Commit 8ba007a9 authored by Kishon Vijay Abraham I's avatar Kishon Vijay Abraham I Committed by Felipe Balbi

usb: dwc3: core: enable the USB2 and USB3 phy in probe

Enabled the USB2 and USB3 PHY in probe by calling usb_phy_set_suspend
and disabled the PHYs on driver removal. When PM is implemented this
will be optimized to enable the PHYs only when needed.
Signed-off-by: default avatarKishon Vijay Abraham I <kishon@ti.com>
Signed-off-by: default avatarFelipe Balbi <balbi@ti.com>
parent 7e41bba9
......@@ -432,6 +432,9 @@ static int dwc3_probe(struct platform_device *pdev)
return -EPROBE_DEFER;
}
usb_phy_set_suspend(dwc->usb2_phy, 0);
usb_phy_set_suspend(dwc->usb3_phy, 0);
spin_lock_init(&dwc->lock);
platform_set_drvdata(pdev, dwc);
......@@ -554,6 +557,9 @@ static int dwc3_remove(struct platform_device *pdev)
res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
usb_phy_set_suspend(dwc->usb2_phy, 1);
usb_phy_set_suspend(dwc->usb3_phy, 1);
pm_runtime_put(&pdev->dev);
pm_runtime_disable(&pdev->dev);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment