summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobert Watson <rwatson@FreeBSD.org>2004-03-29 00:33:39 +0000
committerRobert Watson <rwatson@FreeBSD.org>2004-03-29 00:33:39 +0000
commit2418d3cceca40d80ac8ad85fbc29a8d3978f9641 (patch)
treee965447e0c71f70c97a3f7241d77ac35c98e321a
parenta1288c786eff5fe8f49539f8d726f56f218356a6 (diff)
Notes
-rw-r--r--sys/net/bpfdesc.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/sys/net/bpfdesc.h b/sys/net/bpfdesc.h
index 46892f6e3a23..58f9d4e7b3fd 100644
--- a/sys/net/bpfdesc.h
+++ b/sys/net/bpfdesc.h
@@ -102,7 +102,10 @@ struct bpf_d {
#define BPFD_LOCK(bd) mtx_lock(&(bd)->bd_mtx)
#define BPFD_UNLOCK(bd) mtx_unlock(&(bd)->bd_mtx)
-#define BPFD_LOCK_ASSERT(bd) mtx_assert(&(bd)->bd_mtx, MA_OWNED)
+#define BPFD_LOCK_ASSERT(bd) do { \
+ mtx_assert(&(bd)->bd_mtx, MA_OWNED); \
+ NET_ASSERT_GIANT(); \
+} while (0)
/* Test whether a BPF is ready for read(). */
#define bpf_ready(bd) \