summaryrefslogtreecommitdiff
path: root/sys/arch/hppa
diff options
context:
space:
mode:
authorMichael Shalayeff <mickey@cvs.openbsd.org>2007-03-05 17:14:00 +0000
committerMichael Shalayeff <mickey@cvs.openbsd.org>2007-03-05 17:14:00 +0000
commit2aeaeb17838d109a8a54a6fb610e18a7460cc7ab (patch)
tree149968e678ee8bdebe06abb824a45a6d3aa0966e /sys/arch/hppa
parent22a9427316883f2fd5d92257d92db4d443057a05 (diff)
proper check for [non]user returns to syscall gate page; found by miod@
Diffstat (limited to 'sys/arch/hppa')
-rw-r--r--sys/arch/hppa/hppa/trap.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/arch/hppa/hppa/trap.c b/sys/arch/hppa/hppa/trap.c
index 5a10fdb01bc..07e06fc9659 100644
--- a/sys/arch/hppa/hppa/trap.c
+++ b/sys/arch/hppa/hppa/trap.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: trap.c,v 1.96 2007/01/17 19:30:12 mickey Exp $ */
+/* $OpenBSD: trap.c,v 1.97 2007/03/05 17:13:59 mickey Exp $ */
/*
* Copyright (c) 1998-2004 Michael Shalayeff
@@ -552,8 +552,8 @@ if (kdb_trap (type, va, frame))
* for weird things start to happen on return to the userland
* and also see a note in locore.S:TLABEL(all)
*/
- if ((type & T_USER) &&
- (frame->tf_iioq_head & ~PAGE_MASK) != SYSCALLGATE)
+ if ((type & T_USER) && !(frame->tf_iisq_head == HPPA_SID_KERNEL &&
+ (frame->tf_iioq_head & ~PAGE_MASK) == SYSCALLGATE))
userret(p);
}