summaryrefslogtreecommitdiff
path: root/drivers/usb/otg
diff options
context:
space:
mode:
authorKurt Yi <kyi@nvidia.com>2012-01-11 21:11:07 +0900
committerVarun Colbert <vcolbert@nvidia.com>2012-01-19 16:25:39 -0800
commitbdd9e97c84f69bab23f5542dc6ac2efa93e53224 (patch)
treef59beafbd80de5e72a5d273a0113eed2d0aafa0b /drivers/usb/otg
parent4b9dfedec9ab23b03949407856c03635f31cfa49 (diff)
usb: host: tegra: replace CONFIG_USB_HOTPLUG to tegra_ehci_platform_data
remove CONFIG_USB_HOTPLUG and add default_enable into tegra_ehci_platform_data We can't use different def_config because whistler & ventana source code is merged in same tree. BUG 923705 Change-Id: I3dfdf237d80865831264f02104c89c8088101905 Reviewed-on: http://git-master/r/74574 Signed-off-by: Kurt Yi <kyi@nvidia.com> Signed-off-by: Varun Wadekar <vwadekar@nvidia.com> Reviewed-on: http://git-master/r/75888 Reviewed-by: Varun Colbert <vcolbert@nvidia.com> Tested-by: Varun Colbert <vcolbert@nvidia.com>
Diffstat (limited to 'drivers/usb/otg')
-rw-r--r--drivers/usb/otg/tegra-otg.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/drivers/usb/otg/tegra-otg.c b/drivers/usb/otg/tegra-otg.c
index a063630e529d..d23356e9c1a7 100644
--- a/drivers/usb/otg/tegra-otg.c
+++ b/drivers/usb/otg/tegra-otg.c
@@ -324,6 +324,8 @@ static int tegra_otg_set_suspend(struct otg_transceiver *otg, int suspend)
static int tegra_otg_probe(struct platform_device *pdev)
{
struct tegra_otg_data *tegra;
+ struct tegra_otg_platform_data *otg_pdata;
+ struct tegra_ehci_platform_data *ehci_pdata;
struct resource *res;
int err;
@@ -332,6 +334,8 @@ static int tegra_otg_probe(struct platform_device *pdev)
return -ENOMEM;
tegra->otg.dev = &pdev->dev;
+ otg_pdata = tegra->otg.dev->platform_data;
+ ehci_pdata = otg_pdata->ehci_pdata;
tegra->otg.label = "tegra-otg";
tegra->otg.state = OTG_STATE_UNDEFINED;
tegra->otg.set_host = tegra_otg_set_host;
@@ -391,9 +395,8 @@ static int tegra_otg_probe(struct platform_device *pdev)
}
INIT_WORK (&tegra->work, irq_work);
-#ifndef CONFIG_USB_HOTPLUG
- clk_disable(tegra->clk);
-#endif
+ if (!ehci_pdata->default_enable)
+ clk_disable(tegra->clk);
dev_info(&pdev->dev, "otg transceiver registered\n");
return 0;