patch-2.3.46 linux/drivers/cdrom/mcd.c
Next file: linux/drivers/cdrom/mcdx.c
Previous file: linux/drivers/cdrom/gscd.c
Back to the patch index
Back to the overall index
- Lines: 35
- Date:
Wed Feb 16 15:42:05 2000
- Orig file:
v2.3.45/linux/drivers/cdrom/mcd.c
- Orig date:
Thu Feb 10 17:11:07 2000
diff -u --recursive --new-file v2.3.45/linux/drivers/cdrom/mcd.c linux/drivers/cdrom/mcd.c
@@ -86,6 +86,7 @@
#include <linux/timer.h>
#include <linux/fs.h>
#include <linux/kernel.h>
+#include <linux/devfs_fs_kernel.h>
#include <linux/cdrom.h>
#include <linux/ioport.h>
#include <linux/string.h>
@@ -134,7 +135,7 @@
/* #define DOUBLE_QUICK_ONLY */
#define CURRENT_VALID \
-(CURRENT && MAJOR(CURRENT -> rq_dev) == MAJOR_NR && CURRENT -> cmd == READ \
+(!QUEUE_EMPTY && MAJOR(CURRENT -> rq_dev) == MAJOR_NR && CURRENT -> cmd == READ \
&& CURRENT -> sector != -1)
#define MFL_STATUSorDATA (MFL_STATUS | MFL_DATA)
@@ -1156,7 +1157,7 @@
case 2:
release_region(mcd_port,4);
case 1:
- if (unregister_blkdev(MAJOR_NR, "mcd")) {
+ if (devfs_unregister_blkdev(MAJOR_NR, "mcd")) {
printk(KERN_WARNING "Can't unregister major mcd\n");
return;
}
@@ -1181,7 +1182,7 @@
return -EIO;
}
- if (register_blkdev(MAJOR_NR, "mcd", &cdrom_fops) != 0)
+ if (devfs_register_blkdev(MAJOR_NR, "mcd", &cdrom_fops) != 0)
{
printk("Unable to get major %d for Mitsumi CD-ROM\n",
MAJOR_NR);
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)