RE: [PATCH 3/6 v2] omap: musb: ti81xx: Add phy power function

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

> On 07-09-2011 21:02, Ajay Kumar Gupta wrote:
> 
> > Adding ti81xx_musb_phy_power() which will be used by musb driver
> through
> > its function pointer in board_data.
> 
> > Signed-off-by: Ajay Kumar Gupta<ajay.gupta@xxxxxx>
> > Signed-off-by: Ravi Babu<ravibabu@xxxxxx>
> > ---
> >   arch/arm/mach-omap2/omap_phy_internal.c |   24
> +++++++++++++++++++++++
> >   arch/arm/plat-omap/include/plat/usb.h   |   32
> +++++++++++++++++++++++++++++++
> >   2 files changed, 56 insertions(+), 0 deletions(-)
> 
> > diff --git a/arch/arm/mach-omap2/omap_phy_internal.c b/arch/arm/mach-
> omap2/omap_phy_internal.c
> > index 58775e3..352b6af 100644
> > --- a/arch/arm/mach-omap2/omap_phy_internal.c
> > +++ b/arch/arm/mach-omap2/omap_phy_internal.c
> > @@ -260,3 +260,27 @@ void am35x_set_mode(u8 musb_mode)
> >
> >   	omap_ctrl_writel(devconf2, AM35XX_CONTROL_DEVCONF2);
> >   }
> > +
> > +void ti81xx_musb_phy_power(u8 on)
> > +{
> > +	u32 usbphycfg = omap_ctrl_readl(USBCTRL0);
> > +
> > +	if (on) {
> > +		if (cpu_is_ti816x()) {
> > +			usbphycfg |= TI816X_USBPHY0_NORMAL_MODE;
> > +			usbphycfg &= ~TI816X_USBPHY_REFCLK_OSC;
> > +		} else if (cpu_is_ti814x()) {
> > +			usbphycfg&= ~(USBPHY_CM_PWRDN | USBPHY_OTG_PWRDN
> > +				| USBPHY_DPINPUT | USBPHY_DMINPUT);
> > +			usbphycfg |= (USBPHY_OTGVDET_EN |
> USBPHY_OTGSESSEND_EN
> > +				| USBPHY_DPOPBUFCTL | USBPHY_DPOPBUFCTL);
> 
>     Same #define repeated twice?

Good catch.. thanks. One of them should be USBPHY_DMOPBUFCTL, will fix in v3.

Ajay
> 
> WBR, Sergei
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Arm (vger)]     [ARM Kernel]     [ARM MSM]     [Linux Tegra]     [Linux WPAN Networking]     [Linux Wireless Networking]     [Maemo Users]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux