scsi: qla2xxx: Always check the qla2x00_wait_for_hba_online() return value
[ Upstream commit e6803efae5acd109fad9f2f07dab674563441a53 ] This patch fixes several Coverity complaints about not always checking the qla2x00_wait_for_hba_online() return value. Cc: Himanshu Madhani <hmadhani@marvell.com> Signed-off-by: Bart Van Assche <bvanassche@acm.org> Tested-by: Himanshu Madhani <hmadhani@marvell.com> Reviewed-by: Himanshu Madhani <hmadhani@marvell.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
parent
3cd216d42c
commit
6465a34716
2 changed files with 7 additions and 3 deletions
|
@ -760,7 +760,8 @@ qla2x00_sysfs_write_reset(struct file *filp, struct kobject *kobj,
|
||||||
break;
|
break;
|
||||||
} else {
|
} else {
|
||||||
/* Make sure FC side is not in reset */
|
/* Make sure FC side is not in reset */
|
||||||
qla2x00_wait_for_hba_online(vha);
|
WARN_ON_ONCE(qla2x00_wait_for_hba_online(vha) !=
|
||||||
|
QLA_SUCCESS);
|
||||||
|
|
||||||
/* Issue MPI reset */
|
/* Issue MPI reset */
|
||||||
scsi_block_requests(vha->host);
|
scsi_block_requests(vha->host);
|
||||||
|
|
|
@ -6026,7 +6026,8 @@ qlt_enable_vha(struct scsi_qla_host *vha)
|
||||||
} else {
|
} else {
|
||||||
set_bit(ISP_ABORT_NEEDED, &base_vha->dpc_flags);
|
set_bit(ISP_ABORT_NEEDED, &base_vha->dpc_flags);
|
||||||
qla2xxx_wake_dpc(base_vha);
|
qla2xxx_wake_dpc(base_vha);
|
||||||
qla2x00_wait_for_hba_online(base_vha);
|
WARN_ON_ONCE(qla2x00_wait_for_hba_online(base_vha) !=
|
||||||
|
QLA_SUCCESS);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
EXPORT_SYMBOL(qlt_enable_vha);
|
EXPORT_SYMBOL(qlt_enable_vha);
|
||||||
|
@ -6056,7 +6057,9 @@ static void qlt_disable_vha(struct scsi_qla_host *vha)
|
||||||
|
|
||||||
set_bit(ISP_ABORT_NEEDED, &vha->dpc_flags);
|
set_bit(ISP_ABORT_NEEDED, &vha->dpc_flags);
|
||||||
qla2xxx_wake_dpc(vha);
|
qla2xxx_wake_dpc(vha);
|
||||||
qla2x00_wait_for_hba_online(vha);
|
if (qla2x00_wait_for_hba_online(vha) != QLA_SUCCESS)
|
||||||
|
ql_dbg(ql_dbg_tgt, vha, 0xe081,
|
||||||
|
"qla2x00_wait_for_hba_online() failed\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
Loading…
Add table
Reference in a new issue