Commit 97dec564 authored by Andrew Vasquez's avatar Andrew Vasquez Committed by James Bottomley

[SCSI] qla2xxx: Adjust FCP_RSP response-info field check after TMF completion.

Based on reading of the FCP2/4 specification, the driver cannot
expect the storage device to send FCP_RSP information. Instead,
the driver should interpret the data which is present in the frame
to base decisions on the success or failure of the system.
Signed-off-by: default avatarAndrew Vasquez <andrew.vasquez@qlogic.com>
Signed-off-by: default avatarMadhuranath Iyengar <Madhu.Iyengar@qlogic.com>
Signed-off-by: default avatarJames Bottomley <James.Bottomley@suse.de>
parent 6aef87be
...@@ -2462,22 +2462,19 @@ __qla24xx_issue_tmf(char *name, uint32_t type, struct fc_port *fcport, ...@@ -2462,22 +2462,19 @@ __qla24xx_issue_tmf(char *name, uint32_t type, struct fc_port *fcport,
"-- completion status (%x).\n", __func__, "-- completion status (%x).\n", __func__,
vha->host_no, le16_to_cpu(sts->comp_status))); vha->host_no, le16_to_cpu(sts->comp_status)));
rval = QLA_FUNCTION_FAILED; rval = QLA_FUNCTION_FAILED;
} else if (!(le16_to_cpu(sts->scsi_status) & } else if (le16_to_cpu(sts->scsi_status) &
SS_RESPONSE_INFO_LEN_VALID)) { SS_RESPONSE_INFO_LEN_VALID) {
DEBUG2_3_11(printk("%s(%ld): failed to complete IOCB " if (le32_to_cpu(sts->rsp_data_len) < 4) {
"-- no response info (%x).\n", __func__, vha->host_no, DEBUG2_3_11(printk("%s(%ld): ignoring inconsistent "
le16_to_cpu(sts->scsi_status))); "data length -- not enough response info (%d).\n",
rval = QLA_FUNCTION_FAILED; __func__, vha->host_no,
} else if (le32_to_cpu(sts->rsp_data_len) < 4) { le32_to_cpu(sts->rsp_data_len)));
DEBUG2_3_11(printk("%s(%ld): failed to complete IOCB " } else if (sts->data[3]) {
"-- not enough response info (%d).\n", __func__, DEBUG2_3_11(printk("%s(%ld): failed to complete IOCB "
vha->host_no, le32_to_cpu(sts->rsp_data_len))); "-- response (%x).\n", __func__,
rval = QLA_FUNCTION_FAILED; vha->host_no, sts->data[3]));
} else if (sts->data[3]) { rval = QLA_FUNCTION_FAILED;
DEBUG2_3_11(printk("%s(%ld): failed to complete IOCB " }
"-- response (%x).\n", __func__,
vha->host_no, sts->data[3]));
rval = QLA_FUNCTION_FAILED;
} }
/* Issue marker IOCB. */ /* Issue marker IOCB. */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment