diff -ur 2.1.9/linux/drivers/block/ide-cd.c linux/drivers/block/ide-cd.c
--- 2.1.9/linux/drivers/block/ide-cd.c Tue Nov 12 23:31:44 1996
+++ linux/drivers/block/ide-cd.c Tue Nov 12 23:39:36 1996
@@ -2765,13 +2765,19 @@
int ide_cdrom_open (struct inode *ip, struct file *fp, ide_drive_t *drive)
{
- return cdrom_fops.open (ip, fp);
+ int r;
+ MOD_INC_USE_COUNT;
+ r = cdrom_fops.open (ip, fp);
+ if(r)
+ MOD_DEC_USE_COUNT;
+ return r;
}
void ide_cdrom_release (struct inode *inode, struct file *file,
ide_drive_t *drive)
{
cdrom_fops.release (inode, file);
+ MOD_DEC_USE_COUNT;
}
int ide_cdrom_check_media_change (ide_drive_t *drive)
Regards,
Alain