summaryrefslogtreecommitdiff
path: root/sys/arch/alpha
diff options
context:
space:
mode:
authorMiod Vallat <miod@cvs.openbsd.org>2004-12-06 20:12:26 +0000
committerMiod Vallat <miod@cvs.openbsd.org>2004-12-06 20:12:26 +0000
commit120d8ac9c11b65f4f5ea455c3ece1377f7c9f5e9 (patch)
treec6379e62ac806f3ca515fd801b4b656553be0348 /sys/arch/alpha
parente8f58ee282d9d19ac7b1f6c8c781fd5af48073cc (diff)
Use uvm_grow() to account for stack growth, rather than home-grown code
or nothing. Inspired by a similar recent change in NetBSD.
Diffstat (limited to 'sys/arch/alpha')
-rw-r--r--sys/arch/alpha/alpha/trap.c13
1 files changed, 4 insertions, 9 deletions
diff --git a/sys/arch/alpha/alpha/trap.c b/sys/arch/alpha/alpha/trap.c
index 23e7aa56e74..a21d1de511c 100644
--- a/sys/arch/alpha/alpha/trap.c
+++ b/sys/arch/alpha/alpha/trap.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: trap.c,v 1.43 2003/11/13 08:19:20 miod Exp $ */
+/* $OpenBSD: trap.c,v 1.44 2004/12/06 20:12:21 miod Exp $ */
/* $NetBSD: trap.c,v 1.52 2000/05/24 16:48:33 thorpej Exp $ */
/*-
@@ -481,15 +481,10 @@ do_fault:
* we need to reflect that as an access error.
*/
if (map != kernel_map &&
- (caddr_t)va >= vm->vm_maxsaddr &&
- va < USRSTACK) {
+ (caddr_t)va >= vm->vm_maxsaddr) {
if (rv == 0) {
- unsigned nss;
-
- nss = btoc(USRSTACK -
- (unsigned long)va);
- if (nss > vm->vm_ssize)
- vm->vm_ssize = nss;
+ if (p != NULL)
+ uvm_grow(p, va);
} else if (rv == EACCES)
rv = EFAULT;
}