From: Hema HK Date: Mon, 28 Feb 2011 09:35:29 +0000 (+0530) Subject: usb: musb: OMAP3xxx: Fix device detection in otg & host mode X-Git-Tag: MMI-PSA29.97-13-9~20524^2~75 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=70045c57f31f998a7206baa81167c7bc9f452cef;p=GitHub%2FMotorolaMobilityLLC%2Fkernel-slsi.git usb: musb: OMAP3xxx: Fix device detection in otg & host mode In OMAP3xxx with OTG mode or host only mode, When the device is inserted after the gadget driver loading the enumeration was not through. This is because the mentor controller will start sensing the ID PIN only after setting the session bit. So after ID-GND, need to set the session bit for mentor to get it configured as A device. This is a fix to set the session bit again in ID_GND notification handler. Tested with OMAP3630Zoom3 platform. Signed-off-by: Hema HK Signed-off-by: Felipe Balbi --- diff --git a/drivers/usb/musb/omap2430.c b/drivers/usb/musb/omap2430.c index 47267987077d..f5d4f368be9e 100644 --- a/drivers/usb/musb/omap2430.c +++ b/drivers/usb/musb/omap2430.c @@ -246,19 +246,13 @@ static int musb_otg_notifications(struct notifier_block *nb, if (musb->gadget_driver) { pm_runtime_get_sync(musb->controller); otg_init(musb->xceiv); - - if (data->interface_type == - MUSB_INTERFACE_UTMI) - omap2430_musb_set_vbus(musb, 1); - + omap2430_musb_set_vbus(musb, 1); } #endif } else { pm_runtime_get_sync(musb->controller); otg_init(musb->xceiv); - if (data->interface_type == - MUSB_INTERFACE_UTMI) - omap2430_musb_set_vbus(musb, 1); + omap2430_musb_set_vbus(musb, 1); } break;