Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/rump/librump/rumpkern Recently uvm_page_locked_p() leake...
details: https://anonhg.NetBSD.org/src/rev/06f843fac537
branches: trunk
changeset: 779372:06f843fac537
user: martin <martin%NetBSD.org@localhost>
date: Wed May 23 14:59:21 2012 +0000
description:
Recently uvm_page_locked_p() leaked outside of uvm/MD code, so rump
needs to provide one.
diffstat:
sys/rump/librump/rumpkern/vm.c | 14 ++++++++++++--
1 files changed, 12 insertions(+), 2 deletions(-)
diffs (35 lines):
diff -r 4f999d8abe19 -r 06f843fac537 sys/rump/librump/rumpkern/vm.c
--- a/sys/rump/librump/rumpkern/vm.c Wed May 23 13:54:37 2012 +0000
+++ b/sys/rump/librump/rumpkern/vm.c Wed May 23 14:59:21 2012 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: vm.c,v 1.125 2012/03/17 17:58:38 hannken Exp $ */
+/* $NetBSD: vm.c,v 1.126 2012/05/23 14:59:21 martin Exp $ */
/*
* Copyright (c) 2007-2011 Antti Kantee. All Rights Reserved.
@@ -41,7 +41,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: vm.c,v 1.125 2012/03/17 17:58:38 hannken Exp $");
+__KERNEL_RCSID(0, "$NetBSD: vm.c,v 1.126 2012/05/23 14:59:21 martin Exp $");
#include <sys/param.h>
#include <sys/atomic.h>
@@ -354,6 +354,16 @@
vm->vm_refcnt = 1;
}
+bool
+uvm_page_locked_p(struct vm_page *pg)
+{
+
+ if (pg->uobject != NULL) {
+ return mutex_owned(pg->uobject->vmobjlock);
+ }
+ return true;
+}
+
void
uvm_pagewire(struct vm_page *pg)
{
Home |
Main Index |
Thread Index |
Old Index