Am Mittwoch, 11. Mai 2005 15:34 schrieb Stuart MacDonald: > From: Pete Zaitcev [mailto:[EMAIL PROTECTED] > > On Wed, 20 Apr 2005 11:28:39 -0700, Greg KH <[EMAIL PROTECTED]> wrote: > > > On Wed, Apr 20, 2005 at 08:26:29PM +0200, Oliver Neukum wrote: > > > > /* shutdown our bulk reads and writes */ > > > > spin_lock_irqsave(&info->lock, flags); > > > > list_for_each_safe(tmp, tmp2, &info->rx_urbs_submitted) { > > > > wrap = list_entry(tmp, struct whiteheat_urb_wrap, list); > > > > urb = wrap->urb; > > > > usb_kill_urb(urb); > > > > list_del(tmp); > > > > list_add(tmp, &info->rx_urbs_free); > > > > } > > > > > > > > This, from whiteheat.c, is wrong. Usb_kill_urb() with a spinlock > > > > held is illegal. > > Curious, why is it illegal? **
Because it may sleep. Any task scheduled in after the unlinking task goes to sleep may attempt to take the spinlock already held. That would hang the CPU it runs on. HTH Oliver ------------------------------------------------------- This SF.Net email is sponsored by Oracle Space Sweepstakes Want to be the first software developer in space? Enter now for the Oracle Space Sweepstakes! http://ads.osdn.com/?ad_id=7393&alloc_id=16281&op=click _______________________________________________ linux-usb-devel@lists.sourceforge.net To unsubscribe, use the last form field at: https://lists.sourceforge.net/lists/listinfo/linux-usb-devel