From d640400bc5f640b9682b0a903dc3776c9aebba6b Mon Sep 17 00:00:00 2001 From: Gleb Smirnoff Date: Tue, 7 Feb 2006 13:11:13 +0000 Subject: [PATCH] Since em(4) taskqueue is a new network context, we need to conditionally lock Giant here. Submitted by: Andrey V. Elsukov --- sys/dev/em/if_em.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sys/dev/em/if_em.c b/sys/dev/em/if_em.c index 6a24365b28f4..eef8a1f2b8a0 100644 --- a/sys/dev/em/if_em.c +++ b/sys/dev/em/if_em.c @@ -1101,6 +1101,7 @@ em_handle_rxtx(void *context, int pending) struct adapter *adapter = context; struct ifnet *ifp; + NET_LOCK_GIANT(); ifp = adapter->ifp; /* @@ -1120,7 +1121,7 @@ em_handle_rxtx(void *context, int pending) } em_enable_intr(adapter); - return; + NET_UNLOCK_GIANT(); } #endif