From: mpi Date: Sun, 19 Sep 2021 10:43:26 +0000 (+0000) Subject: Unlock top part of the VM fault handler. X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=ec32250877fbd2cef94427763632d18208af8be5;p=openbsd Unlock top part of the VM fault handler. This is possible now that pmap_extract() is serialized with pmap_remove(). ok sthen@, deraadt@ --- diff --git a/sys/arch/i386/i386/trap.c b/sys/arch/i386/i386/trap.c index e97d0928b47..86ca52a1b1b 100644 --- a/sys/arch/i386/i386/trap.c +++ b/sys/arch/i386/i386/trap.c @@ -1,4 +1,4 @@ -/* $OpenBSD: trap.c,v 1.154 2021/06/20 10:58:36 sthen Exp $ */ +/* $OpenBSD: trap.c,v 1.155 2021/09/19 10:43:26 mpi Exp $ */ /* $NetBSD: trap.c,v 1.95 1996/05/05 06:50:02 mycroft Exp $ */ /*- @@ -126,9 +126,7 @@ upageflttrap(struct trapframe *frame, uint32_t cr2) union sigval sv; int signal, sicode, error; - KERNEL_LOCK(); error = uvm_fault(&p->p_vmspace->vm_map, va, 0, access_type); - KERNEL_UNLOCK(); if (error == 0) { uvm_grow(p, va); @@ -203,9 +201,7 @@ kpageflttrap(struct trapframe *frame, uint32_t cr2) if (curcpu()->ci_inatomic == 0 || map == kernel_map) { onfault = pcb->pcb_onfault; pcb->pcb_onfault = NULL; - KERNEL_LOCK(); error = uvm_fault(map, va, 0, access_type); - KERNEL_UNLOCK(); pcb->pcb_onfault = onfault; if (error == 0 && map != kernel_map)