Ooops unmounting a defect DVD
I wouldn't have noticed this at all since you didn't send it to the scsi list, but fortunately, Al Viro drew it politely to my attention as another example of SCSI refcounting problems.
The issue seems to be that we have a spurious scsi_cd_put() on the error path of sr_open(). The sr_block_..() functions are the "real" block opens and should be refcounted, the sr_...() are the pseudo cdrom opens and should not be refcounted.
Could you try this and see if it fixes the problem?
James
===== drivers/scsi/sr.c 1.124 vs edited =====
drivers/scsi/sr.c +0 -1
@@ -544,7 +544,6 @@return 0 ; error_out: -scsi_cd_put (cd);return retval; }
Am Samstag, 29. Januar 2005 15:46 schrieb James Bottomley:
Quoted 3 lines
I wouldn't have noticed this at all since you didn't send it to the scsi list, but fortunately, Al Viro drew it politely to my attention as another example of SCSI refcounting problems.
Sorry, it happening in cdrom_release fooled me into considering it a generic cdrom problem.
Quoted 6 lines
The issue seems to be that we have a spurious
scsi_cd_put()on the error path ofsr_open(). The sr_block_..() functions are the "real" block opens and should be refcounted, the sr_...() are the pseudo cdrom opens and should not be refcounted.Could you try this and see if it fixes the problem?
It fully fixes the problem. Thank you.
Regards
Oliver