]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - drivers/block/scsi_ioctl.c
Merge iSeries include file move
[linux-2.6-omap-h63xx.git] / drivers / block / scsi_ioctl.c
index abb2df249fd35dbb3242d31285f75586022ab324..382dea7b224c61b87c354fdb425ad7b6f3e19c39 100644 (file)
@@ -123,6 +123,7 @@ static int verify_command(struct file *file, unsigned char *cmd)
                safe_for_read(READ_12),
                safe_for_read(READ_16),
                safe_for_read(READ_BUFFER),
+               safe_for_read(READ_DEFECT_DATA),
                safe_for_read(READ_LONG),
                safe_for_read(INQUIRY),
                safe_for_read(MODE_SENSE),
@@ -167,6 +168,7 @@ static int verify_command(struct file *file, unsigned char *cmd)
                safe_for_write(WRITE_VERIFY_12),
                safe_for_write(WRITE_16),
                safe_for_write(WRITE_LONG),
+               safe_for_write(WRITE_LONG_2),
                safe_for_write(ERASE),
                safe_for_write(GPCMD_MODE_SELECT_10),
                safe_for_write(MODE_SELECT),
@@ -199,15 +201,15 @@ static int verify_command(struct file *file, unsigned char *cmd)
                        return 0;
        }
 
+       /* And root can do any command.. */
+       if (capable(CAP_SYS_RAWIO))
+               return 0;
+
        if (!type) {
                cmd_type[cmd[0]] = CMD_WARNED;
                printk(KERN_WARNING "scsi: unknown opcode 0x%02x\n", cmd[0]);
        }
 
-       /* And root can do any command.. */
-       if (capable(CAP_SYS_RAWIO))
-               return 0;
-
        /* Otherwise fail it with an "Operation not permitted" */
        return -EPERM;
 }