summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJustus Winter <4winter@informatik.uni-hamburg.de>2015-08-12 15:45:42 +0200
committerJustus Winter <4winter@informatik.uni-hamburg.de>2015-08-12 15:46:45 +0200
commitf0eb90bfbdc80633620064df47b3089457b65d67 (patch)
tree782c443f73d6e31f505155bf23934adad2a6d7f2
parent0f3ec488afa427ce350493a2868cd7ebff04c42a (diff)
fix vm_page initializationpmm-2015-08-12
-rw-r--r--vm/vm_page.c3
-rw-r--r--vm/vm_resident.c5
2 files changed, 5 insertions, 3 deletions
diff --git a/vm/vm_page.c b/vm/vm_page.c
index fca80b3..7bae124 100644
--- a/vm/vm_page.c
+++ b/vm/vm_page.c
@@ -200,7 +200,6 @@ vm_page_initialize(struct vm_page *page, unsigned short seg_index,
page->phys_addr = pa;
}
-/* XXX legacy mach interface */
void
vm_page_init_mach(struct vm_page *page)
{
@@ -209,11 +208,13 @@ vm_page_init_mach(struct vm_page *page)
sizeof *page - VM_PAGE_HEADER_SIZE);
}
+/* XXX legacy mach interface */
void
vm_page_init(vm_page_t mem,
vm_offset_t phys_addr)
{
vm_page_initialize(mem, mem->seg_index, phys_addr);
+ vm_page_init_mach(mem);
}
void
diff --git a/vm/vm_resident.c b/vm/vm_resident.c
index 88880ef..dc4388d 100644
--- a/vm/vm_resident.c
+++ b/vm/vm_resident.c
@@ -468,8 +468,9 @@ vm_page_t vm_page_grab_fictitious(void)
if (m != VM_PAGE_NULL) {
vm_page_fictitious_count--;
vm_page_queue_fictitious = (vm_page_t) m->pageq.next;
- assert(m->fictitious);
- assert(! m->tabled);
+ /* XXX is this re-initialization really needed ? */
+ vm_page_init(m, vm_page_fictitious_addr);
+ m->fictitious = TRUE;
}
simple_unlock(&vm_page_queue_free_lock);
return m;