summaryrefslogtreecommitdiffstats
path: root/sys
diff options
context:
space:
mode:
Diffstat (limited to 'sys')
-rw-r--r--sys/i386/i386/trap.c3
-rw-r--r--sys/kern/kern_sig.c3
2 files changed, 5 insertions, 1 deletions
diff --git a/sys/i386/i386/trap.c b/sys/i386/i386/trap.c
index f5fe14f..7f45106 100644
--- a/sys/i386/i386/trap.c
+++ b/sys/i386/i386/trap.c
@@ -315,6 +315,9 @@ trap(frame)
break;
case T_PAGEFLT: /* page fault */
+ if (td->td_flags & TDF_SA)
+ thread_user_enter(p, td);
+
i = trap_pfault(&frame, TRUE, eva);
#if defined(I586_CPU) && !defined(NO_F00F_HACK)
if (i == -2) {
diff --git a/sys/kern/kern_sig.c b/sys/kern/kern_sig.c
index ab98bb0..26ad4b1 100644
--- a/sys/kern/kern_sig.c
+++ b/sys/kern/kern_sig.c
@@ -1498,7 +1498,8 @@ trapsignal(struct thread *td, int sig, u_long code)
p = td->td_proc;
if (td->td_flags & TDF_SA) {
- thread_user_enter(p, td);
+ if (td->td_mailbox == NULL)
+ thread_user_enter(p, td);
PROC_LOCK(p);
if (td->td_mailbox) {
SIGDELSET(td->td_sigmask, sig);
OpenPOWER on IntegriCloud