From 53829812525551d44793280058aed8219133cb7a Mon Sep 17 00:00:00 2001 From: alfred Date: Tue, 22 May 2001 19:01:26 +0000 Subject: aquire vm mutex in swp_pager_async_iodone. Don't call swp_pager_async_iodone with the mutex held. --- sys/vm/swap_pager.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'sys/vm/swap_pager.c') diff --git a/sys/vm/swap_pager.c b/sys/vm/swap_pager.c index 44f4465..3f9f758 100644 --- a/sys/vm/swap_pager.c +++ b/sys/vm/swap_pager.c @@ -1474,8 +1474,8 @@ swap_pager_putpages(object, m, count, sync, rtvals) */ mtx_unlock(&Giant); - mtx_lock(&vm_mtx); swp_pager_async_iodone(bp); + mtx_lock(&vm_mtx); splx(s); } @@ -1554,7 +1554,7 @@ swp_pager_async_iodone(bp) /* * remove the mapping for kernel virtual */ - + mtx_lock(&vm_mtx); pmap_qremove((vm_offset_t)bp->b_data, bp->b_npages); /* @@ -1689,6 +1689,7 @@ swp_pager_async_iodone(bp) if (object) vm_object_pip_wakeupn(object, bp->b_npages); + mtx_unlock(&vm_mtx); /* * release the physical I/O buffer */ -- cgit v1.1