diff options
author | Tuomas Tynkkynen <ttynkkynen@nvidia.com> | 2013-07-25 21:38:06 +0300 |
---|---|---|
committer | Felipe Balbi <balbi@ti.com> | 2013-07-29 13:58:25 +0300 |
commit | 7db71a9a6707284f3d9075fff2ad674f6a51c359 (patch) | |
tree | 902a0864cecd8299dc3b1998ef4c3b575865d85a /drivers/usb | |
parent | 0ee5b4ab79b6be1400f3fa47142e927ddc33a5bd (diff) | |
download | blackbird-op-linux-7db71a9a6707284f3d9075fff2ad674f6a51c359.tar.gz blackbird-op-linux-7db71a9a6707284f3d9075fff2ad674f6a51c359.zip |
usb: host: tegra: Locate a PHY via standard API
Use devm_get_phy_by_phandle to get a PHY device instead of the custom
Tegra functions.
Signed-off-by: Tuomas Tynkkynen <ttynkkynen@nvidia.com>
Reviewed-by: Stephen Warren <swarren@nvidia.com>
Tested-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
Diffstat (limited to 'drivers/usb')
-rw-r--r-- | drivers/usb/host/ehci-tegra.c | 9 |
1 files changed, 1 insertions, 8 deletions
diff --git a/drivers/usb/host/ehci-tegra.c b/drivers/usb/host/ehci-tegra.c index a208cea4e4c7..db8031fd5c13 100644 --- a/drivers/usb/host/ehci-tegra.c +++ b/drivers/usb/host/ehci-tegra.c @@ -328,7 +328,6 @@ static int tegra_ehci_probe(struct platform_device *pdev) struct tegra_ehci_hcd *tegra; int err = 0; int irq; - struct device_node *np_phy; struct usb_phy *u_phy; /* Right now device-tree probed devices don't get dma_mask set. @@ -367,13 +366,7 @@ static int tegra_ehci_probe(struct platform_device *pdev) udelay(1); tegra_periph_reset_deassert(tegra->clk); - np_phy = of_parse_phandle(pdev->dev.of_node, "nvidia,phy", 0); - if (!np_phy) { - err = -ENODEV; - goto cleanup_clk_en; - } - - u_phy = tegra_usb_get_phy(np_phy); + u_phy = devm_usb_get_phy_by_phandle(&pdev->dev, "nvidia,phy", 0); if (IS_ERR(u_phy)) { err = PTR_ERR(u_phy); goto cleanup_clk_en; |