aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb
diff options
context:
space:
mode:
authorMarek Szyprowski <m.szyprowski@samsung.com>2014-10-20 06:45:34 -0400
committerFelipe Balbi <balbi@ti.com>2014-10-23 14:58:51 -0400
commit3a8146aafcedd93e42045598802e1eb71cae68c0 (patch)
tree19b34c127184b8377f54b42f34dbc624be919821 /drivers/usb
parentd12a8727171c770990c246f0682f0af7859bb245 (diff)
usb: dwc2: gadget: disable phy before turning off power regulators
This patch fixes probe function to match the pattern used elsewhere in the driver, where power regulators are turned off as the last element in the device shutdown procedure. Acked-by: Paul Zimmerman <paulz@synopsys.com> Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
Diffstat (limited to 'drivers/usb')
-rw-r--r--drivers/usb/dwc2/gadget.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/usb/dwc2/gadget.c b/drivers/usb/dwc2/gadget.c
index 5e548f75686c..eee87098bb8b 100644
--- a/drivers/usb/dwc2/gadget.c
+++ b/drivers/usb/dwc2/gadget.c
@@ -3568,6 +3568,7 @@ static int s3c_hsotg_probe(struct platform_device *pdev)
3568 s3c_hsotg_initep(hsotg, &hsotg->eps[epnum], epnum); 3568 s3c_hsotg_initep(hsotg, &hsotg->eps[epnum], epnum);
3569 3569
3570 /* disable power and clock */ 3570 /* disable power and clock */
3571 s3c_hsotg_phy_disable(hsotg);
3571 3572
3572 ret = regulator_bulk_disable(ARRAY_SIZE(hsotg->supplies), 3573 ret = regulator_bulk_disable(ARRAY_SIZE(hsotg->supplies),
3573 hsotg->supplies); 3574 hsotg->supplies);
@@ -3576,8 +3577,6 @@ static int s3c_hsotg_probe(struct platform_device *pdev)
3576 goto err_ep_mem; 3577 goto err_ep_mem;
3577 } 3578 }
3578 3579
3579 s3c_hsotg_phy_disable(hsotg);
3580
3581 ret = usb_add_gadget_udc(&pdev->dev, &hsotg->gadget); 3580 ret = usb_add_gadget_udc(&pdev->dev, &hsotg->gadget);
3582 if (ret) 3581 if (ret)
3583 goto err_ep_mem; 3582 goto err_ep_mem;