aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJake Burkholder <jake@FreeBSD.org>2002-04-20 17:28:08 +0000
committerJake Burkholder <jake@FreeBSD.org>2002-04-20 17:28:08 +0000
commit9ba847abf388c3ee10d9a5f48a6c715bdd7e1a55 (patch)
tree0f620d2d59285cce64ffd68ff6129e195b48853e
parent88ef0373918fb54814238448c23b301edddf3029 (diff)
Notes
-rw-r--r--sys/sparc64/sparc64/trap.c18
1 files changed, 2 insertions, 16 deletions
diff --git a/sys/sparc64/sparc64/trap.c b/sys/sparc64/sparc64/trap.c
index ff974a60742c9..0d635e1a859c1 100644
--- a/sys/sparc64/sparc64/trap.c
+++ b/sys/sparc64/sparc64/trap.c
@@ -450,8 +450,6 @@ trap_pfault(struct thread *td, struct trapframe *tf)
*/
vm = p->p_vmspace;
- mtx_lock(&Giant);
-
/*
* Keep swapout from messing with us during this
* critical time.
@@ -460,17 +458,8 @@ trap_pfault(struct thread *td, struct trapframe *tf)
++p->p_lock;
PROC_UNLOCK(p);
- /*
- * Grow the stack if necessary. vm_map_growstack only
- * fails if the va falls into a growable stack region
- * and the stack growth fails. If it succeeds, or the
- * va was not within a growable stack region, fault in
- * the user page.
- */
- if (vm_map_growstack(p, va) != KERN_SUCCESS)
- rv = KERN_FAILURE;
- else
- rv = vm_fault(&vm->vm_map, va, prot, flags);
+ /* Fault in the user page. */
+ rv = vm_fault(&vm->vm_map, va, prot, flags);
/*
* Now the process can be swapped again.
@@ -487,15 +476,12 @@ trap_pfault(struct thread *td, struct trapframe *tf)
KASSERT(tf->tf_tstate & TSTATE_PRIV,
("trap_pfault: fault on nucleus context from user mode"));
- mtx_lock(&Giant);
-
/*
* Don't have to worry about process locking or stacks in the
* kernel.
*/
rv = vm_fault(kernel_map, va, prot, VM_FAULT_NORMAL);
}
- mtx_unlock(&Giant);
CTR3(KTR_TRAP, "trap_pfault: return td=%p va=%#lx rv=%d",
td, va, rv);