mirror of
https://github.com/FEX-Emu/linux.git
synced 2024-12-24 18:38:38 +00:00
scsi: be2iscsi: Add missing unlock for mbox_lock
Julia pointed out beiscsi_boot_get_sinfo does not unlock mbox_lock on nonemb_cmd memory allocation failure. Signed-off-by: Jitendra Bhivare <jitendra.bhivare@broadcom.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
This commit is contained in:
parent
bf9b7554f4
commit
658f18d1b8
@ -1085,8 +1085,10 @@ unsigned int beiscsi_boot_get_sinfo(struct beiscsi_hba *phba)
|
||||
nonemb_cmd->va = pci_alloc_consistent(phba->ctrl.pdev,
|
||||
sizeof(nonemb_cmd->size),
|
||||
&nonemb_cmd->dma);
|
||||
if (!nonemb_cmd->va)
|
||||
if (!nonemb_cmd->va) {
|
||||
mutex_unlock(&ctrl->mbox_lock);
|
||||
return 0;
|
||||
}
|
||||
|
||||
req = nonemb_cmd->va;
|
||||
memset(req, 0, sizeof(*req));
|
||||
|
Loading…
Reference in New Issue
Block a user