diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2012-12-25 19:29:01 -0500 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2013-02-03 18:16:00 -0500 |
commit | 8be433ab55d5058327e82f124f1eb0b37e4540b1 (patch) | |
tree | 7db03b4f1a31eb80be341b8f188e35dd1ef25704 /arch/m68k | |
parent | 1ba3e7efb60b4d7d4f75f084214b90bd0fdaa319 (diff) |
m68k: switch to generic old sigaction()
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'arch/m68k')
-rw-r--r-- | arch/m68k/Kconfig | 1 | ||||
-rw-r--r-- | arch/m68k/include/asm/signal.h | 7 | ||||
-rw-r--r-- | arch/m68k/kernel/signal.c | 32 |
3 files changed, 1 insertions, 39 deletions
diff --git a/arch/m68k/Kconfig b/arch/m68k/Kconfig index 107747981b38..a358bf63defe 100644 --- a/arch/m68k/Kconfig +++ b/arch/m68k/Kconfig | |||
@@ -20,6 +20,7 @@ config M68K | |||
20 | select MODULES_USE_ELF_RELA | 20 | select MODULES_USE_ELF_RELA |
21 | select GENERIC_SIGALTSTACK | 21 | select GENERIC_SIGALTSTACK |
22 | select OLD_SIGSUSPEND3 | 22 | select OLD_SIGSUSPEND3 |
23 | select OLD_SIGACTION | ||
23 | 24 | ||
24 | config RWSEM_GENERIC_SPINLOCK | 25 | config RWSEM_GENERIC_SPINLOCK |
25 | bool | 26 | bool |
diff --git a/arch/m68k/include/asm/signal.h b/arch/m68k/include/asm/signal.h index c7b4fb1fa14d..214320b50384 100644 --- a/arch/m68k/include/asm/signal.h +++ b/arch/m68k/include/asm/signal.h | |||
@@ -16,13 +16,6 @@ typedef struct { | |||
16 | unsigned long sig[_NSIG_WORDS]; | 16 | unsigned long sig[_NSIG_WORDS]; |
17 | } sigset_t; | 17 | } sigset_t; |
18 | 18 | ||
19 | struct old_sigaction { | ||
20 | __sighandler_t sa_handler; | ||
21 | old_sigset_t sa_mask; | ||
22 | unsigned long sa_flags; | ||
23 | __sigrestore_t sa_restorer; | ||
24 | }; | ||
25 | |||
26 | #define __ARCH_HAS_SA_RESTORER | 19 | #define __ARCH_HAS_SA_RESTORER |
27 | 20 | ||
28 | #include <asm/sigcontext.h> | 21 | #include <asm/sigcontext.h> |
diff --git a/arch/m68k/kernel/signal.c b/arch/m68k/kernel/signal.c index b5c6b4d9d1a9..2a16df3d9312 100644 --- a/arch/m68k/kernel/signal.c +++ b/arch/m68k/kernel/signal.c | |||
@@ -224,38 +224,6 @@ static inline void push_cache(unsigned long vaddr) | |||
224 | 224 | ||
225 | #endif /* CONFIG_MMU */ | 225 | #endif /* CONFIG_MMU */ |
226 | 226 | ||
227 | asmlinkage int | ||
228 | sys_sigaction(int sig, const struct old_sigaction __user *act, | ||
229 | struct old_sigaction __user *oact) | ||
230 | { | ||
231 | struct k_sigaction new_ka, old_ka; | ||
232 | int ret; | ||
233 | |||
234 | if (act) { | ||
235 | old_sigset_t mask; | ||
236 | if (!access_ok(VERIFY_READ, act, sizeof(*act)) || | ||
237 | __get_user(new_ka.sa.sa_handler, &act->sa_handler) || | ||
238 | __get_user(new_ka.sa.sa_restorer, &act->sa_restorer) || | ||
239 | __get_user(new_ka.sa.sa_flags, &act->sa_flags) || | ||
240 | __get_user(mask, &act->sa_mask)) | ||
241 | return -EFAULT; | ||
242 | siginitset(&new_ka.sa.sa_mask, mask); | ||
243 | } | ||
244 | |||
245 | ret = do_sigaction(sig, act ? &new_ka : NULL, oact ? &old_ka : NULL); | ||
246 | |||
247 | if (!ret && oact) { | ||
248 | if (!access_ok(VERIFY_WRITE, oact, sizeof(*oact)) || | ||
249 | __put_user(old_ka.sa.sa_handler, &oact->sa_handler) || | ||
250 | __put_user(old_ka.sa.sa_restorer, &oact->sa_restorer) || | ||
251 | __put_user(old_ka.sa.sa_flags, &oact->sa_flags) || | ||
252 | __put_user(old_ka.sa.sa_mask.sig[0], &oact->sa_mask)) | ||
253 | return -EFAULT; | ||
254 | } | ||
255 | |||
256 | return ret; | ||
257 | } | ||
258 | |||
259 | /* | 227 | /* |
260 | * Do a signal return; undo the signal stack. | 228 | * Do a signal return; undo the signal stack. |
261 | * | 229 | * |