aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-omap2/omap_phy_internal.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/mach-omap2/omap_phy_internal.c')
-rw-r--r--arch/arm/mach-omap2/omap_phy_internal.c35
1 files changed, 0 insertions, 35 deletions
diff --git a/arch/arm/mach-omap2/omap_phy_internal.c b/arch/arm/mach-omap2/omap_phy_internal.c
index 1a19fa096bab..8e903564ede2 100644
--- a/arch/arm/mach-omap2/omap_phy_internal.c
+++ b/arch/arm/mach-omap2/omap_phy_internal.c
@@ -152,38 +152,3 @@ void am35x_set_mode(u8 musb_mode)
152 152
153 omap_ctrl_writel(devconf2, AM35XX_CONTROL_DEVCONF2); 153 omap_ctrl_writel(devconf2, AM35XX_CONTROL_DEVCONF2);
154} 154}
155
156void ti81xx_musb_phy_power(u8 on)
157{
158 void __iomem *scm_base = NULL;
159 u32 usbphycfg;
160
161 scm_base = ioremap(TI81XX_SCM_BASE, SZ_2K);
162 if (!scm_base) {
163 pr_err("system control module ioremap failed\n");
164 return;
165 }
166
167 usbphycfg = readl_relaxed(scm_base + USBCTRL0);
168
169 if (on) {
170 if (cpu_is_ti816x()) {
171 usbphycfg |= TI816X_USBPHY0_NORMAL_MODE;
172 usbphycfg &= ~TI816X_USBPHY_REFCLK_OSC;
173 } else if (cpu_is_ti814x()) {
174 usbphycfg &= ~(USBPHY_CM_PWRDN | USBPHY_OTG_PWRDN
175 | USBPHY_DPINPUT | USBPHY_DMINPUT);
176 usbphycfg |= (USBPHY_OTGVDET_EN | USBPHY_OTGSESSEND_EN
177 | USBPHY_DPOPBUFCTL | USBPHY_DMOPBUFCTL);
178 }
179 } else {
180 if (cpu_is_ti816x())
181 usbphycfg &= ~TI816X_USBPHY0_NORMAL_MODE;
182 else if (cpu_is_ti814x())
183 usbphycfg |= USBPHY_CM_PWRDN | USBPHY_OTG_PWRDN;
184
185 }
186 writel_relaxed(usbphycfg, scm_base + USBCTRL0);
187
188 iounmap(scm_base);
189}