Messages in this thread | | | Date | Fri, 2 Jul 2004 17:11:52 -0400 (EDT) | From | Alan Stern <> | Subject | Re: [linux-usb-devel] Re: USBDEVFS_RESET deadlocks USB bus. |
| |
On Fri, 2 Jul 2004, Zephaniah E. Hull wrote:
> On Tue, Jun 08, 2004 at 10:19:40PM +0200, Duncan Sands wrote: > > > Great, could you send me the patch? (So I have something usable until it > > > gets into mainline and a kernel is released with it.) > > > > Sure - I just have to write it first! It's a bit tricky to do right... > > Has there been any progress on this? > > I have been looking at the code in question and I am curious as to what > events we are attempting to protect against with the serialize spinlock? > > Thanks.
There has been progress. If you start with the latest 2.6.7 kernels (vanilla or -mm) and apply these two patches:
http://marc.theaimsgroup.com/?l=linux-usb-devel&m=108810394203966&q=raw http://marc.theaimsgroup.com/?l=linux-usb-devel&m=108810535225278&q=raw
the deadlock problems should be solved. Although those patches haven't yet been merged, I'm pretty sure they will be.
To answer your other question... The serialize semaphore (not spinlock) prevents the system from trying to do several incompatible things to a USB device at the same time. For example, reset the device while a driver is probing it. Or reset it while it is being suspended.
Alan Stern
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |