diff options
author | Will Deacon <will.deacon@arm.com> | 2012-07-04 13:16:30 -0400 |
---|---|---|
committer | Russell King <rmk+kernel@arm.linux.org.uk> | 2012-07-05 04:50:56 -0400 |
commit | 3b0c06226783ffc836217eb34f7eca311b1e63f7 (patch) | |
tree | 5011996479e951a152d704c12bb9613ce8a95fd3 /arch/arm/kernel/signal.c | |
parent | 82401bf105495c593544375b4748f48fce70d9c4 (diff) |
ARM: 7442/1: Revert "remove unused restart trampoline"
This reverts commit fa18484d0947b976a769d15c83c50617493c81c1.
We need the restart trampoline back so that we can revert a related
problematic patch 6b5c8045ecc7e726cdaa2a9d9c8e5008050e1252 ("arm: new
way of handling ERESTART_RESTARTBLOCK").
Acked-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Will Deacon <will.deacon@arm.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'arch/arm/kernel/signal.c')
-rw-r--r-- | arch/arm/kernel/signal.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/arch/arm/kernel/signal.c b/arch/arm/kernel/signal.c index fd2392a17ac1..6d3bce5bd7bc 100644 --- a/arch/arm/kernel/signal.c +++ b/arch/arm/kernel/signal.c | |||
@@ -27,6 +27,7 @@ | |||
27 | */ | 27 | */ |
28 | #define SWI_SYS_SIGRETURN (0xef000000|(__NR_sigreturn)|(__NR_OABI_SYSCALL_BASE)) | 28 | #define SWI_SYS_SIGRETURN (0xef000000|(__NR_sigreturn)|(__NR_OABI_SYSCALL_BASE)) |
29 | #define SWI_SYS_RT_SIGRETURN (0xef000000|(__NR_rt_sigreturn)|(__NR_OABI_SYSCALL_BASE)) | 29 | #define SWI_SYS_RT_SIGRETURN (0xef000000|(__NR_rt_sigreturn)|(__NR_OABI_SYSCALL_BASE)) |
30 | #define SWI_SYS_RESTART (0xef000000|__NR_restart_syscall|__NR_OABI_SYSCALL_BASE) | ||
30 | 31 | ||
31 | /* | 32 | /* |
32 | * With EABI, the syscall number has to be loaded into r7. | 33 | * With EABI, the syscall number has to be loaded into r7. |
@@ -47,6 +48,18 @@ const unsigned long sigreturn_codes[7] = { | |||
47 | }; | 48 | }; |
48 | 49 | ||
49 | /* | 50 | /* |
51 | * Either we support OABI only, or we have EABI with the OABI | ||
52 | * compat layer enabled. In the later case we don't know if | ||
53 | * user space is EABI or not, and if not we must not clobber r7. | ||
54 | * Always using the OABI syscall solves that issue and works for | ||
55 | * all those cases. | ||
56 | */ | ||
57 | const unsigned long syscall_restart_code[2] = { | ||
58 | SWI_SYS_RESTART, /* swi __NR_restart_syscall */ | ||
59 | 0xe49df004, /* ldr pc, [sp], #4 */ | ||
60 | }; | ||
61 | |||
62 | /* | ||
50 | * atomically swap in the new signal mask, and wait for a signal. | 63 | * atomically swap in the new signal mask, and wait for a signal. |
51 | */ | 64 | */ |
52 | asmlinkage int sys_sigsuspend(int restart, unsigned long oldmask, old_sigset_t mask) | 65 | asmlinkage int sys_sigsuspend(int restart, unsigned long oldmask, old_sigset_t mask) |