summaryrefslogtreecommitdiff
path: root/arch
diff options
context:
space:
mode:
authorSeshendra Gadagottu <sgadagottu@nvidia.com>2011-02-18 22:28:44 +0530
committerVarun Colbert <vcolbert@nvidia.com>2011-02-22 18:12:49 -0800
commitf7a800483296dc29d846d232b58ba7c694e7baab (patch)
tree646b91666ca93fa9b477945e391fbff358193af8 /arch
parent9618759e4a002ee3d121cf090545509bfedb6bff (diff)
arch: arm: usb_phy: support for HSIC power off
Fixing the hsic re-enumeration issue by adding missing code in ushic_phy_power_off function. BUG 790888 Change-Id: I56c280acee2fd6ae6719c6802d14975840ef1d53 Reviewed-on: http://git-master/r/19304 Tested-by: Seshendra Gadagottu <sgadagottu@nvidia.com> Reviewed-by: Kaushik Sen <ksen@nvidia.com> Reviewed-by: Hanumanth Venkateswa Moganty <vmoganty@nvidia.com> Reviewed-by: Shail Dave <sdave@nvidia.com>
Diffstat (limited to 'arch')
-rw-r--r--arch/arm/mach-tegra/usb_phy.c17
1 files changed, 16 insertions, 1 deletions
diff --git a/arch/arm/mach-tegra/usb_phy.c b/arch/arm/mach-tegra/usb_phy.c
index bcc5cc464eb6..7318d95e7317 100644
--- a/arch/arm/mach-tegra/usb_phy.c
+++ b/arch/arm/mach-tegra/usb_phy.c
@@ -933,8 +933,23 @@ static void uhsic_phy_power_on(struct tegra_usb_phy *phy)
static void uhsic_phy_power_off(struct tegra_usb_phy *phy)
{
+ unsigned long val;
+ void __iomem *base = phy->regs;
+
+ val = readl(base + UHSIC_PADS_CFG1);
+ val &= ~UHSIC_RPU_STROBE;
+ val |= UHSIC_RPD_STROBE;
+ writel(val, base + UHSIC_PADS_CFG1);
+
+ val = readl(base + USB_SUSP_CTRL);
+ val |= UHSIC_RESET;
+ writel(val, base + USB_SUSP_CTRL);
+ udelay(30);
+
+ val = readl(base + USB_SUSP_CTRL);
+ val &= ~UHSIC_PHY_ENABLE;
+ writel(val, base + USB_SUSP_CTRL);
- /* Do not do any thing here */
}
struct tegra_usb_phy *tegra_usb_phy_open(int instance, void __iomem *regs,