]> git.samba.org - sfrench/cifs-2.6.git/blobdiff - drivers/target/target_core_device.c
Merge tag 'md/4.13-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/shli/md
[sfrench/cifs-2.6.git] / drivers / target / target_core_device.c
index 3ae8fbf01bdf4ccf4728450dbcb6701453d48c98..e8dd6da164b28550f42d4909afed480291cc29ab 100644 (file)
@@ -49,8 +49,8 @@
 #include "target_core_pr.h"
 #include "target_core_ua.h"
 
-DEFINE_MUTEX(device_mutex);
-LIST_HEAD(device_list);
+static DEFINE_MUTEX(device_mutex);
+static LIST_HEAD(device_list);
 static DEFINE_IDR(devices_idr);
 
 static struct se_hba *lun0_hba;
@@ -1183,7 +1183,7 @@ passthrough_parse_cdb(struct se_cmd *cmd,
                }
                if (cdb[0] == PERSISTENT_RESERVE_OUT) {
                        cmd->execute_cmd = target_scsi3_emulate_pr_out;
-                       size = get_unaligned_be16(&cdb[7]);
+                       size = get_unaligned_be32(&cdb[5]);
                        return target_cmd_size_check(cmd, size);
                }
 
@@ -1226,7 +1226,7 @@ passthrough_parse_cdb(struct se_cmd *cmd,
                switch (get_unaligned_be16(&cdb[8])) {
                case READ_32:
                case WRITE_32:
-               case 0x0c: /* WRITE_VERIFY_32 */
+               case WRITE_VERIFY_32:
                case XDWRITEREAD_32:
                        cmd->se_cmd_flags |= SCF_SCSI_DATA_CDB;
                        break;