diff options
author | Christof Schmitt <christof.schmitt@de.ibm.com> | 2007-12-20 06:30:23 -0500 |
---|---|---|
committer | James Bottomley <James.Bottomley@HansenPartnership.com> | 2008-01-11 19:29:02 -0500 |
commit | 8627533c115c546649693d68fed6a74762c47d51 (patch) | |
tree | 747a70b12d8796cd1bbde3ae7b04e8243e13be21 /drivers | |
parent | d1ad09db2fd551d49d65ef040591cb9298e70fb6 (diff) |
[SCSI] zfcp: Fix evaluation of port handles in abort handler
According to the FSF spec, word 0 (bytes 0-3) has the handle
specified with the abort command and word 1 (bytes 4-7) has the
handle for the command to be aborted. Fix the if statements
that try to compare those.
Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com>
Signed-off-by: Martin Peschke <mp3@de.ibm.com>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/s390/scsi/zfcp_fsf.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/drivers/s390/scsi/zfcp_fsf.c b/drivers/s390/scsi/zfcp_fsf.c index ff866ebd44ac..e697b1cb6d27 100644 --- a/drivers/s390/scsi/zfcp_fsf.c +++ b/drivers/s390/scsi/zfcp_fsf.c | |||
@@ -1164,8 +1164,8 @@ zfcp_fsf_abort_fcp_command_handler(struct zfcp_fsf_req *new_fsf_req) | |||
1164 | { | 1164 | { |
1165 | int retval = -EINVAL; | 1165 | int retval = -EINVAL; |
1166 | struct zfcp_unit *unit; | 1166 | struct zfcp_unit *unit; |
1167 | unsigned char status_qual = | 1167 | union fsf_status_qual *fsf_stat_qual = |
1168 | new_fsf_req->qtcb->header.fsf_status_qual.word[0]; | 1168 | &new_fsf_req->qtcb->header.fsf_status_qual; |
1169 | 1169 | ||
1170 | if (new_fsf_req->status & ZFCP_STATUS_FSFREQ_ERROR) { | 1170 | if (new_fsf_req->status & ZFCP_STATUS_FSFREQ_ERROR) { |
1171 | /* do not set ZFCP_STATUS_FSFREQ_ABORTSUCCEEDED */ | 1171 | /* do not set ZFCP_STATUS_FSFREQ_ABORTSUCCEEDED */ |
@@ -1178,7 +1178,7 @@ zfcp_fsf_abort_fcp_command_handler(struct zfcp_fsf_req *new_fsf_req) | |||
1178 | switch (new_fsf_req->qtcb->header.fsf_status) { | 1178 | switch (new_fsf_req->qtcb->header.fsf_status) { |
1179 | 1179 | ||
1180 | case FSF_PORT_HANDLE_NOT_VALID: | 1180 | case FSF_PORT_HANDLE_NOT_VALID: |
1181 | if (status_qual >> 4 != status_qual % 0xf) { | 1181 | if (fsf_stat_qual->word[0] != fsf_stat_qual->word[1]) { |
1182 | debug_text_event(new_fsf_req->adapter->erp_dbf, 3, | 1182 | debug_text_event(new_fsf_req->adapter->erp_dbf, 3, |
1183 | "fsf_s_phand_nv0"); | 1183 | "fsf_s_phand_nv0"); |
1184 | /* | 1184 | /* |
@@ -1207,8 +1207,7 @@ zfcp_fsf_abort_fcp_command_handler(struct zfcp_fsf_req *new_fsf_req) | |||
1207 | break; | 1207 | break; |
1208 | 1208 | ||
1209 | case FSF_LUN_HANDLE_NOT_VALID: | 1209 | case FSF_LUN_HANDLE_NOT_VALID: |
1210 | if (status_qual >> 4 != status_qual % 0xf) { | 1210 | if (fsf_stat_qual->word[0] != fsf_stat_qual->word[1]) { |
1211 | /* 2 */ | ||
1212 | debug_text_event(new_fsf_req->adapter->erp_dbf, 3, | 1211 | debug_text_event(new_fsf_req->adapter->erp_dbf, 3, |
1213 | "fsf_s_lhand_nv0"); | 1212 | "fsf_s_lhand_nv0"); |
1214 | /* | 1213 | /* |