]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
[SCSI] qla2xxx: Correct truncation in return-code status checking.
authorAndrew Vasquez <andrew.vasquez@qlogic.com>
Thu, 5 Mar 2009 19:07:03 +0000 (11:07 -0800)
committerJames Bottomley <James.Bottomley@HansenPartnership.com>
Tue, 10 Mar 2009 14:27:54 +0000 (09:27 -0500)
QLA_* return codes are 'int' in size.  There were still several
legacy check-points which assumed a return-code width of 8-bits.
This could cause incorrect assumptions of 'good' status if a
return of QLA_FUNCTION_TIMEOUT.

Signed-off-by: Andrew Vasquez <andrew.vasquez@qlogic.com>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
drivers/scsi/qla2xxx/qla_init.c
drivers/scsi/qla2xxx/qla_os.c

index e54ab2f1079508f90577a85003d7ef5c30f6280b..87f9abc714604b9927b019ebb67f71cf11f01c5a 100644 (file)
@@ -3435,7 +3435,7 @@ qla2x00_abort_isp(scsi_qla_host_t *vha)
 static int
 qla2x00_restart_isp(scsi_qla_host_t *vha)
 {
-       uint8_t         status = 0;
+       int status = 0;
        uint32_t wait_time;
        struct qla_hw_data *ha = vha->hw;
        struct req_que *req = ha->req_q_map[0];
index 2f5f72531e23108acde73b9174d22af9e584e83c..16c34760b95da354b2165df386b15d3087568262 100644 (file)
@@ -2568,7 +2568,7 @@ qla2x00_do_work(struct scsi_qla_host *vha)
 void qla2x00_relogin(struct scsi_qla_host *vha)
 {
        fc_port_t       *fcport;
-       uint8_t         status;
+       int status;
        uint16_t        next_loopid = 0;
        struct qla_hw_data *ha = vha->hw;