From: Vikas Chaudhary Date: Thu, 7 Oct 2010 05:48:07 +0000 (-0700) Subject: [SCSI] qla4xxx: honor return status of qla4xxx_hw_reset X-Git-Tag: firefly_0821_release~7613^2~3529^2~64 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=f931c5343f4a500552a3b223b1f840e802d5e1e6;p=firefly-linux-kernel-4.4.55.git [SCSI] qla4xxx: honor return status of qla4xxx_hw_reset Signed-off-by: Vikas Chaudhary Signed-off-by: Ravi Anand Reviewed-by: Mike Christie Signed-off-by: James Bottomley --- diff --git a/drivers/scsi/qla4xxx/ql4_os.c b/drivers/scsi/qla4xxx/ql4_os.c index b24bf969b8a9..6e59b59602a1 100644 --- a/drivers/scsi/qla4xxx/ql4_os.c +++ b/drivers/scsi/qla4xxx/ql4_os.c @@ -935,11 +935,14 @@ int qla4xxx_soft_reset(struct scsi_qla_host *ha) { uint32_t max_wait_time; unsigned long flags = 0; - int status = QLA_ERROR; + int status; uint32_t ctrl_status; - qla4xxx_hw_reset(ha); + status = qla4xxx_hw_reset(ha); + if (status != QLA_SUCCESS) + return status; + status = QLA_ERROR; /* Wait until the Network Reset Intr bit is cleared */ max_wait_time = RESET_INTR_TOV; do {