summaryrefslogtreecommitdiff
path: root/arch/frv/kernel/entry.S
diff options
context:
space:
mode:
authorDavid Howells <dhowells@redhat.com>2012-05-01 19:44:14 +0100
committerAl Viro <viro@zeniv.linux.org.uk>2012-06-01 12:59:18 -0400
commit137c3c469f5a940c8c095b734373581c3a0d3955 (patch)
tree43a01fe1f514429fc915605587ace27b14dccc9f /arch/frv/kernel/entry.S
parentefee984c27b67e3ebef40410f35671997441b57c (diff)
FRV: Prevent syscall exit tracing and notify_resume at end of kernel exceptions
Move the test for kernel mode processing from do_signal() into entry.S to also prevent system call exit tracing and userspace resumption notification handling happening when returning from kernel exceptions. Reported-by: Al Viro <viro@zeniv.linux.org.uk> Signed-off-by: David Howells <dhowells@redhat.com> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'arch/frv/kernel/entry.S')
-rw-r--r--arch/frv/kernel/entry.S4
1 files changed, 3 insertions, 1 deletions
diff --git a/arch/frv/kernel/entry.S b/arch/frv/kernel/entry.S
index 5ba23f715ea5..ff3092c18ca2 100644
--- a/arch/frv/kernel/entry.S
+++ b/arch/frv/kernel/entry.S
@@ -1163,7 +1163,9 @@ __syscall_trace_entry:
# perform syscall exit tracing
__syscall_exit_work:
LEDS 0x6340
- andicc gr4,#_TIF_SYSCALL_TRACE,gr0,icc0
+ andicc gr22,#PSR_PS,gr0,icc1 ; don't handle on return to kernel mode
+ andicc.p gr4,#_TIF_SYSCALL_TRACE,gr0,icc0
+ bne icc1,#0,__entry_return_direct
beq icc0,#1,__entry_work_pending
movsg psr,gr23