Bug 439668 - ptrace+utrace: step-to-breakpoint: Watchpoint breaks PTRACE_SINGLESTEP
ptrace+utrace: step-to-breakpoint: Watchpoint breaks PTRACE_SINGLESTEP
Status: CLOSED WONTFIX
Product: Fedora
Classification: Fedora
Component: kernel (Show other bugs)
13
x86_64 Linux
low Severity high
: ---
: ---
Assigned To: Roland McGrath
Fedora Extras Quality Assurance
: Reopened
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2008-03-30 03:30 EDT by Jan Kratochvil
Modified: 2011-06-27 09:57 EDT (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2011-06-27 09:57:46 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Jan Kratochvil 2008-03-30 03:30:16 EDT
Description of problem:
After one sets+clears an unhit watchpoint later processes being debugged on the
same CPU will skip two instructions with a single PTRACE_SINGLESTEP.

Version-Release number of selected component (if applicable):
kernel-2.6.23.1-42.fc8.x86_64
kernel-2.6.24.3-50.fc8.x86_64
kernel-2.6.25-0.172.rc7.git4.fc9.x86_64 (Rawhide)
kernel-vanilla-2.6.25-0.101.rc4.git3.fc8.x86_64 (AFAIK NON-utrace!)

How reproducible:
Always.

Steps to Reproduce:
1. wget -O step-to-breakpoint.c
'http://sources.redhat.com/cgi-bin/cvsweb.cgi/~checkout~/tests/ptrace-tests/tests/step-to-breakpoint.c?cvsroot=systemtap';
gcc -o step-to-breakpoint step-to-breakpoint.c -Wall -ggdb2 -D_GNU_SOURCE;
./step-to-breakpoint; echo $?

Actual results:
1

Expected results:
0

Additional info:
It also breaks various GDB testcase: gdb.base/call-sc.exp
Tested on:
  Intel(R) Xeon(TM) CPU 3.20GHz 
  model           : 3
  stepping        : 4
  Dual CPU dual core (cpus=4)
Comment 3 Jan Kratochvil 2008-03-30 10:04:37 EDT
Problem is unreproducible on F-8:
  kernel-2.6.23.1-42.fc8.x86_64
  kernel-2.6.24.3-50.fc8.x86_64
on:
        Dual Core AMD Opteron(tm) Processor 275
        cpu family      : 15
        model           : 33
        stepping        : 2

Therefore also due to the problem specifics expecting it is an Intel CPU errata
but I did not find it listed at:
  http://www.intel.com/design/mobile/specupdt/309222.htm
  February 2008 Revision 016
Comment 4 Roland McGrath 2008-03-30 22:54:11 EDT
The test case passes for me on my machines:

cpu family      : 6
model           : 15
model name      : Intel(R) Xeon(R) CPU            5120  @ 1.86GHz
stepping        : 6

I tried 2.6.24.3-34.fc8 and upstreamish bleeding edge hacking kernel.
Comment 5 Jan Kratochvil 2008-03-31 14:18:42 EDT
Verified as reproducibile on dell-pe2850-01.rhts.boston.redhat.com (still the
same host but the problem is really common in the RHTS farm) after loading
microcode-20080220.dat as found in microcode_ctl-1.17-1.44.fc9 being loaded on
F-8 kernel-2.6.23.1-42.fc8.x86_64 using F-8 microcode_ctl-1.17-1.38.fc8.x86_64.
Comment 6 Geoff Gustafson 2008-04-02 11:06:55 EDT
I will try to get Intel to evaluate this.
Comment 7 Jan Kratochvil 2008-04-04 12:44:35 EDT
The problem is most probably listed as N37 in the Intel Errata suggested by
Geoff G.:
  http://www.intel.com/design/intarch/specupdt/249199.htm
so it affects Intel processors having in /proc/cpuinfo:
  cpu family : 15

Unfortunately from the N37 description I do not see a simple kernel workaround
for it, fortunately the problem is no longer present on the recent Intel CPUs.

Still this is not a response from Intel, just my preliminary expectation.
Comment 8 Geoff Gustafson 2008-04-04 15:06:15 EDT
I just had various people on #devel run it, and here was one box that returned 1
from the test:

RHEL4.? running 2.6.9-68.26.EL.nmiwatchdog

cpu family      : 15
model           : 104
model name      : AMD Turion(tm) 64 X2 Mobile Technology TL-58
stepping        : 2

It's a laptop, aris is testing on it and says it's benl's. So that would seem to
argue against CPU erratum...
Comment 9 Roland McGrath 2008-04-04 16:20:27 EDT
The erratum N37 description mentions several specific cases with many details,
and those cases are definitely not coming up in this test case.
Comment 10 Jan Kratochvil 2008-04-04 17:06:41 EDT
(In reply to comment #8)
> It's a laptop, aris is testing on it and says it's benl's. So that would seem
> to argue against CPU erratum...

Tried it there (on AMD) repeatedly and the problem is really reproducible there.
Comment 11 Bug Zapper 2008-11-26 05:18:54 EST
This message is a reminder that Fedora 8 is nearing its end of life.
Approximately 30 (thirty) days from now Fedora will stop maintaining
and issuing updates for Fedora 8.  It is Fedora's policy to close all
bug reports from releases that are no longer maintained.  At that time
this bug will be closed as WONTFIX if it remains open with a Fedora 
'version' of '8'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version prior to Fedora 8's end of life.

Bug Reporter: Thank you for reporting this issue and we are sorry that 
we may not be able to fix it before Fedora 8 is end of life.  If you 
would still like to see this bug fixed and are able to reproduce it 
against a later version of Fedora please change the 'version' of this 
bug to the applicable version.  If you are unable to change the version, 
please add a comment here and someone will do it for you.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events.  Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

The process we are following is described here: 
http://fedoraproject.org/wiki/BugZappers/HouseKeeping
Comment 12 Bug Zapper 2009-01-09 01:17:24 EST
Fedora 8 changed to end-of-life (EOL) status on 2009-01-07. Fedora 8 is 
no longer maintained, which means that it will not receive any further 
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of 
Fedora please feel free to reopen this bug against that version.

Thank you for reporting this bug and we are sorry it could not be fixed.
Comment 13 Jan Kratochvil 2009-03-18 17:56:32 EDT
Verified on: kernel-2.6.29-0.207.rc7.ptrace.fc11.x86_64
"ptrace" - just removed:
ApplyPatch linux-2.6-utrace.patch
Comment 15 Bug Zapper 2009-06-09 05:30:42 EDT
This bug appears to have been reported against 'rawhide' during the Fedora 11 development cycle.
Changing version to '11'.

More information and reason for this action is here:
http://fedoraproject.org/wiki/BugZappers/HouseKeeping
Comment 16 Bug Zapper 2010-04-27 07:58:27 EDT
This message is a reminder that Fedora 11 is nearing its end of life.
Approximately 30 (thirty) days from now Fedora will stop maintaining
and issuing updates for Fedora 11.  It is Fedora's policy to close all
bug reports from releases that are no longer maintained.  At that time
this bug will be closed as WONTFIX if it remains open with a Fedora 
'version' of '11'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version prior to Fedora 11's end of life.

Bug Reporter: Thank you for reporting this issue and we are sorry that 
we may not be able to fix it before Fedora 11 is end of life.  If you 
would still like to see this bug fixed and are able to reproduce it 
against a later version of Fedora please change the 'version' of this 
bug to the applicable version.  If you are unable to change the version, 
please add a comment here and someone will do it for you.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events.  Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

The process we are following is described here: 
http://fedoraproject.org/wiki/BugZappers/HouseKeeping
Comment 17 Jan Kratochvil 2010-04-27 15:09:13 EDT
Bug has been verified by CAI Qian as existing in RHEL-6 Beta 1.
Comment 18 Bug Zapper 2011-06-02 14:33:50 EDT
This message is a reminder that Fedora 13 is nearing its end of life.
Approximately 30 (thirty) days from now Fedora will stop maintaining
and issuing updates for Fedora 13.  It is Fedora's policy to close all
bug reports from releases that are no longer maintained.  At that time
this bug will be closed as WONTFIX if it remains open with a Fedora 
'version' of '13'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version prior to Fedora 13's end of life.

Bug Reporter: Thank you for reporting this issue and we are sorry that 
we may not be able to fix it before Fedora 13 is end of life.  If you 
would still like to see this bug fixed and are able to reproduce it 
against a later version of Fedora please change the 'version' of this 
bug to the applicable version.  If you are unable to change the version, 
please add a comment here and someone will do it for you.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events.  Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

The process we are following is described here: 
http://fedoraproject.org/wiki/BugZappers/HouseKeeping
Comment 19 Bug Zapper 2011-06-27 09:57:46 EDT
Fedora 13 changed to end-of-life (EOL) status on 2011-06-25. Fedora 13 is 
no longer maintained, which means that it will not receive any further 
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of 
Fedora please feel free to reopen this bug against that version.

Thank you for reporting this bug and we are sorry it could not be fixed.

Note You need to log in before you can comment on or make changes to this bug.