patch-2.4.0-test2 linux/drivers/cdrom/cm206.c

Next file: linux/drivers/cdrom/gscd.c
Previous file: linux/drivers/cdrom/cdrom.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.4.0-test1/linux/drivers/cdrom/cm206.c linux/drivers/cdrom/cm206.c
@@ -736,13 +736,14 @@
 
 static int cm206_open(struct cdrom_device_info * cdi, int purpose) 
 {
+  MOD_INC_USE_COUNT;
   if (!cd->openfiles) {		/* reset only first time */
     cd->background=0;
     reset_cm260();
     cd->adapter_last = -1;	/* invalidate adapter memory */
     cd->sector_last = -1;
   }
-  ++cd->openfiles; MOD_INC_USE_COUNT;
+  ++cd->openfiles;
   stats(open);
   return 0;
 }
@@ -757,7 +758,8 @@
     cd->sector_last = -1;	/* Make our internal buffer invalid */
     FIRST_TRACK = 0;		/* No valid disc status */
   }
-  --cd->openfiles; MOD_DEC_USE_COUNT;
+  --cd->openfiles;
+  MOD_DEC_USE_COUNT;
 }
 
 /* Empty buffer empties $sectors$ sectors of the adapter card buffer,
@@ -1258,6 +1260,7 @@
   &cm206_dops,                  /* device operations */
   NULL,				/* link */
   NULL,				/* handle (not used by cm206) */
+  0,				/* devfs handle */
   0,				/* dev */
   0,				/* mask */
   2,				/* maximum speed */

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