> Problem #1.- Continuous reset of the USB controller > To check if the hardware is fine, I've run the BSP FSL-2.6.31_09.12.01 > from Freescale and I can load any gadget driver with positive results. > > The problem appears on new kernels when fsl_udc_core is compiled with > VERBOSE and DEBUG defined. I've tried 3.2.2, 3.3.2 and 3.4-rc3 kernels, > all of them with the same results; if I load -any- gadget driver and > plug the USB cord into my Linux Host, I get the following error > messages, continuously, non stopping: > ------------------------------------------------------------------------ > --- [fsl_udc_irq] reset int > [reset_irq] Controller reset > [dr_controller_setup] vir[qh_base] is ffdf9000 phy[qh_base] is > 0x838c4000 reg is 0x838c4000 > [fsl_udc_irq] reset int > [reset_irq] Controller reset > [dr_controller_setup] vir[qh_base] is ffdf9000 phy[qh_base] is > 0x838c4000 reg is 0x838c4000 > .......... > .......... > ------------------------------------------------------------------------ > --- > If fsl_udc_core is compiled with VERBOSE -OR- DEBUG undefined, I can > load any gadget driver with no "reset" problem. > PORTSCX_PORT_RESET is cleared by hardware automatically when the reset is completed, if you have inserted too many debug message after reset occurs, the PORTSCX_PORT_RESET will be 0. The code at upstream may have some problems, you may not need below code: 1833 } else { 1834 VDBG("Controller reset"); 1835 /* initialize usb hw reg except for regs for EP, not 1836 * touch usbintr reg */ 1837 dr_controller_setup(udc); 1838 1839 /* Reset all internal used Queues */ 1840 reset_queues(udc); 1841 1842 ep0_setup(udc); 1843 1844 /* Enable DR IRQ reg, Set Run bit, change udc state */ 1845 dr_controller_run(udc); 1846 udc->usb_state = USB_STATE_ATTACHED; 1847 } > > > Problem #2.- g_webcam enumeration > The enumeration starts as soon as the USB cord is plugged into my Linux > Host, but with no user space support (the device /dev/video0 hasn't been > opened). > > With the USB cord unplugged I've traced the call chain when g_webcam is > modprobed down to "fsl_pullup". This function is only called once and, > as expected, "is_on" parameter is 0 so the pullup should disabled, but > when I plug the USB cord ..... enumeration starts :( > Some logic about controlling controller run/stop is incomplete at current i.mx framework (lack of vbus interrupt to trigger fsl_vbus_session) Temp solution for let your thing work (only for g_webcam): 1. Does not set USB_CMD_RUN_STOP at dr_controller_run 2. Change fsl_pullup: 1234 if (can_pullup(udc)) --> 1234 if (is_on) > Any advice is really appreciated !!! > > TIA for your help, > Gonzalo. > > > -- > To unsubscribe from this list: send the line "unsubscribe linux-usb" in > the body of a message to majordomo@xxxxxxxxxxxxxxx > More majordomo info at http://vger.kernel.org/majordomo-info.html -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html