summaryrefslogtreecommitdiffstats
path: root/sys/net/bpf_zerocopy.c
diff options
context:
space:
mode:
authoralc <alc@FreeBSD.org>2010-05-03 05:41:50 +0000
committeralc <alc@FreeBSD.org>2010-05-03 05:41:50 +0000
commit387e15c45aad8ee988d094eebcf76078a1a4752c (patch)
tree63203bfa05c5420331af4dfe5225e91b49587bae /sys/net/bpf_zerocopy.c
parent46340f07933ebae5d0723021a44679b64cb1013b (diff)
downloadFreeBSD-src-387e15c45aad8ee988d094eebcf76078a1a4752c.zip
FreeBSD-src-387e15c45aad8ee988d094eebcf76078a1a4752c.tar.gz
This is the first step in transitioning responsibility for synchronizing
access to the page's wire_count from the page queues lock to the page lock. Submitted by: kmacy
Diffstat (limited to 'sys/net/bpf_zerocopy.c')
-rw-r--r--sys/net/bpf_zerocopy.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/sys/net/bpf_zerocopy.c b/sys/net/bpf_zerocopy.c
index 3cf4b8d..5ca6978 100644
--- a/sys/net/bpf_zerocopy.c
+++ b/sys/net/bpf_zerocopy.c
@@ -112,11 +112,13 @@ static void
zbuf_page_free(vm_page_t pp)
{
+ vm_page_lock(pp);
vm_page_lock_queues();
vm_page_unwire(pp, 0);
if (pp->wire_count == 0 && pp->object == NULL)
vm_page_free(pp);
vm_page_unlock_queues();
+ vm_page_unlock(pp);
}
/*
OpenPOWER on IntegriCloud