aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/core
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>2014-11-25 12:31:14 -0500
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2014-11-25 12:31:14 -0500
commit2d4d9f35bab1cad7f83d10864291d1e50b12c3f9 (patch)
tree24b5f23a1c98e29b8d2daad46133bfb261a8abae /drivers/usb/core
parent2193dda5eec60373c7a061c129c6ab9d658f78e9 (diff)
parentebf3992061db1f7b3aa093f37fb308acc74fbc82 (diff)
Merge tag 'usb-for-v3.19' of git://git.kernel.org/pub/scm/linux/kernel/git/balbi/usb into usb-next
Felipe writes: usb: patches for v3.19 merge window This time, a very pull request with 216 non-merge commits. Most of the commits contained here are sparse or coccinelle fixes ranging from missing 'static' to returning 0 in case of errors. More importantly, we have the removal the now unnecessary 'driver' argument to ->udc_stop(). DWC2 learned about Dual-Role builds. Users of this IP can now have a single driver built for host and device roles. DWC3 got support for two new HW platforms: Exynos7 and AMD. The Broadcom USB 3.0 Device Controller IP is now supported and so is PLX USB338x, which means DWC3 has lost is badge as the only USB 3.0 peripheral IP supported on Linux. Thanks for Tony Lindgren's work, we can now have a distro-like kernel where all MUSB glue layers can be built into the same kernel (statically or dynamically linked) and it'll work in PIO (DMA will come probably on v3.20). Other than these, the usual set of cleanups and non-critical fixes. Signed-off-by: Felipe Balbi <balbi@ti.com>
Diffstat (limited to 'drivers/usb/core')
-rw-r--r--drivers/usb/core/hcd.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/drivers/usb/core/hcd.c b/drivers/usb/core/hcd.c
index a6efb4184f2b..2f2118fa36a8 100644
--- a/drivers/usb/core/hcd.c
+++ b/drivers/usb/core/hcd.c
@@ -2650,7 +2650,7 @@ int usb_add_hcd(struct usb_hcd *hcd,
2650 } 2650 }
2651 } 2651 }
2652 2652
2653 if (IS_ENABLED(CONFIG_GENERIC_PHY)) { 2653 if (IS_ENABLED(CONFIG_GENERIC_PHY) && !hcd->phy) {
2654 struct phy *phy = phy_get(hcd->self.controller, "usb"); 2654 struct phy *phy = phy_get(hcd->self.controller, "usb");
2655 2655
2656 if (IS_ERR(phy)) { 2656 if (IS_ERR(phy)) {
@@ -2670,6 +2670,7 @@ int usb_add_hcd(struct usb_hcd *hcd,
2670 goto err_phy; 2670 goto err_phy;
2671 } 2671 }
2672 hcd->phy = phy; 2672 hcd->phy = phy;
2673 hcd->remove_phy = 1;
2673 } 2674 }
2674 } 2675 }
2675 2676
@@ -2816,7 +2817,7 @@ err_allocate_root_hub:
2816err_register_bus: 2817err_register_bus:
2817 hcd_buffer_destroy(hcd); 2818 hcd_buffer_destroy(hcd);
2818err_create_buf: 2819err_create_buf:
2819 if (IS_ENABLED(CONFIG_GENERIC_PHY) && hcd->phy) { 2820 if (IS_ENABLED(CONFIG_GENERIC_PHY) && hcd->remove_phy && hcd->phy) {
2820 phy_power_off(hcd->phy); 2821 phy_power_off(hcd->phy);
2821 phy_exit(hcd->phy); 2822 phy_exit(hcd->phy);
2822 phy_put(hcd->phy); 2823 phy_put(hcd->phy);
@@ -2900,7 +2901,7 @@ void usb_remove_hcd(struct usb_hcd *hcd)
2900 usb_deregister_bus(&hcd->self); 2901 usb_deregister_bus(&hcd->self);
2901 hcd_buffer_destroy(hcd); 2902 hcd_buffer_destroy(hcd);
2902 2903
2903 if (IS_ENABLED(CONFIG_GENERIC_PHY) && hcd->phy) { 2904 if (IS_ENABLED(CONFIG_GENERIC_PHY) && hcd->remove_phy && hcd->phy) {
2904 phy_power_off(hcd->phy); 2905 phy_power_off(hcd->phy);
2905 phy_exit(hcd->phy); 2906 phy_exit(hcd->phy);
2906 phy_put(hcd->phy); 2907 phy_put(hcd->phy);