diff options
Diffstat (limited to 'arch/blackfin/kernel/signal.c')
-rw-r--r-- | arch/blackfin/kernel/signal.c | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/arch/blackfin/kernel/signal.c b/arch/blackfin/kernel/signal.c index 9d692a1277b3..7f4205ddfa4d 100644 --- a/arch/blackfin/kernel/signal.c +++ b/arch/blackfin/kernel/signal.c | |||
@@ -249,7 +249,7 @@ handle_restart(struct pt_regs *regs, struct k_sigaction *ka, int has_handler) | |||
249 | */ | 249 | */ |
250 | static int | 250 | static int |
251 | handle_signal(int sig, siginfo_t *info, struct k_sigaction *ka, | 251 | handle_signal(int sig, siginfo_t *info, struct k_sigaction *ka, |
252 | sigset_t *oldset, struct pt_regs *regs) | 252 | struct pt_regs *regs) |
253 | { | 253 | { |
254 | int ret; | 254 | int ret; |
255 | 255 | ||
@@ -259,7 +259,7 @@ handle_signal(int sig, siginfo_t *info, struct k_sigaction *ka, | |||
259 | handle_restart(regs, ka, 1); | 259 | handle_restart(regs, ka, 1); |
260 | 260 | ||
261 | /* set up the stack frame */ | 261 | /* set up the stack frame */ |
262 | ret = setup_rt_frame(sig, ka, info, oldset, regs); | 262 | ret = setup_rt_frame(sig, ka, info, sigmask_to_save(), regs); |
263 | 263 | ||
264 | if (ret == 0) | 264 | if (ret == 0) |
265 | block_sigmask(ka, sig); | 265 | block_sigmask(ka, sig); |
@@ -281,22 +281,16 @@ asmlinkage void do_signal(struct pt_regs *regs) | |||
281 | siginfo_t info; | 281 | siginfo_t info; |
282 | int signr; | 282 | int signr; |
283 | struct k_sigaction ka; | 283 | struct k_sigaction ka; |
284 | sigset_t *oldset; | ||
285 | 284 | ||
286 | current->thread.esp0 = (unsigned long)regs; | 285 | current->thread.esp0 = (unsigned long)regs; |
287 | 286 | ||
288 | if (try_to_freeze()) | 287 | if (try_to_freeze()) |
289 | goto no_signal; | 288 | goto no_signal; |
290 | 289 | ||
291 | if (test_thread_flag(TIF_RESTORE_SIGMASK)) | ||
292 | oldset = ¤t->saved_sigmask; | ||
293 | else | ||
294 | oldset = ¤t->blocked; | ||
295 | |||
296 | signr = get_signal_to_deliver(&info, &ka, regs, NULL); | 290 | signr = get_signal_to_deliver(&info, &ka, regs, NULL); |
297 | if (signr > 0) { | 291 | if (signr > 0) { |
298 | /* Whee! Actually deliver the signal. */ | 292 | /* Whee! Actually deliver the signal. */ |
299 | if (handle_signal(signr, &info, &ka, oldset, regs) == 0) { | 293 | if (handle_signal(signr, &info, &ka, regs) == 0) { |
300 | /* a signal was successfully delivered; the saved | 294 | /* a signal was successfully delivered; the saved |
301 | * sigmask will have been stored in the signal frame, | 295 | * sigmask will have been stored in the signal frame, |
302 | * and will be restored by sigreturn, so we can simply | 296 | * and will be restored by sigreturn, so we can simply |