aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/qla2xxx
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/scsi/qla2xxx')
-rw-r--r--drivers/scsi/qla2xxx/qla_isr.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/drivers/scsi/qla2xxx/qla_isr.c b/drivers/scsi/qla2xxx/qla_isr.c
index 798b7e87e2e1..53cbaffbb78c 100644
--- a/drivers/scsi/qla2xxx/qla_isr.c
+++ b/drivers/scsi/qla2xxx/qla_isr.c
@@ -977,13 +977,13 @@ qla2x00_status_entry(scsi_qla_host_t *ha, void *pkt)
977 break; 977 break;
978 978
979 /* Copy Sense Data into sense buffer. */ 979 /* Copy Sense Data into sense buffer. */
980 memset(cp->sense_buffer, 0, sizeof(cp->sense_buffer)); 980 memset(cp->sense_buffer, 0, SCSI_SENSE_BUFFERSIZE);
981 981
982 if (!(scsi_status & SS_SENSE_LEN_VALID)) 982 if (!(scsi_status & SS_SENSE_LEN_VALID))
983 break; 983 break;
984 984
985 if (sense_len >= sizeof(cp->sense_buffer)) 985 if (sense_len >= SCSI_SENSE_BUFFERSIZE)
986 sense_len = sizeof(cp->sense_buffer); 986 sense_len = SCSI_SENSE_BUFFERSIZE;
987 987
988 CMD_ACTUAL_SNSLEN(cp) = sense_len; 988 CMD_ACTUAL_SNSLEN(cp) = sense_len;
989 sp->request_sense_length = sense_len; 989 sp->request_sense_length = sense_len;
@@ -1061,13 +1061,13 @@ qla2x00_status_entry(scsi_qla_host_t *ha, void *pkt)
1061 break; 1061 break;
1062 1062
1063 /* Copy Sense Data into sense buffer */ 1063 /* Copy Sense Data into sense buffer */
1064 memset(cp->sense_buffer, 0, sizeof(cp->sense_buffer)); 1064 memset(cp->sense_buffer, 0, SCSI_SENSE_BUFFERSIZE);
1065 1065
1066 if (!(scsi_status & SS_SENSE_LEN_VALID)) 1066 if (!(scsi_status & SS_SENSE_LEN_VALID))
1067 break; 1067 break;
1068 1068
1069 if (sense_len >= sizeof(cp->sense_buffer)) 1069 if (sense_len >= SCSI_SENSE_BUFFERSIZE)
1070 sense_len = sizeof(cp->sense_buffer); 1070 sense_len = SCSI_SENSE_BUFFERSIZE;
1071 1071
1072 CMD_ACTUAL_SNSLEN(cp) = sense_len; 1072 CMD_ACTUAL_SNSLEN(cp) = sense_len;
1073 sp->request_sense_length = sense_len; 1073 sp->request_sense_length = sense_len;