summaryrefslogtreecommitdiff
path: root/arch
diff options
context:
space:
mode:
authorKrishna Yarlagadda <kyarlagadda@nvidia.com>2012-07-18 17:04:33 +0530
committerMatthew Pedro <mapedro@nvidia.com>2012-08-15 10:43:05 -0700
commitd271f6bb9a48fa382cbc17afadfc1453e94bb234 (patch)
tree1c708eacf673427f5b1df784c90299ad143374d2 /arch
parent80a7b7b2d10a97427e12884d469a518cc2b5f765 (diff)
ARM: tegra: usb: regulator on during lp0 on T20
Tegra 2 requires regulator to be on during lp0 Bug 1012273 Bug 1030730 Signed-off-by: Krishna Yarlagadda <kyarlagadda@nvidia.com> Reviewed-on: http://git-master/r/116743 (cherry picked from commit 50331bba385d880f74dd9dcbce8a32d6f4e49f8c) Change-Id: I8106582529fbb5d6fed76e56b32871af8806b918 Reviewed-on: http://git-master/r/123681 Tested-by: Peer Chen <pchen@nvidia.com> Reviewed-by: Automatic_Commit_Validation_User GVS: Gerrit_Virtual_Submit Reviewed-by: Matthew Pedro <mapedro@nvidia.com>
Diffstat (limited to 'arch')
-rw-r--r--arch/arm/mach-tegra/usb_phy.c13
1 files changed, 5 insertions, 8 deletions
diff --git a/arch/arm/mach-tegra/usb_phy.c b/arch/arm/mach-tegra/usb_phy.c
index a83f04a7656c..de7ff1a65896 100644
--- a/arch/arm/mach-tegra/usb_phy.c
+++ b/arch/arm/mach-tegra/usb_phy.c
@@ -413,6 +413,8 @@ void tegra_usb_phy_close(struct tegra_usb_phy *phy)
}
if (phy->vdd_reg) {
+ if (phy->vdd_reg_on)
+ regulator_disable(phy->vdd_reg);
regulator_put(phy->vdd_reg);
}
@@ -480,17 +482,12 @@ int tegra_usb_phy_power_off(struct tegra_usb_phy *phy)
}
}
- if (phy->vdd_reg && phy->vdd_reg_on) {
-#ifndef CONFIG_ARCH_TEGRA_2x_SOC
- regulator_disable(phy->vdd_reg);
- phy->vdd_reg_on = false;
-#else
- if (tegra_get_revision() >= TEGRA_REVISION_A03) {
+ if (phy->vdd_reg && phy->vdd_reg_on)
+ if (phy->pdata->has_hostpc ||
+ phy->pdata->builtin_host_disabled) {
regulator_disable(phy->vdd_reg);
phy->vdd_reg_on = false;
}
-#endif
- }
phy->phy_power_on = false;