summaryrefslogtreecommitdiffstats
path: root/sys/vm
diff options
context:
space:
mode:
authoralc <alc@FreeBSD.org>2002-12-15 07:30:51 +0000
committeralc <alc@FreeBSD.org>2002-12-15 07:30:51 +0000
commit7c1f8a0482277ec58ffe23375ce71c08006c77f6 (patch)
tree635010a129a1316d19f59d8324e98fdc11b0bcc4 /sys/vm
parentbbbd1418d8d83da8945525a2d9c25f16ffd15a55 (diff)
downloadFreeBSD-src-7c1f8a0482277ec58ffe23375ce71c08006c77f6.zip
FreeBSD-src-7c1f8a0482277ec58ffe23375ce71c08006c77f6.tar.gz
As per the comments, vm_object_page_remove() now expects its caller to lock
the object (i.e., acquire Giant).
Diffstat (limited to 'sys/vm')
-rw-r--r--sys/vm/vm_object.c10
1 files changed, 2 insertions, 8 deletions
diff --git a/sys/vm/vm_object.c b/sys/vm/vm_object.c
index 68c58aa..22d462c 100644
--- a/sys/vm/vm_object.c
+++ b/sys/vm/vm_object.c
@@ -1698,14 +1698,9 @@ vm_object_page_remove(vm_object_t object, vm_pindex_t start, vm_pindex_t end, bo
vm_pindex_t size;
int all;
- if (object == NULL)
- return;
-
- mtx_lock(&Giant);
- if (object->resident_page_count == 0) {
- mtx_unlock(&Giant);
+ if (object == NULL ||
+ object->resident_page_count == 0)
return;
- }
all = ((end == 0) && (start == 0));
/*
@@ -1784,7 +1779,6 @@ again:
}
vm_page_unlock_queues();
vm_object_pip_wakeup(object);
- mtx_unlock(&Giant);
}
/*
OpenPOWER on IntegriCloud