]> Pileus Git - ~andy/linux/blobdiff - drivers/block/paride/pt.c
[PATCH] fix missing includes
[~andy/linux] / drivers / block / paride / pt.c
index 5fe8ee86f095bb82a9691fd5792f8411a4797555..715ae5dc88fba4f8a2e1dd191d2bd8d591997d4c 100644 (file)
@@ -146,6 +146,7 @@ static int (*drives[4])[6] = {&drive0, &drive1, &drive2, &drive3};
 #include <linux/slab.h>
 #include <linux/mtio.h>
 #include <linux/device.h>
+#include <linux/sched.h>       /* current, TASK_*, schedule_timeout() */
 
 #include <asm/uaccess.h>
 
@@ -383,8 +384,7 @@ static int pt_atapi(struct pt_unit *tape, char *cmd, int dlen, char *buf, char *
 
 static void pt_sleep(int cs)
 {
-       current->state = TASK_INTERRUPTIBLE;
-       schedule_timeout(cs);
+       schedule_timeout_interruptible(cs);
 }
 
 static int pt_poll_dsc(struct pt_unit *tape, int pause, int tmo, char *msg)
@@ -972,7 +972,7 @@ static int __init pt_init(void)
        devfs_mk_dir("pt");
        for (unit = 0; unit < PT_UNITS; unit++)
                if (pt[unit].present) {
-                       class_device_create(pt_class, MKDEV(major, unit),
+                       class_device_create(pt_class, NULL, MKDEV(major, unit),
                                        NULL, "pt%d", unit);
                        err = devfs_mk_cdev(MKDEV(major, unit),
                                      S_IFCHR | S_IRUSR | S_IWUSR,
@@ -981,7 +981,7 @@ static int __init pt_init(void)
                                class_device_destroy(pt_class, MKDEV(major, unit));
                                goto out_class;
                        }
-                       class_device_create(pt_class, MKDEV(major, unit + 128),
+                       class_device_create(pt_class, NULL, MKDEV(major, unit + 128),
                                        NULL, "pt%dn", unit);
                        err = devfs_mk_cdev(MKDEV(major, unit + 128),
                                      S_IFCHR | S_IRUSR | S_IWUSR,