summaryrefslogtreecommitdiffstats
path: root/drivers/scsi
diff options
context:
space:
mode:
authorBart Van Assche <bvanassche@acm.org>2013-06-25 11:27:29 -0400
committerJames Bottomley <JBottomley@Parallels.com>2013-07-08 17:33:47 +0100
commitb2ec76c5926438bda26b0e316246ae0e79bc810a (patch)
tree32040fb98406afdac9cf18a38ec63f1156e8d346 /drivers/scsi
parent6ec6f9094a76aa9e732ede2add6cf32d0c2206e3 (diff)
downloadop-kernel-dev-b2ec76c5926438bda26b0e316246ae0e79bc810a.zip
op-kernel-dev-b2ec76c5926438bda26b0e316246ae0e79bc810a.tar.gz
[SCSI] qla2xxx: Fix qla2xxx_check_risc_status().
Change the 'rval' variable from QLA_FUNCTION_TIMEOUT into QLA_SUCCESS before starting a loop that is only executed if rval is initialized to QLA_SUCCESS. Coverity reported that loop as "dead code". Signed-off-by: Bart Van Assche <bvanassche@acm.org> Signed-off-by: Saurav Kashyap <saurav.kashyap@qlogic.com> Signed-off-by: James Bottomley <JBottomley@Parallels.com>
Diffstat (limited to 'drivers/scsi')
-rw-r--r--drivers/scsi/qla2xxx/qla_isr.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/scsi/qla2xxx/qla_isr.c b/drivers/scsi/qla2xxx/qla_isr.c
index d2a4c75..2d8e7b8 100644
--- a/drivers/scsi/qla2xxx/qla_isr.c
+++ b/drivers/scsi/qla2xxx/qla_isr.c
@@ -2485,6 +2485,7 @@ qla2xxx_check_risc_status(scsi_qla_host_t *vha)
if (rval == QLA_SUCCESS)
goto next_test;
+ rval = QLA_SUCCESS;
WRT_REG_DWORD(&reg->iobase_window, 0x0003);
for (cnt = 100; (RD_REG_DWORD(&reg->iobase_window) & BIT_0) == 0 &&
rval == QLA_SUCCESS; cnt--) {
OpenPOWER on IntegriCloud