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 simplify code
details: https://anonhg.NetBSD.org/src/rev/91770b4bb26d
branches: trunk
changeset: 785266:91770b4bb26d
user: yamt <yamt%NetBSD.org@localhost>
date: Wed Mar 06 11:42:18 2013 +0000
description:
simplify code
add a comment
diffstat:
sys/rump/librump/rumpkern/vm.c | 26 ++++++++++++++------------
1 files changed, 14 insertions(+), 12 deletions(-)
diffs (54 lines):
diff -r f77848cc15de -r 91770b4bb26d sys/rump/librump/rumpkern/vm.c
--- a/sys/rump/librump/rumpkern/vm.c Wed Mar 06 11:40:22 2013 +0000
+++ b/sys/rump/librump/rumpkern/vm.c Wed Mar 06 11:42:18 2013 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: vm.c,v 1.135 2013/01/29 21:26:24 para Exp $ */
+/* $NetBSD: vm.c,v 1.136 2013/03/06 11:42:18 yamt 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.135 2013/01/29 21:26:24 para Exp $");
+__KERNEL_RCSID(0, "$NetBSD: vm.c,v 1.136 2013/03/06 11:42:18 yamt Exp $");
#include <sys/param.h>
#include <sys/atomic.h>
@@ -252,6 +252,18 @@
}
/*
+ * uvm_page_locked_p: return true if object associated with page is
+ * locked. this is a weak check for runtime assertions only.
+ */
+
+bool
+uvm_page_locked_p(struct vm_page *pg)
+{
+
+ return mutex_owned(pg->uobject->vmobjlock);
+}
+
+/*
* Misc routines
*/
@@ -361,16 +373,6 @@
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