On Wed, 2003-12-17 at 19:06, Alan Stern wrote: > On Wed, 17 Dec 2003, Axel Waggershauser wrote: > > > Hi, > > > > I was about to write a usb driver (port my old one) based on the > > usb-skeleton.c example in the 2.6.0-test11 source. I either found a bug > > or overlooked something... > > What you wrote looks right to me. > > You should submit it in the form of a patch to Greg KH <[EMAIL PROTECTED]> > and CC: to the linux-usb-devel list. > > Alan Stern >
Ok, here it is (attachment): Axel.
--- linux-2.6.0/drivers/usb/usb-skeleton.c 2003-09-27 02:02:00.000000000 +0200 +++ linux-2.6.0-fixed/drivers/usb/usb-skeleton.c 2003-12-27 14:40:05.000000000 +0100 @@ -297,7 +297,7 @@ --dev->open; - if (!dev->present) { + if (!dev->present && !dev->open) { /* the device was unplugged before the file was released */ up (&dev->sem); skel_delete (dev);