The patch titled signals: convert the X86_32 code to use set_current_blocked() has been added to the -mm tree. Its filename is signals-convert-the-x86_32-code-to-use-set_current_blocked.patch Before you just go and hit "reply", please: a) Consider who else should be cc'ed b) Prefer to cc a suitable mailing list as well c) Ideally: find the original patch on the mailing list and do a reply-to-all to that, adding suitable additional cc's *** Remember to use Documentation/SubmitChecklist when testing your code *** See http://userweb.kernel.org/~akpm/stuff/added-to-mm.txt to find out what to do about this The current -mm tree may be found at http://userweb.kernel.org/~akpm/mmotm/ ------------------------------------------------------ Subject: signals: convert the X86_32 code to use set_current_blocked() From: Oleg Nesterov <oleg@xxxxxxxxxx> sys_sigsuspend() and sys_sigreturn() change ->blocked directly. This is not correct, see the changelog in e6fa16ab "signal: sigprocmask() should do retarget_shared_pending()" Change them to use set_current_blocked(). Signed-off-by: Oleg Nesterov <oleg@xxxxxxxxxx> Reviewed-by: Matt Fleming <matt.fleming@xxxxxxxxxxxxxxx> Cc: Tejun Heo <tj@xxxxxxxxxx> Cc: "H. Peter Anvin" <hpa@xxxxxxxxx> Cc: Thomas Gleixner <tglx@xxxxxxxxxxxxx> Cc: Ingo Molnar <mingo@xxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- arch/x86/kernel/signal.c | 18 ++++++++---------- 1 file changed, 8 insertions(+), 10 deletions(-) diff -puN arch/x86/kernel/signal.c~signals-convert-the-x86_32-code-to-use-set_current_blocked arch/x86/kernel/signal.c --- a/arch/x86/kernel/signal.c~signals-convert-the-x86_32-code-to-use-set_current_blocked +++ a/arch/x86/kernel/signal.c @@ -485,17 +485,18 @@ static int __setup_rt_frame(int sig, str asmlinkage int sys_sigsuspend(int history0, int history1, old_sigset_t mask) { - mask &= _BLOCKABLE; - spin_lock_irq(¤t->sighand->siglock); + sigset_t blocked; + current->saved_sigmask = current->blocked; - siginitset(¤t->blocked, mask); - recalc_sigpending(); - spin_unlock_irq(¤t->sighand->siglock); + + mask &= _BLOCKABLE; + siginitset(&blocked, mask); + set_current_blocked(&blocked); current->state = TASK_INTERRUPTIBLE; schedule(); - set_restore_sigmask(); + set_restore_sigmask(); return -ERESTARTNOHAND; } @@ -572,10 +573,7 @@ unsigned long sys_sigreturn(struct pt_re goto badframe; sigdelsetmask(&set, ~_BLOCKABLE); - spin_lock_irq(¤t->sighand->siglock); - current->blocked = set; - recalc_sigpending(); - spin_unlock_irq(¤t->sighand->siglock); + set_current_blocked(&set); if (restore_sigcontext(regs, &frame->sc, &ax)) goto badframe; _ Patches currently in -mm which might be from oleg@xxxxxxxxxx are xtensa-prevent-arbitrary-read-in-ptrace.patch xtensa-prevent-arbitrary-read-in-ptrace-fix.patch linux-next.patch ptrace-unify-show_regs-prototype.patch ptrace-unify-show_regs-prototype-fix.patch signals-convert-the-ia32_emulation-code-to-use-set_current_blocked.patch signals-convert-the-x86_32-code-to-use-set_current_blocked.patch coredump-use-task-comm-instead-of-unknown.patch do_coredump-fix-the-ispipe-error-check.patch ipc-introduce-shm_rmid_forced-sysctl.patch ipc-introduce-shm_rmid_forced-sysctl-fix-2.patch ipc-introduce-shm_rmid_forced-sysctl-testing.patch -- To unsubscribe from this list: send the line "unsubscribe mm-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html