diff options
Diffstat (limited to 'arch/powerpc')
-rw-r--r-- | arch/powerpc/kernel/entry_32.S | 4 | ||||
-rw-r--r-- | arch/powerpc/kernel/entry_64.S | 3 | ||||
-rw-r--r-- | arch/powerpc/kernel/signal.c | 13 |
3 files changed, 15 insertions, 5 deletions
diff --git a/arch/powerpc/kernel/entry_32.S b/arch/powerpc/kernel/entry_32.S index e6fca6a9014d..1cbbf7033641 100644 --- a/arch/powerpc/kernel/entry_32.S +++ b/arch/powerpc/kernel/entry_32.S | |||
@@ -1060,8 +1060,8 @@ do_user_signal: /* r10 contains MSR_KERNEL here */ | |||
1060 | SAVE_NVGPRS(r1) | 1060 | SAVE_NVGPRS(r1) |
1061 | rlwinm r3,r3,0,0,30 | 1061 | rlwinm r3,r3,0,0,30 |
1062 | stw r3,_TRAP(r1) | 1062 | stw r3,_TRAP(r1) |
1063 | 2: li r3,0 | 1063 | 2: addi r3,r1,STACK_FRAME_OVERHEAD |
1064 | addi r4,r1,STACK_FRAME_OVERHEAD | 1064 | mr r4,r9 |
1065 | bl do_signal | 1065 | bl do_signal |
1066 | REST_NVGPRS(r1) | 1066 | REST_NVGPRS(r1) |
1067 | b recheck | 1067 | b recheck |
diff --git a/arch/powerpc/kernel/entry_64.S b/arch/powerpc/kernel/entry_64.S index 79c089e97ce4..2d802e97097c 100644 --- a/arch/powerpc/kernel/entry_64.S +++ b/arch/powerpc/kernel/entry_64.S | |||
@@ -643,8 +643,7 @@ user_work: | |||
643 | b .ret_from_except_lite | 643 | b .ret_from_except_lite |
644 | 644 | ||
645 | 1: bl .save_nvgprs | 645 | 1: bl .save_nvgprs |
646 | li r3,0 | 646 | addi r3,r1,STACK_FRAME_OVERHEAD |
647 | addi r4,r1,STACK_FRAME_OVERHEAD | ||
648 | bl .do_signal | 647 | bl .do_signal |
649 | b .ret_from_except | 648 | b .ret_from_except |
650 | 649 | ||
diff --git a/arch/powerpc/kernel/signal.c b/arch/powerpc/kernel/signal.c index e74aa0ed4e9e..a54405ebd7b0 100644 --- a/arch/powerpc/kernel/signal.c +++ b/arch/powerpc/kernel/signal.c | |||
@@ -112,7 +112,7 @@ static void check_syscall_restart(struct pt_regs *regs, struct k_sigaction *ka, | |||
112 | } | 112 | } |
113 | } | 113 | } |
114 | 114 | ||
115 | int do_signal(sigset_t *oldset, struct pt_regs *regs) | 115 | static int do_signal_pending(sigset_t *oldset, struct pt_regs *regs) |
116 | { | 116 | { |
117 | siginfo_t info; | 117 | siginfo_t info; |
118 | int signr; | 118 | int signr; |
@@ -188,6 +188,17 @@ int do_signal(sigset_t *oldset, struct pt_regs *regs) | |||
188 | return ret; | 188 | return ret; |
189 | } | 189 | } |
190 | 190 | ||
191 | void do_signal(struct pt_regs *regs, unsigned long thread_info_flags) | ||
192 | { | ||
193 | if (thread_info_flags & _TIF_SIGPENDING) | ||
194 | do_signal_pending(NULL, regs); | ||
195 | |||
196 | if (thread_info_flags & _TIF_NOTIFY_RESUME) { | ||
197 | clear_thread_flag(TIF_NOTIFY_RESUME); | ||
198 | tracehook_notify_resume(regs); | ||
199 | } | ||
200 | } | ||
201 | |||
191 | long sys_sigaltstack(const stack_t __user *uss, stack_t __user *uoss, | 202 | long sys_sigaltstack(const stack_t __user *uss, stack_t __user *uoss, |
192 | unsigned long r5, unsigned long r6, unsigned long r7, | 203 | unsigned long r5, unsigned long r6, unsigned long r7, |
193 | unsigned long r8, struct pt_regs *regs) | 204 | unsigned long r8, struct pt_regs *regs) |