From: Rasesh Mody Date: Sat, 29 Sep 2018 05:42:40 +0000 (+0000) Subject: net/bnx2x: fix call to link handling periodic function X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=0f6ebeee2402441b20e45ea27f0ff2a4fc2c165f;hp=29822ca5cce2613e6de5b0972fc340e856f201c5;p=dpdk.git net/bnx2x: fix call to link handling periodic function If link handling periodic function is allowed to be called in interrupt context, the periodic function can get called too frequently and exhaust the retry credits to check link status. This change makes sure link handling periodic function is not called in interrupt context. Fixes: 540a211084a7 ("bnx2x: driver core") Cc: stable@dpdk.org Signed-off-by: Rasesh Mody --- diff --git a/drivers/net/bnx2x/bnx2x_ethdev.c b/drivers/net/bnx2x/bnx2x_ethdev.c index ae2e60a060..0057843b5d 100644 --- a/drivers/net/bnx2x/bnx2x_ethdev.c +++ b/drivers/net/bnx2x/bnx2x_ethdev.c @@ -131,7 +131,9 @@ bnx2x_interrupt_handler(void *param) PMD_DEBUG_PERIODIC_LOG(INFO, sc, "Interrupt handled"); + atomic_store_rel_long(&sc->periodic_flags, PERIODIC_STOP); bnx2x_interrupt_action(dev); + atomic_store_rel_long(&sc->periodic_flags, PERIODIC_GO); rte_intr_enable(&sc->pci_dev->intr_handle); }