On Wed, Sep 10, 2003 at 12:38:18PM +1000, Mark McDougall wrote:
> Hi All,
> 
> I'm having problems unlinking in my device driver.
> 
> My driver submits a number of IN urbs on device open (up to 16) and 
> simply appends data in a buffer in the callback function before 
> re-submitting another urb (not the same one - an 'idle' one).
> 
> However, when closing the device and attempting to unlink the urbs, I am 
> getting kernel panics. Sometimes they occur on close (unlink), and other 
> times on module exit (probably on free_urb).
> 
> Are there any known race conditions in usb_unlink_urb()? (I saw 
> reference to one in passing in a msg on this mailing list)

What kernel version are you using?  And what is the callback for the
oops?

> I've seen plenty of code that checks urb->status == -EINPROGRESS then 
> unlinks if required - but IMHO that's pretty susceptible to race 
> conditions?!? FWIW I'm using SYNC unlinking.

Yeah, don't check for that.  Just make the call.  That should work just
fine in 2.6.

thanks,

greg k-h


-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
[EMAIL PROTECTED]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel

Reply via email to