2 * OF helpers for usb devices.
4 * This file is released under the GPLv2
7 #ifndef __LINUX_USB_OF_H
8 #define __LINUX_USB_OF_H
10 #include <linux/usb/otg.h>
11 #include <linux/usb/phy.h>
13 #if IS_ENABLED(CONFIG_OF)
14 enum usb_dr_mode of_usb_get_dr_mode(struct device_node *np);
16 static inline enum usb_dr_mode of_usb_get_dr_mode(struct device_node *np)
18 return USB_DR_MODE_UNKNOWN;
22 #if IS_ENABLED(CONFIG_OF) && IS_ENABLED(CONFIG_USB_PHY)
23 enum usb_phy_interface of_usb_get_phy_mode(struct device_node *np);
25 static inline enum usb_phy_interface of_usb_get_phy_mode(struct device_node *np)
27 return USBPHY_INTERFACE_MODE_UNKNOWN;
32 #endif /* __LINUX_USB_OF_H */