Commit 4a41cdf9 authored by Heiko Carstens's avatar Heiko Carstens Committed by Linus Torvalds

[PATCH] powerpc: Fix sigmask handling in sys_sigsuspend.

Better save the sigmask instead of throwing it away so it can be restored.
Signed-off-by: default avatarHeiko Carstens <heiko.carstens@de.ibm.com>
Acked-by: default avatarBenjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Paul Mackerras <paulus@samba.org>
Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
parent e6199788
...@@ -254,11 +254,9 @@ int do_signal(sigset_t *oldset, struct pt_regs *regs); ...@@ -254,11 +254,9 @@ int do_signal(sigset_t *oldset, struct pt_regs *regs);
*/ */
long sys_sigsuspend(old_sigset_t mask) long sys_sigsuspend(old_sigset_t mask)
{ {
sigset_t saveset;
mask &= _BLOCKABLE; mask &= _BLOCKABLE;
spin_lock_irq(&current->sighand->siglock); spin_lock_irq(&current->sighand->siglock);
saveset = current->blocked; current->saved_sigmask = current->blocked;
siginitset(&current->blocked, mask); siginitset(&current->blocked, mask);
recalc_sigpending(); recalc_sigpending();
spin_unlock_irq(&current->sighand->siglock); spin_unlock_irq(&current->sighand->siglock);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment