diff options
author | Martin Schwidefsky <schwidefsky@de.ibm.com> | 2010-01-13 14:44:27 -0500 |
---|---|---|
committer | Martin Schwidefsky <sky@mschwide.boeblingen.de.ibm.com> | 2010-01-13 14:44:44 -0500 |
commit | 6f50248ef0efa7453397eb53e41e8aa5df534492 (patch) | |
tree | c04084989d30918bb9515bebcc9496689e90b4e0 /arch/s390/kernel | |
parent | f8d5faf718c9ff2c04eb8484585d4963c4111cd7 (diff) |
[S390] duplicate SIGTRAP on signal delivery.
The code in do_signal sets the TIF_SINGLE_STEP bit and calls
tracehook_signal_handler after the signal frame has been set up.
This causes two SIGTRAP signals to be delivered to the tracer.
Stop setting the TIF_SINGLE_STEP bit in do_signal to get the
correct number of SIGTRAPs.
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Diffstat (limited to 'arch/s390/kernel')
-rw-r--r-- | arch/s390/kernel/signal.c | 10 |
1 files changed, 1 insertions, 9 deletions
diff --git a/arch/s390/kernel/signal.c b/arch/s390/kernel/signal.c index 6b4fef877f9d..1675c48b9145 100644 --- a/arch/s390/kernel/signal.c +++ b/arch/s390/kernel/signal.c | |||
@@ -500,18 +500,10 @@ void do_signal(struct pt_regs *regs) | |||
500 | clear_thread_flag(TIF_RESTORE_SIGMASK); | 500 | clear_thread_flag(TIF_RESTORE_SIGMASK); |
501 | 501 | ||
502 | /* | 502 | /* |
503 | * If we would have taken a single-step trap | ||
504 | * for a normal instruction, act like we took | ||
505 | * one for the handler setup. | ||
506 | */ | ||
507 | if (current->thread.per_info.single_step) | ||
508 | set_thread_flag(TIF_SINGLE_STEP); | ||
509 | |||
510 | /* | ||
511 | * Let tracing know that we've done the handler setup. | 503 | * Let tracing know that we've done the handler setup. |
512 | */ | 504 | */ |
513 | tracehook_signal_handler(signr, &info, &ka, regs, | 505 | tracehook_signal_handler(signr, &info, &ka, regs, |
514 | test_thread_flag(TIF_SINGLE_STEP)); | 506 | current->thread.per_info.single_step); |
515 | } | 507 | } |
516 | return; | 508 | return; |
517 | } | 509 | } |