diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2013-02-23 21:50:11 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2013-02-23 21:50:11 -0500 |
commit | 9e2d59ad580d590134285f361a0e80f0e98c0207 (patch) | |
tree | f3232be75781484193413f32ec82c21f6d8eb76e /arch/blackfin | |
parent | 5ce1a70e2f00f0bce0cab57f798ca354b9496169 (diff) | |
parent | 235b80226b986dabcbba844968f7807866bd0bfe (diff) |
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/signal
Pull signal handling cleanups from Al Viro:
"This is the first pile; another one will come a bit later and will
contain SYSCALL_DEFINE-related patches.
- a bunch of signal-related syscalls (both native and compat)
unified.
- a bunch of compat syscalls switched to COMPAT_SYSCALL_DEFINE
(fixing several potential problems with missing argument
validation, while we are at it)
- a lot of now-pointless wrappers killed
- a couple of architectures (cris and hexagon) forgot to save
altstack settings into sigframe, even though they used the
(uninitialized) values in sigreturn; fixed.
- microblaze fixes for delivery of multiple signals arriving at once
- saner set of helpers for signal delivery introduced, several
architectures switched to using those."
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/signal: (143 commits)
x86: convert to ksignal
sparc: convert to ksignal
arm: switch to struct ksignal * passing
alpha: pass k_sigaction and siginfo_t using ksignal pointer
burying unused conditionals
make do_sigaltstack() static
arm64: switch to generic old sigaction() (compat-only)
arm64: switch to generic compat rt_sigaction()
arm64: switch compat to generic old sigsuspend
arm64: switch to generic compat rt_sigqueueinfo()
arm64: switch to generic compat rt_sigpending()
arm64: switch to generic compat rt_sigprocmask()
arm64: switch to generic sigaltstack
sparc: switch to generic old sigsuspend
sparc: COMPAT_SYSCALL_DEFINE does all sign-extension as well as SYSCALL_DEFINE
sparc: kill sign-extending wrappers for native syscalls
kill sparc32_open()
sparc: switch to use of generic old sigaction
sparc: switch sys_compat_rt_sigaction() to COMPAT_SYSCALL_DEFINE
mips: switch to generic sys_fork() and sys_clone()
...
Diffstat (limited to 'arch/blackfin')
-rw-r--r-- | arch/blackfin/include/asm/unistd.h | 2 | ||||
-rw-r--r-- | arch/blackfin/kernel/signal.c | 12 |
2 files changed, 2 insertions, 12 deletions
diff --git a/arch/blackfin/include/asm/unistd.h b/arch/blackfin/include/asm/unistd.h index e943cb130048..04e83ea8d5cc 100644 --- a/arch/blackfin/include/asm/unistd.h +++ b/arch/blackfin/include/asm/unistd.h | |||
@@ -18,8 +18,6 @@ | |||
18 | #define __ARCH_WANT_SYS_GETPGRP | 18 | #define __ARCH_WANT_SYS_GETPGRP |
19 | #define __ARCH_WANT_SYS_LLSEEK | 19 | #define __ARCH_WANT_SYS_LLSEEK |
20 | #define __ARCH_WANT_SYS_NICE | 20 | #define __ARCH_WANT_SYS_NICE |
21 | #define __ARCH_WANT_SYS_RT_SIGACTION | ||
22 | #define __ARCH_WANT_SYS_RT_SIGSUSPEND | ||
23 | #define __ARCH_WANT_SYS_VFORK | 21 | #define __ARCH_WANT_SYS_VFORK |
24 | 22 | ||
25 | /* | 23 | /* |
diff --git a/arch/blackfin/kernel/signal.c b/arch/blackfin/kernel/signal.c index 84b4be05840c..b022af6c48f8 100644 --- a/arch/blackfin/kernel/signal.c +++ b/arch/blackfin/kernel/signal.c | |||
@@ -37,11 +37,6 @@ struct rt_sigframe { | |||
37 | struct ucontext uc; | 37 | struct ucontext uc; |
38 | }; | 38 | }; |
39 | 39 | ||
40 | asmlinkage int sys_sigaltstack(const stack_t __user *uss, stack_t __user *uoss) | ||
41 | { | ||
42 | return do_sigaltstack(uss, uoss, rdusp()); | ||
43 | } | ||
44 | |||
45 | static inline int | 40 | static inline int |
46 | rt_restore_sigcontext(struct pt_regs *regs, struct sigcontext __user *sc, int *pr0) | 41 | rt_restore_sigcontext(struct pt_regs *regs, struct sigcontext __user *sc, int *pr0) |
47 | { | 42 | { |
@@ -100,7 +95,7 @@ asmlinkage int sys_rt_sigreturn(void) | |||
100 | if (rt_restore_sigcontext(regs, &frame->uc.uc_mcontext, &r0)) | 95 | if (rt_restore_sigcontext(regs, &frame->uc.uc_mcontext, &r0)) |
101 | goto badframe; | 96 | goto badframe; |
102 | 97 | ||
103 | if (do_sigaltstack(&frame->uc.uc_stack, NULL, regs->usp) == -EFAULT) | 98 | if (restore_altstack(&frame->uc.uc_stack)) |
104 | goto badframe; | 99 | goto badframe; |
105 | 100 | ||
106 | return r0; | 101 | return r0; |
@@ -178,10 +173,7 @@ setup_rt_frame(int sig, struct k_sigaction *ka, siginfo_t * info, | |||
178 | /* Create the ucontext. */ | 173 | /* Create the ucontext. */ |
179 | err |= __put_user(0, &frame->uc.uc_flags); | 174 | err |= __put_user(0, &frame->uc.uc_flags); |
180 | err |= __put_user(0, &frame->uc.uc_link); | 175 | err |= __put_user(0, &frame->uc.uc_link); |
181 | err |= | 176 | err |= __save_altstack(&frame->uc.uc_stack, rdusp()); |
182 | __put_user((void *)current->sas_ss_sp, &frame->uc.uc_stack.ss_sp); | ||
183 | err |= __put_user(sas_ss_flags(rdusp()), &frame->uc.uc_stack.ss_flags); | ||
184 | err |= __put_user(current->sas_ss_size, &frame->uc.uc_stack.ss_size); | ||
185 | err |= rt_setup_sigcontext(&frame->uc.uc_mcontext, regs); | 177 | err |= rt_setup_sigcontext(&frame->uc.uc_mcontext, regs); |
186 | err |= copy_to_user(&frame->uc.uc_sigmask, set, sizeof(*set)); | 178 | err |= copy_to_user(&frame->uc.uc_sigmask, set, sizeof(*set)); |
187 | 179 | ||