On Wed, Oct 27, 2004 at 03:49:43PM -0400, Alan Stern wrote: > > Since the linux-usb implementation is 100% bug-free, my code is the > > bug's likely home. Should I be holding any locks when I call > > usb_control_msg() or usb_bulk_msg()? > > You certainly shouldn't hold any spinlocks, since those routines need to > sleep. There's nothing wrong with holding a semaphore, but you don't > _need_ to hold any locks at all.
Good.. it's not that then. > Does your driver print a debug message every time it submits an URB or > calls one of those routines? By checking the log you could verify that > events aren't happening out of sequence. I have in the past.. I'm reasonably satisfied that everything's firing in order (on my side anyways). I'll try it again and get back to you. > Have you eliminated the possibility of other programs running in the > background also trying to communicate with your device (some Gnome/hotplug > programs do that)? Yes: I have a single semaphore guarding my data structure and access to the USB device.. so it's no that. (At least, I've checked this many times.) > Have you turned on USB debugging in the kernel configuration? If > something is going wrong, maybe it will show in the debugging log. I have, but I not recently. I'll go do that, re-test and get back to you. > > * Just to recap: this bug happens when my system is heavily loaded > > with lots of disk activity. (Ie, lots of hardware and software > > interrupts.) Also, the only tester that reported the same problem was > > using a dual AMD64. (Sounds ripe for race conditions.) > > I'm not aware of any race conditions. (Of course, if I did know of one I > probably would have fixed it already!) Of course.. I realize it's unlikely I've found a never-seen-before race condition; so thanks for entertaining the idea. Geoff ------------------------------------------------------- This SF.Net email is sponsored by: Sybase ASE Linux Express Edition - download now for FREE LinuxWorld Reader's Choice Award Winner for best database on Linux. http://ads.osdn.com/?ad_id=5588&alloc_id=12065&op=click _______________________________________________ [EMAIL PROTECTED] To unsubscribe, use the last form field at: https://lists.sourceforge.net/lists/listinfo/linux-usb-devel