From 163a9eabd15682886036ee17e7bf50276cfadc44 Mon Sep 17 00:00:00 2001 From: alc Date: Tue, 2 Mar 2004 08:25:58 +0000 Subject: Modify contigmalloc1() so that the free page queues lock is not held when vm_page_free() is called. The problem with holding this lock is that it is a spin lock and vm_page_free() may attempt the acquisition of a different default-type lock. --- sys/vm/vm_page.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'sys/vm/vm_page.c') diff --git a/sys/vm/vm_page.c b/sys/vm/vm_page.c index 853178a..ae1673a 100644 --- a/sys/vm/vm_page.c +++ b/sys/vm/vm_page.c @@ -206,12 +206,11 @@ vm_page_startup(vm_offset_t starta, vm_offset_t enda, vm_offset_t vaddr) end = phys_avail[biggestone+1]; /* - * Initialize the locks. Recursive acquisition of the vm page - * queue free mutex begins in contigmalloc1(). + * Initialize the locks. */ mtx_init(&vm_page_queue_mtx, "vm page queue mutex", NULL, MTX_DEF); mtx_init(&vm_page_queue_free_mtx, "vm page queue free mutex", NULL, - MTX_RECURSE | MTX_SPIN); + MTX_SPIN); /* * Initialize the queue headers for the free queue, the active queue -- cgit v1.1