qlcnic: Remove redundant unlock in qlcnic_pinit_from_rom
authorDinghao Liu <dinghao.liu@zju.edu.cn>
Fri, 3 Sep 2021 07:35:43 +0000 (15:35 +0800)
committerDavid S. Miller <davem@davemloft.net>
Sat, 4 Sep 2021 09:50:59 +0000 (10:50 +0100)
Previous commit 68233c583ab4 removes the qlcnic_rom_lock()
in qlcnic_pinit_from_rom(), but remains its corresponding
unlock function, which is odd. I'm not very sure whether the
lock is missing, or the unlock is redundant. This bug is
suggested by a static analysis tool, please advise.

Fixes: 68233c583ab4 ("qlcnic: updated reset sequence")
Signed-off-by: Dinghao Liu <dinghao.liu@zju.edu.cn>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/qlogic/qlcnic/qlcnic_init.c

index 3d61a76..09f20c7 100644 (file)
@@ -437,7 +437,6 @@ int qlcnic_pinit_from_rom(struct qlcnic_adapter *adapter)
        QLCWR32(adapter, QLCNIC_CRB_PEG_NET_4 + 0x3c, 1);
        msleep(20);
 
-       qlcnic_rom_unlock(adapter);
        /* big hammer don't reset CAM block on reset */
        QLCWR32(adapter, QLCNIC_ROMUSB_GLB_SW_RESET, 0xfeffffff);