Bug 426647
| Summary: | ptrace: PTRACE_SINGLESTEP,signal steps on the 2nd instr. | ||||||
|---|---|---|---|---|---|---|---|
| Product: | Red Hat Enterprise Linux 4 | Reporter: | Jan Kratochvil <jan.kratochvil> | ||||
| Component: | kernel | Assignee: | Jerome Marchand <jmarchan> | ||||
| Status: | CLOSED ERRATA | QA Contact: | Martin Jenner <mjenner> | ||||
| Severity: | low | Docs Contact: | |||||
| Priority: | low | ||||||
| Version: | 4.6 | CC: | roland, vgoyal | ||||
| Target Milestone: | rc | ||||||
| Target Release: | --- | ||||||
| Hardware: | s390x | ||||||
| OS: | Linux | ||||||
| URL: | http://sources.redhat.com/cgi-bin/cvsweb.cgi/~checkout~/tests/ptrace-tests/tests/step-into-handler.c?cvsroot=systemtap | ||||||
| Whiteboard: | |||||||
| Fixed In Version: | RHSA-2008-0665 | Doc Type: | Bug Fix | ||||
| Doc Text: | Story Points: | --- | |||||
| Clone Of: | Environment: | ||||||
| Last Closed: | 2008-07-24 19:23:51 UTC | Type: | --- | ||||
| Regression: | --- | Mount Type: | --- | ||||
| Documentation: | --- | CRM: | |||||
| Verified Versions: | Category: | --- | |||||
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||
| Cloudforms Team: | --- | Target Upstream Version: | |||||
| Embargoed: | |||||||
| Bug Depends On: | |||||||
| Bug Blocks: | 338951 | ||||||
| Attachments: |
|
||||||
|
Description
Jan Kratochvil
2007-12-23 16:39:33 UTC
RHEL-5 kernel under the test was: kernel-2.6.18-58.el5.utrace2.s390x This was indeed fixed in RHEL5 as part of the utrace port for s390. The upstream code for this is being cleaned up right now, it so happens. This is probably the right fix for RHEL4: --- linux-2.6.9/arch/s390/kernel/signal.c +++ linux-2.6.9/arch/s390/kernel/signal.c @@ -514,6 +514,8 @@ int do_signal(struct pt_regs *regs, sigs } #endif handle_signal(signr, &ka, &info, oldset, regs); + if (current->thread.per_info.single_step) + set_thread_flag(TIF_SINGLE_STEP); return 1; } Created attachment 303601 [details]
Restore single_step flag after signal
Resore current->thread.per_info.single_step before returning from do_signal()
and jump to sysc_singlestep after do_signal() returned in system_call().
With the patch above applied, the reproducer returns zero on both s390 and s390x (31 et 64 bits). Committed in 71.EL . RPMS are available at http://people.redhat.com/vgoyal/rhel4/ An advisory has been issued which should help the problem described in this bug report. This report is therefore being closed with a resolution of ERRATA. For more information on therefore solution and/or where to find the updated files, please follow the link below. You may reopen this bug report if the solution does not work for you. http://rhn.redhat.com/errata/RHSA-2008-0665.html |