Skip to content

Commit

Permalink
parisc: fix tracing of signals
Browse files Browse the repository at this point in the history
Mike Frysinger pointed out that calling tracehook_signal_handler with
stepping=0 missed testing the thread flags, resulting in not calling
ptrace_notify. Fix this by testing if we're single stepping or branch
stepping and setting the flag accordingly.

Tested, seems to work.

Reported-by: Mike Frysinger <[email protected]>
Signed-off-by: Kyle McMartin <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
  • Loading branch information
jkkm authored and torvalds committed Feb 12, 2010
1 parent 0e9695d commit 22a8cdd
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion arch/parisc/kernel/signal.c
Original file line number Diff line number Diff line change
Expand Up @@ -468,7 +468,9 @@ handle_signal(unsigned long sig, siginfo_t *info, struct k_sigaction *ka,
recalc_sigpending();
spin_unlock_irq(&current->sighand->siglock);

tracehook_signal_handler(sig, info, ka, regs, 0);
tracehook_signal_handler(sig, info, ka, regs,
test_thread_flag(TIF_SINGLESTEP) ||
test_thread_flag(TIF_BLOCKSTEP));

return 1;
}
Expand Down

0 comments on commit 22a8cdd

Please sign in to comment.