x86,um: switch to generic old sigsuspend()
authorAl Viro <viro@zeniv.linux.org.uk>
Tue, 25 Dec 2012 21:09:20 +0000 (16:09 -0500)
committerAl Viro <viro@zeniv.linux.org.uk>
Sun, 3 Feb 2013 23:16:26 +0000 (18:16 -0500)
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
arch/um/kernel/signal.c
arch/x86/Kconfig
arch/x86/ia32/ia32_signal.c
arch/x86/include/asm/sys_ia32.h
arch/x86/include/asm/syscalls.h
arch/x86/kernel/signal.c
arch/x86/syscalls/syscall_32.tbl
arch/x86/um/Kconfig

index 48ccf718e290144c9dce74459dfc765846c93c55..3e831b3fd07bb4f547db12eadb6ccecb99df86c9 100644 (file)
@@ -122,13 +122,3 @@ int do_signal(void)
 {
        return kern_do_signal(&current->thread.regs);
 }
-
-/*
- * Atomically swap in the new signal mask, and wait for a signal.
- */
-long sys_sigsuspend(int history0, int history1, old_sigset_t mask)
-{
-       sigset_t blocked;
-       siginitset(&blocked, mask);
-       return sigsuspend(&blocked);
-}
index 9f031118f856d4eb49cdac1b3c0df3988551809e..5bda2d7f1b690a44ad795d37038830533c4557d3 100644 (file)
@@ -116,6 +116,7 @@ config X86
        select GENERIC_SIGALTSTACK
        select GENERIC_COMPAT_RT_SIGQUEUEINFO
        select GENERIC_COMPAT_RT_SIGPENDING
+       select OLD_SIGSUSPEND3 if X86_32 || IA32_EMULATION
 
 config INSTRUCTION_DECODER
        def_bool y
index 15fdb3f57d8c0abdd2ca9e89be73c4631d97086a..b0460cd7de5a9ce024cae70085bc313753807e5a 100644 (file)
@@ -129,13 +129,6 @@ int copy_siginfo_from_user32(siginfo_t *to, compat_siginfo_t __user *from)
        return err;
 }
 
-asmlinkage long sys32_sigsuspend(int history0, int history1, old_sigset_t mask)
-{
-       sigset_t blocked;
-       siginitset(&blocked, mask);
-       return sigsuspend(&blocked);
-}
-
 /*
  * Do a signal return; undo the signal stack.
  */
index e3a893167387a380724bcd700552a49a4aaa26bc..d4c3837f929757261aa4ffcb6da552f3ef55649e 100644 (file)
@@ -66,7 +66,6 @@ asmlinkage long sys32_fallocate(int, int, unsigned,
                                unsigned, unsigned, unsigned);
 
 /* ia32/ia32_signal.c */
-asmlinkage long sys32_sigsuspend(int, int, old_sigset_t);
 asmlinkage long sys32_sigreturn(void);
 asmlinkage long sys32_rt_sigreturn(void);
 
index f755423a5d02fa99355021d9922b3e630115b73c..7ed7dec7fb0ed99ee7f3f374513a60ccddd41989 100644 (file)
@@ -34,7 +34,6 @@ asmlinkage int sys_get_thread_area(struct user_desc __user *);
 #ifdef CONFIG_X86_32
 
 /* kernel/signal.c */
-asmlinkage int sys_sigsuspend(int, int, old_sigset_t);
 asmlinkage int sys_sigaction(int, const struct old_sigaction __user *,
                             struct old_sigaction __user *);
 unsigned long sys_sigreturn(void);
index 38ba7e56e1614802ac5de7552a7958e382b1a116..057712901509911ded13b49e6b3d894b5aeb71a3 100644 (file)
@@ -536,17 +536,6 @@ static int x32_setup_rt_frame(int sig, struct k_sigaction *ka,
 }
 
 #ifdef CONFIG_X86_32
-/*
- * Atomically swap in the new signal mask, and wait for a signal.
- */
-asmlinkage int
-sys_sigsuspend(int history0, int history1, old_sigset_t mask)
-{
-       sigset_t blocked;
-       siginitset(&blocked, mask);
-       return sigsuspend(&blocked);
-}
-
 asmlinkage int
 sys_sigaction(int sig, const struct old_sigaction __user *act,
              struct old_sigaction __user *oact)
index 9c707c4b48114ef393b83d623604b2d9e7410f38..fae76a348c736e355d9a0965322c20c829e918b8 100644 (file)
@@ -78,7 +78,7 @@
 69     i386    ssetmask                sys_ssetmask
 70     i386    setreuid                sys_setreuid16
 71     i386    setregid                sys_setregid16
-72     i386    sigsuspend              sys_sigsuspend                  sys32_sigsuspend
+72     i386    sigsuspend              sys_sigsuspend                  sys_sigsuspend
 73     i386    sigpending              sys_sigpending                  compat_sys_sigpending
 74     i386    sethostname             sys_sethostname
 75     i386    setrlimit               sys_setrlimit                   compat_sys_setrlimit
index 53c90fd412d1a4637fcb17aeaf1a5d5978a2160a..a3725824449e73b0b6f626d86660ac9de8870127 100644 (file)
@@ -25,6 +25,7 @@ config X86_32
        select ARCH_WANT_IPC_PARSE_VERSION
        select MODULES_USE_ELF_REL
        select CLONE_BACKWARDS
+       select OLD_SIGSUSPEND3
 
 config X86_64
        def_bool 64BIT