From f76f330809e0c9e7235584273b5a5d6adccded52 Mon Sep 17 00:00:00 2001 From: Al Viro Date: Wed, 2 May 2012 21:45:12 -0400 Subject: MIPS: Prevent hitting do_notify_resume() with !user_mode(regs). Too late to do anything there... Signed-off-by: Al Viro Signed-off-by: Ralf Baechle --- arch/mips/kernel/entry.S | 3 +++ 1 file changed, 3 insertions(+) (limited to 'arch/mips/kernel/entry.S') diff --git a/arch/mips/kernel/entry.S b/arch/mips/kernel/entry.S index 37acfa036d44..4b0937f19862 100644 --- a/arch/mips/kernel/entry.S +++ b/arch/mips/kernel/entry.S @@ -167,6 +167,9 @@ work_notifysig: # deal with pending signals and FEXPORT(syscall_exit_work_partial) SAVE_STATIC syscall_exit_work: + LONG_L t0, PT_STATUS(sp) # returning to kernel mode? + andi t0, t0, KU_USER + beqz t0, resume_kernel li t0, _TIF_WORK_SYSCALL_EXIT and t0, a2 # a2 is preloaded with TI_FLAGS beqz t0, work_pending # trace bit set? -- cgit v1.2.3