summaryrefslogtreecommitdiff
path: root/drivers/net/bnxt/bnxt_rxr.c
diff options
context:
space:
mode:
authorKalesh AP <kalesh-anakkur.purayil@broadcom.com>2019-10-24 13:14:28 +0530
committerFerruh Yigit <ferruh.yigit@intel.com>2019-10-25 19:23:23 +0200
commitbfbfe4aaa1ebee405d497dfef7346e220c99590b (patch)
treee89a3985377a7cef3818065d8321edd78c93e173 /drivers/net/bnxt/bnxt_rxr.c
parent8937597cfe7caf6a2ca4353b5be6f828e114f600 (diff)
downloaddpdk-next-eventdev-bfbfe4aaa1ebee405d497dfef7346e220c99590b.zip
dpdk-next-eventdev-bfbfe4aaa1ebee405d497dfef7346e220c99590b.tar.gz
dpdk-next-eventdev-bfbfe4aaa1ebee405d497dfef7346e220c99590b.tar.xz
net/bnxt: add more checks during firmware reset
Added check for fw reset or fw errors in few more routines. While processing the events, if it is fw fatal or non-fatal event, there is no need to process the remaining events as driver triggers recovery mechanism. Also added a check for fw reset or fatal error in bnxt_disable_int() to avoid bar access in case of fatal error. Fixes: be14720def9c ("net/bnxt: support FW reset") Signed-off-by: Kalesh AP <kalesh-anakkur.purayil@broadcom.com> Signed-off-by: Somnath Kotur <somnath.kotur@broadcom.com> Reviewed-by: Rahul Gupta <rahul.gupta@broadcom.com> Reviewed-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
Diffstat (limited to 'drivers/net/bnxt/bnxt_rxr.c')
-rw-r--r--drivers/net/bnxt/bnxt_rxr.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/net/bnxt/bnxt_rxr.c b/drivers/net/bnxt/bnxt_rxr.c
index 03dae57..ee1444c 100644
--- a/drivers/net/bnxt/bnxt_rxr.c
+++ b/drivers/net/bnxt/bnxt_rxr.c
@@ -639,6 +639,9 @@ uint16_t bnxt_recv_pkts(void *rx_queue, struct rte_mbuf **rx_pkts,
evt =
bnxt_event_hwrm_resp_handler(rxq->bp,
(struct cmpl_base *)rxcmp);
+ /* If the async event is Fatal error, return */
+ if (unlikely(is_bnxt_in_error(rxq->bp)))
+ goto done;
}
raw_cons = NEXT_RAW_CMP(raw_cons);