This is a note to let you know that I've just added the patch titled
sparc64: not any error from do_sigaltstack() should fail rt_sigreturn()
to the 3.6-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary
The filename of the patch is:
sparc64-not-any-error-from-do_sigaltstack-should-fail-rt_sigreturn.patch
and it can be found in the queue-3.6 subdirectory.
If you, or anyone else, feels it should not be added to the stable tree,
please let <[email protected]> know about it.
>From fae2ae2a900a5c7bb385fe4075f343e7e2d5daa2 Mon Sep 17 00:00:00 2001
From: Al Viro <[email protected]>
Date: Sun, 18 Nov 2012 22:27:03 -0500
Subject: sparc64: not any error from do_sigaltstack() should fail rt_sigreturn()
From: Al Viro <[email protected]>
commit fae2ae2a900a5c7bb385fe4075f343e7e2d5daa2 upstream.
If a signal handler is executed on altstack and another signal comes,
we will end up with rt_sigreturn() on return from the second handler
getting -EPERM from do_sigaltstack(). It's perfectly OK, since we
are not asking to change the settings; in fact, they couldn't have been
changed during the second handler execution exactly because we'd been
on altstack all along. 64bit sigreturn on sparc treats any error from
do_sigaltstack() as "SIGSEGV now"; we need to switch to the same semantics
we are using on other architectures.
Signed-off-by: Al Viro <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
---
arch/sparc/kernel/signal_64.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
--- a/arch/sparc/kernel/signal_64.c
+++ b/arch/sparc/kernel/signal_64.c
@@ -295,9 +295,7 @@ void do_rt_sigreturn(struct pt_regs *reg
err |= restore_fpu_state(regs, fpu_save);
err |= __copy_from_user(&set, &sf->mask, sizeof(sigset_t));
- err |= do_sigaltstack(&sf->stack, NULL, (unsigned long)sf);
-
- if (err)
+ if (err || do_sigaltstack(&sf->stack, NULL, (unsigned long)sf) ==
-EFAULT)
goto segv;
err |= __get_user(rwin_save, &sf->rwin_save);
Patches currently in stable-queue which might be from [email protected]
are
queue-3.6/parisc-fix-user-triggerable-panic-on-parisc.patch
queue-3.6/x86-efi-fix-processor-specific-memcpy-build-error.patch
queue-3.6/writeback-put-unused-inodes-to-lru-after-writeback-completion.patch
queue-3.6/sparc64-not-any-error-from-do_sigaltstack-should-fail-rt_sigreturn.patch
--
To unsubscribe from this list: send the line "unsubscribe stable" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html