OSDN Git Service

ibmvnic: handle inconsistent login with reset
authorDany Madden <drt@linux.ibm.com>
Thu, 26 Nov 2020 00:04:24 +0000 (18:04 -0600)
committerJakub Kicinski <kuba@kernel.org>
Sat, 28 Nov 2020 21:26:48 +0000 (13:26 -0800)
Inconsistent login with the vnicserver is causing the device to be
removed. This does not give the device a chance to recover from error
state. This patch schedules a FATAL reset instead to bring the adapter
up.

Fixes: 032c5e82847a2 ("Driver for IBM System i/p VNIC protocol")
Signed-off-by: Dany Madden <drt@linux.ibm.com>
Signed-off-by: Lijun Pan <ljp@linux.ibm.com>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/ibm/ibmvnic.c

index 2491ebc..b28a979 100644 (file)
@@ -4414,7 +4414,7 @@ static int handle_login_rsp(union ibmvnic_crq *login_rsp_crq,
             adapter->req_rx_add_queues !=
             be32_to_cpu(login_rsp->num_rxadd_subcrqs))) {
                dev_err(dev, "FATAL: Inconsistent login and login rsp\n");
-               ibmvnic_remove(adapter->vdev);
+               ibmvnic_reset(adapter, VNIC_RESET_FATAL);
                return -EIO;
        }
        size_array = (u64 *)((u8 *)(adapter->login_rsp_buf) +