On Thu, 17 Nov 2005, vishal wrote: > thanks a lot Greg. I applied the said patches. And thankfully i am able to > detect my device as a Mass strage media device when i use the following > module load command: > #insmod g_file_storage.ko file=/my_file stall=n transport=BBB protocol=SCSI > removable=y > But the detection is succesfull on a windows host. I am able to read the > files succesfully and flawlessly!! > > However when i try to edit a file and save it, the host controller resets > the device(my board) > I traced the code and here is what i found happens: > When the Host issues a WRITE(10) command to the device, my DM320 function > driver hands it over to the Mass Media driver gadget layer wherein the code > jumps to the do_write() function in the file_storage.c, and there it keeps > waiting inside the > sleep_thread(),wait_event_interruptible(fsg->thread_wqh...) > I havent really understood the Mass Media Driver layer yet, am trying > to...any help on what may cause this problem?
The driver is waiting for the host to send data. It can't write anything until the host tells it what to write. > And why would the device not get detected on my Linux host running 2.6.13 > ?. I get read descriptor errors on my linux host when i plug in the > device.Could there be some timing issues? Maybe the device isnt settling > down in the stipulated time? There are lots of possible errors. If you would post a verbose debugging log from the host and from the gadget, maybe I could tell what's going wrong. Make sure the host has CONFIG_USB_DEBUG turned on and the gadget driver has #define DEBUG and #define VERBOSE. Alan Stern ------------------------------------------------------- This SF.Net email is sponsored by the JBoss Inc. Get Certified Today Register for a JBoss Training Course. Free Certification Exam for All Training Attendees Through End of 2005. For more info visit: http://ads.osdn.com/?ad_id=7628&alloc_id=16845&op=click _______________________________________________ [email protected] To unsubscribe, use the last form field at: https://lists.sourceforge.net/lists/listinfo/linux-usb-devel
