diff options
author | Otavio Salvador <otavio@ossystems.com.br> | 2017-06-17 10:36:40 -0300 |
---|---|---|
committer | Otavio Salvador <otavio@ossystems.com.br> | 2017-06-17 10:36:40 -0300 |
commit | 683b9eda58bdc48ad6606f22ca318f1d2200934d (patch) | |
tree | 7acde2eff67256e06cae0419b03af38c5503e5c1 /include/linux/usb | |
parent | a4418c438de6ad397fd17f006ca86257fb9ec5a6 (diff) | |
parent | 30278abfe0977b1d2f065271ce1ea23c0e2d1b6e (diff) |
Merge remote-tracking branch 'imx/imx_4.1.15_2.0.0_ga' into 4.1-2.0.x-imx
* imx/imx_4.1.15_2.0.0_ga: (157 commits)
MLK-14762 ARM: dts: imx6sll-evk: correct gpio pin for lcd power control
MLK-14285-3 usb: phy: mxs: optimize disconnect line condition
MLK-14285-2 usb: chipidea: set mode for usb phy driver
MLK-14285-1 usb: phy: add usb mode for usb_phy
MLK-14747 driver: cpufreq: Correct dc regulator voltage on imx6ull
MLK-14720 epdc: correct WFE setting when bypass legacy process
MLK-13801-02 ARM: dts: Correct the gpt timer clock source on imx6ul/ull/sll
MLK-13801-01 ARM: imx: add gpt_3m clock on imx6sll
MLK-14680 pxp/epdc: add LUT cancellation feature
MLK-14518-2 pxp: set data path for pxp after reset
MLK-14518-1 pxp: initialize pxp according to recommended flow
MLK-14516 epdc: bypass pxp legacy process when there's no transformation
MLK-14369 epdc: sync LUT status to PXP before enable collision detection
MLK-13198 pxp: imx7d: fix error histogram status report issue
MLK-13917 pxp: fix build error for pxp library in user space
MLK-13862-2 epdc/pxp: imx6ull/imx6sll: enhance the LUT cleanup flow to avoid stalling display
MLK-13862-1 epdc/pxp: imx7d: enhance the LUT cleanup flow to avoid stalling display
MLK-14697 ARM: dts: imx: update the setpoint data of imx6sll
MXSCM-266 arm: dts: increase lpddr2 voltage to 1.25V
MXSCM-265: dts: place imx6sxscm dtb files under CONFIG_SOC_IMX6SX
...
Diffstat (limited to 'include/linux/usb')
-rw-r--r-- | include/linux/usb/phy.h | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/include/linux/usb/phy.h b/include/linux/usb/phy.h index 6700d2f6fdde..315b3096b2e8 100644 --- a/include/linux/usb/phy.h +++ b/include/linux/usb/phy.h @@ -60,6 +60,13 @@ enum usb_otg_state { OTG_STATE_A_VBUS_ERR, }; +/* The usb role of phy to be working with */ +enum usb_current_mode { + USB_MODE_NONE, + USB_MODE_HOST, + USB_MODE_DEVICE, +}; + struct usb_phy; struct usb_otg; @@ -127,6 +134,9 @@ struct usb_phy { int (*notify_resume)(struct usb_phy *x, enum usb_device_speed speed); + int (*set_mode)(struct usb_phy *x, + enum usb_current_mode mode); + }; /** @@ -201,6 +211,15 @@ usb_phy_vbus_off(struct usb_phy *x) return x->set_vbus(x, false); } +static inline int +usb_phy_set_mode(struct usb_phy *x, enum usb_current_mode mode) +{ + if (!x || !x->set_mode) + return 0; + + return x->set_mode(x, mode); +} + /* for usb host and peripheral controller drivers */ #if IS_ENABLED(CONFIG_USB_PHY) extern struct usb_phy *usb_get_phy(enum usb_phy_type type); |