From 415d04d08fec74b226c92c1fb54ad117c9c6bac4 Mon Sep 17 00:00:00 2001 From: Al Viro Date: Thu, 26 Apr 2012 18:17:28 -0400 Subject: unicore32: if there's no handler we need to restore sigmask, syscall or no syscall Signed-off-by: Al Viro --- arch/unicore32/kernel/signal.c | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) (limited to 'arch/unicore32') diff --git a/arch/unicore32/kernel/signal.c b/arch/unicore32/kernel/signal.c index 72d953190419..7754df6ef7d4 100644 --- a/arch/unicore32/kernel/signal.c +++ b/arch/unicore32/kernel/signal.c @@ -447,15 +447,12 @@ static void do_signal(struct pt_regs *regs, int syscall) regs->UCreg_00 == -ERESTARTNOINTR) { setup_syscall_restart(regs); } - - /* If there's no signal to deliver, we just put the saved - * sigmask back. - */ - if (test_thread_flag(TIF_RESTORE_SIGMASK)) { - clear_thread_flag(TIF_RESTORE_SIGMASK); - sigprocmask(SIG_SETMASK, ¤t->saved_sigmask, NULL); - } } + /* If there's no signal to deliver, we just put the saved + * sigmask back. + */ + if (test_and_clear_thread_flag(TIF_RESTORE_SIGMASK)) + set_current_blocked(¤t->saved_sigmask); } asmlinkage void do_notify_resume(struct pt_regs *regs, -- cgit v1.2.3