From b934ed77165c1a5ab368778f35de59a554860fd0 Mon Sep 17 00:00:00 2001 From: imp Date: Wed, 1 Oct 2008 05:47:17 +0000 Subject: Remove critical_enter() and critical_exit(): pmap_growkernel is called with kernel_map->system_mtx held so these aren't needed. Add an assertion to make sure this is the case. Also, fix a minor style(9) nit. Reviewed by: alc@ --- sys/mips/mips/pmap.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'sys/mips') diff --git a/sys/mips/mips/pmap.c b/sys/mips/mips/pmap.c index c5e090d..70eaa31 100644 --- a/sys/mips/mips/pmap.c +++ b/sys/mips/mips/pmap.c @@ -452,9 +452,8 @@ void pmap_init(void) { - if (need_wired_tlb_page_pool) { + if (need_wired_tlb_page_pool) pmap_init_fpage(); - } /* * Initialize the address space (zone) for the pv entries. Set a * high water mark so that the system can recover from excessive @@ -1203,7 +1202,7 @@ pmap_growkernel(vm_offset_t addr) pt_entry_t *pte; int i, req; - critical_enter(); + mtx_assert(&kernel_map->system_mtx, MA_OWNED); if (kernel_vm_end == 0) { kernel_vm_end = VM_MIN_KERNEL_ADDRESS + VM_KERNEL_ALLOC_OFFSET; nkpt = 0; @@ -1276,7 +1275,6 @@ pmap_growkernel(vm_offset_t addr) break; } } - critical_exit(); } /*************************************************** -- cgit v1.1