diff options
author | Sritej Velaga <sritej.velaga@qlogic.com> | 2011-07-29 13:30:27 +0000 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2011-08-01 00:12:00 -0700 |
commit | 032a13c7d70f3f40877b298e4c62469980f27a1f (patch) | |
tree | 978285a52c0bc10207ede3da5d0d9fd2833822a3 /drivers/net/qlcnic/qlcnic_main.c | |
parent | 3d46512c642248fcb33f3b3ee2b2a80e2b09cd9c (diff) | |
download | linux-032a13c7d70f3f40877b298e4c62469980f27a1f.tar.gz linux-032a13c7d70f3f40877b298e4c62469980f27a1f.tar.bz2 linux-032a13c7d70f3f40877b298e4c62469980f27a1f.zip |
qlcnic: Fix delay in reset path
Driver should not check for heart beat anymore when FW is hung, rather it
should restart the FW.
Signed-off-by: Sritej Velaga <sritej.velaga@qlogic.com>
Signed-off-by: Anirban Chakraborty <anirban.chakraborty@qlogic.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/qlcnic/qlcnic_main.c')
-rw-r--r-- | drivers/net/qlcnic/qlcnic_main.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/net/qlcnic/qlcnic_main.c b/drivers/net/qlcnic/qlcnic_main.c index 5ca1b562443c..248ebbd43279 100644 --- a/drivers/net/qlcnic/qlcnic_main.c +++ b/drivers/net/qlcnic/qlcnic_main.c @@ -2682,6 +2682,7 @@ qlcnic_clr_all_drv_state(struct qlcnic_adapter *adapter, u8 failed) qlcnic_api_unlock(adapter); err: adapter->fw_fail_cnt = 0; + adapter->flags &= ~QLCNIC_FW_HANG; clear_bit(__QLCNIC_START_FW, &adapter->state); clear_bit(__QLCNIC_RESETTING, &adapter->state); } @@ -2859,6 +2860,7 @@ skip_ack_check: (adapter->flags & QLCNIC_FW_RESET_OWNER)) { QLCDB(adapter, DRV, "Take FW dump\n"); qlcnic_dump_fw(adapter); + adapter->flags |= QLCNIC_FW_HANG; } rtnl_unlock(); @@ -3046,6 +3048,7 @@ attach: done: netif_device_attach(netdev); adapter->fw_fail_cnt = 0; + adapter->flags &= ~QLCNIC_FW_HANG; clear_bit(__QLCNIC_RESETTING, &adapter->state); if (!qlcnic_clr_drv_state(adapter)) @@ -3090,6 +3093,8 @@ qlcnic_check_health(struct qlcnic_adapter *adapter) if (++adapter->fw_fail_cnt < FW_FAIL_THRESH) return 0; + adapter->flags |= QLCNIC_FW_HANG; + qlcnic_dev_request_reset(adapter); if (auto_fw_reset) |