On Mon, Apr 05 2004, James Bottomley wrote: > On Sun, 2004-04-04 at 23:33, Patrick Mansfield wrote: > > How is unregister_cdrom(&cd->cdi) called if the device is not open? > > OK, the attached does everything correctly (as I should have done at > first) by using a kobject to hold the compound references. > > I've stressed this one nicely. Unfortunately, it's showing up a bug in > scsi_sysfs (hold device open, remove it and re-add it at the same HCTL > and you'll see an "error 1").
Really? It doesn't even compile :-) > @@ -514,12 +542,18 @@ > if (sdev->type != TYPE_ROM && sdev->type != TYPE_WORM) > goto fail; > > + if ((err = scsi_device_get(sdev)) != 0) > + goto fail_put_sdev; > + > error = -ENOMEM; > cd = kmalloc(sizeof(*cd), GFP_KERNEL); > if (!cd) > goto fail; > memset(cd, 0, sizeof(*cd)); -- Jens Axboe ------------------------------------------------------- This SF.Net email is sponsored by: IBM Linux Tutorials Free Linux tutorial presented by Daniel Robbins, President and CEO of GenToo technologies. Learn everything from fundamentals to system administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click _______________________________________________ [EMAIL PROTECTED] To unsubscribe, use the last form field at: https://lists.sourceforge.net/lists/listinfo/linux-usb-devel
