]> git.baikalelectronics.ru Git - kernel.git/commit
net: qlcnic: add missed unlock in qlcnic_83xx_flash_read32
authorDinghao Liu <dinghao.liu@zju.edu.cn>
Mon, 16 Aug 2021 13:14:04 +0000 (21:14 +0800)
committerJakub Kicinski <kuba@kernel.org>
Tue, 17 Aug 2021 15:27:31 +0000 (08:27 -0700)
commit992ef212505cb14487ba3bd3592467587463b8c6
tree496f7ce7d00db659d2f37943be759cfb91cf4669
parent274979fcf34e3219bfec605b1925ee9a821f28a8
net: qlcnic: add missed unlock in qlcnic_83xx_flash_read32

qlcnic_83xx_unlock_flash() is called on all paths after we call
qlcnic_83xx_lock_flash(), except for one error path on failure
of QLCRD32(), which may cause a deadlock. This bug is suggested
by a static analysis tool, please advise.

Fixes: 72adeddff2af2 ("qlcnic: flash template based firmware reset recovery")
Signed-off-by: Dinghao Liu <dinghao.liu@zju.edu.cn>
Link: https://lore.kernel.org/r/20210816131405.24024-1-dinghao.liu@zju.edu.cn
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/qlogic/qlcnic/qlcnic_83xx_hw.c