On Thu, Aug 15, 2013 at 05:21:51PM +0200, Sebastian Andrzej Siewior wrote: > This is what I observe: > On the first connect, the musb starts with DEVCTL.Session set. On > disconnect, musb_core calls try_idle. That functions removes the Session > bit signalizing that the session is over (something that only in OTG is > required). A new device, that is plugged, is no longer recognized. > I've setup a timer and checked the DEVCTL register and I haven't seen a > change in VBus and I saw the B-Device bit set. After setting the IDDIG > into A mode and forcing the device to behave like a A device, I didn't > see a change. > Neither VBUS goes to 0b11 nor does a session start request comes. > In the TI-v3.2 kernel they skip to call musb_platform_try_idle() in the > OTG_STATE_A_WAIT_BCON state while not in OTG mode. > Since the second port hast a standard A plug the patch changes the port > to run in host mode only and skips the timer which would remove > DEVCTL.Session so we can reconnect to another device later. > > Signed-off-by: Sebastian Andrzej Siewior <bigeasy@xxxxxxxxxxxxx> Acked-by: Felipe Balbi <balbi@xxxxxx> > --- > arch/arm/boot/dts/am335x-evm.dts | 3 +++ > drivers/usb/musb/musb_dsps.c | 2 ++ > 2 files changed, 5 insertions(+) > > diff --git a/arch/arm/boot/dts/am335x-evm.dts b/arch/arm/boot/dts/am335x-evm.dts > index 648a67e..794b38b9 100644 > --- a/arch/arm/boot/dts/am335x-evm.dts > +++ b/arch/arm/boot/dts/am335x-evm.dts > @@ -192,6 +192,9 @@ > > usb@47401800 { > status = "okay"; > + musb1: usb@47401c00 { > + port-mode = <1>; > + }; > }; > > dma-controller@07402000 { > diff --git a/drivers/usb/musb/musb_dsps.c b/drivers/usb/musb/musb_dsps.c > index 7368577..b7b2346 100644 > --- a/drivers/usb/musb/musb_dsps.c > +++ b/drivers/usb/musb/musb_dsps.c > @@ -230,6 +230,8 @@ static void dsps_musb_try_idle(struct musb *musb, unsigned long timeout) > glue->last_timer = jiffies; > return; > } > + if (musb->port_mode == MUSB_PORT_MODE_HOST) > + return; > > if (time_after(glue->last_timer, timeout) && > timer_pending(&glue->timer)) { > -- > 1.8.4.rc2 > -- balbi
Attachment:
signature.asc
Description: Digital signature