scsi: qla2xxx: Fix error return code in qla82xx_write_flash_dword()
[ Upstream commit5cb289bf2d] Fix to return a negative error code from the error handling case instead of 0 as done elsewhere in this function. Link: https://lore.kernel.org/r/20210514090952.6715-1-thunder.leizhen@huawei.com Fixes:a9083016a5("[SCSI] qla2xxx: Add ISP82XX support.") Reported-by: Hulk Robot <hulkci@huawei.com> Reviewed-by: Himanshu Madhani <himanshu.madhani@oracle.com> Signed-off-by: Zhen Lei <thunder.leizhen@huawei.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
a6362a7375
commit
8170c2039c
1 changed files with 2 additions and 1 deletions
|
|
@ -1066,7 +1066,8 @@ qla82xx_write_flash_dword(struct qla_hw_data *ha, uint32_t flashaddr,
|
|||
return ret;
|
||||
}
|
||||
|
||||
if (qla82xx_flash_set_write_enable(ha))
|
||||
ret = qla82xx_flash_set_write_enable(ha);
|
||||
if (ret < 0)
|
||||
goto done_write;
|
||||
|
||||
qla82xx_wr_32(ha, QLA82XX_ROMUSB_ROM_WDATA, data);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue