diff options
author | Roland Dreier <roland@purestorage.com> | 2011-12-06 13:02:09 -0500 |
---|---|---|
committer | Herton Ronaldo Krzesinski <herton.krzesinski@canonical.com> | 2012-02-13 15:14:58 -0500 |
commit | d8499850367672fba6fe6dfb2afd404a733e5c9c (patch) | |
tree | db5ea51413194936d1144f68b6011fc55b40b5d7 | |
parent | fbb564357c7ac5c43479407b3c25001f432b95ac (diff) |
target: Set response format in INQUIRY response
BugLink: http://bugs.launchpad.net/bugs/922799
commit ce136176fea522fc8f4c16dcae7e8ed1d890ca39 upstream.
Current SCSI specs say that the "response format" field in the standard
INQUIRY response should be set to 2, and all the real SCSI devices I
have do put 2 here. So let's do that too.
Signed-off-by: Roland Dreier <roland@purestorage.com>
Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-rw-r--r-- | drivers/target/target_core_cdb.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/drivers/target/target_core_cdb.c b/drivers/target/target_core_cdb.c index 7f19c8b7b84..f044d45fc58 100644 --- a/drivers/target/target_core_cdb.c +++ b/drivers/target/target_core_cdb.c | |||
@@ -84,6 +84,18 @@ target_emulate_inquiry_std(struct se_cmd *cmd) | |||
84 | buf[2] = dev->transport->get_device_rev(dev); | 84 | buf[2] = dev->transport->get_device_rev(dev); |
85 | 85 | ||
86 | /* | 86 | /* |
87 | * NORMACA and HISUP = 0, RESPONSE DATA FORMAT = 2 | ||
88 | * | ||
89 | * SPC4 says: | ||
90 | * A RESPONSE DATA FORMAT field set to 2h indicates that the | ||
91 | * standard INQUIRY data is in the format defined in this | ||
92 | * standard. Response data format values less than 2h are | ||
93 | * obsolete. Response data format values greater than 2h are | ||
94 | * reserved. | ||
95 | */ | ||
96 | buf[3] = 2; | ||
97 | |||
98 | /* | ||
87 | * Enable SCCS and TPGS fields for Emulated ALUA | 99 | * Enable SCCS and TPGS fields for Emulated ALUA |
88 | */ | 100 | */ |
89 | if (T10_ALUA(dev->se_sub_dev)->alua_type == SPC3_ALUA_EMULATED) | 101 | if (T10_ALUA(dev->se_sub_dev)->alua_type == SPC3_ALUA_EMULATED) |