o Lock some page queue accesses, in particular, those by vm_page_unwire().

This commit is contained in:
Alan Cox 2002-07-13 19:48:54 +00:00
parent d04f03fc63
commit 753492f404
2 changed files with 8 additions and 0 deletions

View File

@ -1002,9 +1002,11 @@ pmap_dispose_thread(td)
m = vm_page_lookup(ksobj, i);
if (m == NULL)
panic("pmap_dispose_thread: kstack already missing?");
vm_page_lock_queues();
vm_page_busy(m);
vm_page_unwire(m, 0);
vm_page_free(m);
vm_page_unlock_queues();
}
/*
* Free the space that this stack was mapped to in the kernel
@ -1037,8 +1039,10 @@ pmap_swapout_thread(td)
m = vm_page_lookup(ksobj, i);
if (m == NULL)
panic("pmap_swapout_thread: kstack already missing?");
vm_page_lock_queues();
vm_page_dirty(m);
vm_page_unwire(m, 0);
vm_page_unlock_queues();
}
}

View File

@ -1002,9 +1002,11 @@ pmap_dispose_thread(td)
m = vm_page_lookup(ksobj, i);
if (m == NULL)
panic("pmap_dispose_thread: kstack already missing?");
vm_page_lock_queues();
vm_page_busy(m);
vm_page_unwire(m, 0);
vm_page_free(m);
vm_page_unlock_queues();
}
/*
* Free the space that this stack was mapped to in the kernel
@ -1037,8 +1039,10 @@ pmap_swapout_thread(td)
m = vm_page_lookup(ksobj, i);
if (m == NULL)
panic("pmap_swapout_thread: kstack already missing?");
vm_page_lock_queues();
vm_page_dirty(m);
vm_page_unwire(m, 0);
vm_page_unlock_queues();
}
}