aboutsummaryrefslogtreecommitdiff
path: root/sys/dev/ipw
diff options
context:
space:
mode:
authorHans Petter Selasky <hselasky@FreeBSD.org>2020-01-30 10:28:01 +0000
committerHans Petter Selasky <hselasky@FreeBSD.org>2020-01-30 10:28:01 +0000
commitb65f813c1ab99448278961c5ca80dc422b1eae29 (patch)
treee9d3fc16d93a1cb5b2c696d2422cf4d78ae0199c /sys/dev/ipw
parent21c4082de9e2cf9a0fd81a9a981ab06022956847 (diff)
downloadsrc-b65f813c1ab99448278961c5ca80dc422b1eae29.tar.gz
src-b65f813c1ab99448278961c5ca80dc422b1eae29.zip
Widen EPOCH(9) usage in PCI WLAN drivers.
Make sure all occurrences of ieee80211_input_xxx() in sys/dev are covered by a network epoch section. Do not depend on the interrupt handler nor any taskqueues being in a network epoch section. This patch should unbreak the PCI WLAN drivers after r357004. Pointy hat: glebius@ Sponsored by: Mellanox Technologies
Notes
Notes: svn path=/head/; revision=357291
Diffstat (limited to 'sys/dev/ipw')
-rw-r--r--sys/dev/ipw/if_ipw.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/sys/dev/ipw/if_ipw.c b/sys/dev/ipw/if_ipw.c
index 49150f9151bf..99587155ab34 100644
--- a/sys/dev/ipw/if_ipw.c
+++ b/sys/dev/ipw/if_ipw.c
@@ -1159,6 +1159,7 @@ static void
ipw_rx_data_intr(struct ipw_softc *sc, struct ipw_status *status,
struct ipw_soft_bd *sbd, struct ipw_soft_buf *sbuf)
{
+ struct epoch_tracker et;
struct ieee80211com *ic = &sc->sc_ic;
struct mbuf *mnew, *m;
struct ieee80211_node *ni;
@@ -1230,11 +1231,13 @@ ipw_rx_data_intr(struct ipw_softc *sc, struct ipw_status *status,
IPW_UNLOCK(sc);
ni = ieee80211_find_rxnode(ic, mtod(m, struct ieee80211_frame_min *));
+ NET_EPOCH_ENTER(et);
if (ni != NULL) {
(void) ieee80211_input(ni, m, rssi - nf, nf);
ieee80211_free_node(ni);
} else
(void) ieee80211_input_all(ic, m, rssi - nf, nf);
+ NET_EPOCH_EXIT(et);
IPW_LOCK(sc);
bus_dmamap_sync(sc->rbd_dmat, sc->rbd_map, BUS_DMASYNC_PREWRITE);