On Mon, Dec 17, 2012 at 04:12:13PM +0800, victor wrote: > Hi, > > > > > > > > > > > # insmod kagen2_udc.ko > > > > > # insmod g_file_storage.ko file=/dev/mmcblk0 > > > > > gadget: controller 'kagen2_usb' not recognized > > > > > > > > this should have caught your attention!! Also, rebase to a newer > > > > kernel as > > > that > > > > message has already been dropped. > > > > > > > > > > The udc_start() function is being called now. Before this, it was not > > > called because of driver->max_speed checking in udc_start(). After > > > udc_start(), which function is to be called when the gadget device is > > > connected to the host PC? > > > > > > Thanks. I will look at the "controller 'kagen2_usb' not recognized" > message. > > > The development is being done on arm9 architecture. I am afraid it is > > > not possible to move to a newer kernel now. > > > > fair enough. Just to help you out, I believe that message will be under > > drivers/usb/gadget/gadget_chips.h: > > > > > http://git.kernel.org/?p=linux/kernel/git/balbi/usb.git;a=blob;f=drivers/usb > /gad > > get/gadget_chips.h;h=a8855d0b7f3bdf19fbdc76eab8a25992f07884b0;hb=76e1 > > 0d158efb6d4516018846f60c2ab5501900bc > > > > note that you must add your gadget_is_kagen2() and check for it on > > usb_gadget_controller_number(). Also keep in mind that this doesn't exist > > anymore for recent kernels. > > > > Thanks, I got it done. I can insmod the g_file_storage.ko without the > "controller 'kagen2_usb' not recognized" message. After that, can I simply > connect the usb cable to the host PC? Because the PC says "USB device not > recognised" when I do so. I have registered the irq routine in > kagen2_udc.ko, and it is not called when usb cable is plugged in. What can > go wrong? from this point on, you need to read your HW documentation. Maybe you're using wrong IRQ number ? Who knows. I have no clue how kagen2 works and can't help anymore. -- balbi
Attachment:
signature.asc
Description: Digital signature