From 976d7cecd5213021cd0b730b113d3fcd107c13ab Mon Sep 17 00:00:00 2001 From: Gleb Smirnoff Date: Thu, 23 Jan 2020 16:36:58 +0000 Subject: [PATCH] With MSI interrupts bge(4) just schedules taskqueue. Enter the network epoch in the taskqueue handler. Reported by: kib --- sys/dev/bge/if_bge.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/sys/dev/bge/if_bge.c b/sys/dev/bge/if_bge.c index 6199478c4b2..fab4c1bb4bb 100644 --- a/sys/dev/bge/if_bge.c +++ b/sys/dev/bge/if_bge.c @@ -4646,6 +4646,7 @@ bge_msi_intr(void *arg) static void bge_intr_task(void *arg, int pending) { + struct epoch_tracker et; struct bge_softc *sc; if_t ifp; uint32_t status, status_tag; @@ -4688,7 +4689,9 @@ bge_intr_task(void *arg, int pending) sc->bge_rx_saved_considx != rx_prod) { /* Check RX return ring producer/consumer. */ BGE_UNLOCK(sc); + NET_EPOCH_ENTER(et); bge_rxeof(sc, rx_prod, 0); + NET_EPOCH_EXIT(et); BGE_LOCK(sc); } if (if_getdrvflags(ifp) & IFF_DRV_RUNNING) {