patch-2.4.14 linux/drivers/block/paride/pf.c

Next file: linux/drivers/block/ps2esdi.c
Previous file: linux/drivers/block/paride/pd.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.4.13/linux/drivers/block/paride/pf.c linux/drivers/block/paride/pf.c
@@ -312,6 +312,7 @@
 /* kernel glue structures */
 
 static struct block_device_operations pf_fops = {
+	owner:			THIS_MODULE,
 	open:			pf_open,
 	release:		pf_release,
 	ioctl:			pf_ioctl,
@@ -427,19 +428,13 @@
 
         if ((unit >= PF_UNITS) || (!PF.present)) return -ENODEV;
 
-        MOD_INC_USE_COUNT;
-
 	pf_identify(unit);
 
-	if (PF.media_status == PF_NM) {
-		MOD_DEC_USE_COUNT;
+	if (PF.media_status == PF_NM)
 		return -ENODEV;
-		}
 
-	if ((PF.media_status == PF_RO) && (file ->f_mode & 2)) {
-		MOD_DEC_USE_COUNT;
+	if ((PF.media_status == PF_RO) && (file ->f_mode & 2))
 		return -EROFS;
-		}
 
         PF.access++;
         if (PF.removable) pf_lock(unit,1);
@@ -512,8 +507,6 @@
 
 	if (!PF.access && PF.removable)
 		pf_lock(unit,0);
-
-        MOD_DEC_USE_COUNT;
 
 	return 0;
 

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)