summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorVenkat Moganty <vmoganty@nvidia.com>2010-09-28 21:32:08 +0530
committerYu-Huan Hsu <yhsu@nvidia.com>2010-10-05 22:16:52 -0700
commit8eaa0afc05248d324ec8d46a557740a043d8e641 (patch)
tree0f7171394565be89e65a903f3f747e02da64be0a /drivers
parent37950bcdd4fdd21b0ff0770c9c5c2fb8c50fbfff (diff)
[tegra-ehci]USB device detection for host mode in LP0
USB devices are not recognised when connected to the USB port, when system is already in LP0. Root port power is not getting enabled when resume from LP0. By the time root hub checks for the port connection auto suspend is getting called and device is not recognised. Fixed this by enabling the root port power during the ehci_restart functionality. Bug 741890 (cherry picked from commit 188bf7050751a40d6f2d6a858e2702774fc70f77) Change-Id: Ib88ed3fc4b01719777a0e49e27434ef6425bc53d Reviewed-on: http://git-master/r/7834 Reviewed-by: Hanumanth Venkateswa Moganty <vmoganty@nvidia.com> Tested-by: Hanumanth Venkateswa Moganty <vmoganty@nvidia.com> Reviewed-by: Yu-Huan Hsu <yhsu@nvidia.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/usb/host/ehci-tegra.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/usb/host/ehci-tegra.c b/drivers/usb/host/ehci-tegra.c
index 54c9ab28b580..1d24a03cd903 100644
--- a/drivers/usb/host/ehci-tegra.c
+++ b/drivers/usb/host/ehci-tegra.c
@@ -177,6 +177,12 @@ static void tegra_ehci_restart (struct usb_hcd *hcd)
ehci->command |= CMD_RUN;
ehci_writel(ehci, ehci->command, &ehci->regs->command);
+ /* Enable the root Port Power */
+ if (HCS_PPC (ehci->hcs_params)) {
+ temp = ehci_readl(ehci, &ehci->regs->port_status[0]);
+ ehci_writel(ehci, temp | PORT_POWER, &ehci->regs->port_status[0]);
+ }
+
down_write(&ehci_cf_port_reset_rwsem);
hcd->state = HC_STATE_RUNNING;
/* unblock posted writes */