riscv trap_pfault: remove unneeded hold of the process around vm_fault() call.
This is re-appearance of the nop code removed from other arches in r287625. Reviewed by: alc (as part of the larger patch), markj Sponsored by: The FreeBSD Foundation MFC after: 1 week DIfferential revision: https://reviews.freebsd.org/D21645
This commit is contained in:
parent
ee41e38d42
commit
6e7abad2fa
@ -217,29 +217,7 @@ data_abort(struct trapframe *frame, int usermode)
|
||||
if (pmap_fault_fixup(map->pmap, va, ftype))
|
||||
goto done;
|
||||
|
||||
if (map != kernel_map) {
|
||||
/*
|
||||
* Keep swapout from messing with us during this
|
||||
* critical time.
|
||||
*/
|
||||
PROC_LOCK(p);
|
||||
++p->p_lock;
|
||||
PROC_UNLOCK(p);
|
||||
|
||||
/* Fault in the user page: */
|
||||
error = vm_fault(map, va, ftype, VM_FAULT_NORMAL);
|
||||
|
||||
PROC_LOCK(p);
|
||||
--p->p_lock;
|
||||
PROC_UNLOCK(p);
|
||||
} else {
|
||||
/*
|
||||
* Don't have to worry about process locking or stacks in the
|
||||
* kernel.
|
||||
*/
|
||||
error = vm_fault(map, va, ftype, VM_FAULT_NORMAL);
|
||||
}
|
||||
|
||||
error = vm_fault(map, va, ftype, VM_FAULT_NORMAL);
|
||||
if (error != KERN_SUCCESS) {
|
||||
if (usermode) {
|
||||
sig = SIGSEGV;
|
||||
|
Loading…
Reference in New Issue
Block a user