]> git.neil.brown.name Git - history.git/commit
[PATCH] ppc64: fix signal mask restoration when delivery fails
authorPaul Mackerras <paulus@samba.org>
Fri, 17 Dec 2004 01:20:10 +0000 (17:20 -0800)
committerLinus Torvalds <torvalds@ppc970.osdl.org>
Fri, 17 Dec 2004 01:20:10 +0000 (17:20 -0800)
commitd45c791c30ab560e53d031376419cc57e8abcaf4
treea71e45b292a65e327084de73553dee502d1fc15c
parent44e0a901c266f940ab4bd4c37b10f0af5de4e03b
[PATCH] ppc64: fix signal mask restoration when delivery fails

This is the third of 3 patches from David Woodhouse which fix various
problems with signal handling on ppc64.

At present, if a signal is being delivered, and the process has specified
delivery of that signal on an alternate stack but the alternate stack that
has been specified is invalid (i.e.  the kernel gets a fault writing to the
alternate stack), then we (correctly) give the process a SIGSEGV but we put
the wrong signal mask in the saved state on the stack - i.e.  we put the
mask that would have been established for the original signal handler
there.

This patch fixes it by making setup_rt_frame, handle_rt_signal32 and
handle_signal32 return a status code to indicate whether they successfully
established a stack frame.  If they fail, the caller doesn't block the
signals specified for the signal handler.

Signed-off-by: Paul Mackerras <paulus@samba.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
arch/ppc64/kernel/signal.c
arch/ppc64/kernel/signal32.c