summaryrefslogtreecommitdiffstats
path: root/sys/dev/e1000/if_em.c
diff options
context:
space:
mode:
authorjfv <jfv@FreeBSD.org>2010-04-10 19:25:55 +0000
committerjfv <jfv@FreeBSD.org>2010-04-10 19:25:55 +0000
commitc1e0bdf67c05cbc608f667819dde5030b8348fa7 (patch)
treeb7f542fac077fa671c7d26ff0998a4ce3926db5f /sys/dev/e1000/if_em.c
parent76d6c015c73ed644251aad688c3238ce1aa2fedc (diff)
downloadFreeBSD-src-c1e0bdf67c05cbc608f667819dde5030b8348fa7.zip
FreeBSD-src-c1e0bdf67c05cbc608f667819dde5030b8348fa7.tar.gz
The lock move in rxeof necessitated a couple
more places to do the locking, fixes a panic.
Diffstat (limited to 'sys/dev/e1000/if_em.c')
-rw-r--r--sys/dev/e1000/if_em.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/sys/dev/e1000/if_em.c b/sys/dev/e1000/if_em.c
index 091f7aa..834e676 100644
--- a/sys/dev/e1000/if_em.c
+++ b/sys/dev/e1000/if_em.c
@@ -1371,7 +1371,9 @@ em_poll(struct ifnet *ifp, enum poll_cmd cmd, int count)
}
EM_CORE_UNLOCK(adapter);
+ EM_RX_LOCK(rxr);
rx_done = em_rxeof(rxr, count);
+ EM_RX_UNLOCK(rxr);
EM_TX_LOCK(txr);
em_txeof(txr);
@@ -1447,7 +1449,10 @@ em_handle_que(void *context, int pending)
if (ifp->if_drv_flags & IFF_DRV_RUNNING) {
+ EM_RX_LOCK(rxr);
more_rx = em_rxeof(rxr, adapter->rx_process_limit);
+ EM_RX_UNLOCK(rxr);
+
EM_TX_LOCK(txr);
em_txeof(txr);
#ifdef EM_MULTIQUEUE
OpenPOWER on IntegriCloud