lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20110722102922.61e7e279@mschwide>
Date:	Fri, 22 Jul 2011 10:29:22 +0200
From:	Martin Schwidefsky <schwidefsky@...ibm.com>
To:	Tejun Heo <tj@...nel.org>
Cc:	Oleg Nesterov <oleg@...hat.com>,
	Stephen Rothwell <sfr@...b.auug.org.au>,
	linux-next@...r.kernel.org, linux-kernel@...r.kernel.org,
	Heiko Carstens <heiko.carstens@...ibm.com>
Subject: Re: linux-next: manual merge of the ptrace tree with the s390 tree

On Fri, 22 Jul 2011 10:06:00 +0200
Tejun Heo <tj@...nel.org> wrote:

> On Thu, Jul 21, 2011 at 04:44:47PM +0200, Oleg Nesterov wrote:
> > On 07/21, Tejun Heo wrote:
> > > Also, I think we really should standardize what gets reported in these
> > > debug traps instead of letting each arch do its own thing.
> > 
> > May be we can standardize .si_info within the single arch at least ;)
> > 
> > I never understood what TRAP_HWBKPT/TRAP_BRKPT actually means, and
> > I can be easily wrong. But, afaics, on x86 PTRACE_SINGLESTEP results
> > in TRAP_TRACE. Unless the tracee steps over syscall, in this case
> > user_single_step_siginfo() sets TRAP_BRKPT. Hmm.
> > 
> > And unless I misread 248bed4b0f3c s390 thinks we need TRAP_HWBKPT.
> 
> Yeah, it looks like a proper mess.  It seems ptrace left too much for
> archs to decide.  Events to be reported should be defined by generic
> ptrace code (there can be some exceptions but only few) and archs
> should provide the mechanisms to implement them.  I'm planning on
> going through ptrace arch specifics soonish.  Hopefully it can be
> cleaned up somehow.

The ptrace code differs because the architectures are different in
regard to tracing, no? For s390 instruction single stepping and
hardware breakpoints are the same thing. It all gets mapped to the
progam-event-recording (PER) tracer. You have a start and an end
address and a few events you want to see for this area (e.g.
instruction fetch or storage alteration).
I could special case ptrace with PTRACE_SINGLESTEP to return with
TRAP_TRACE instead of TRAP_HWBKPT but that would be artificial.
>From the hardware perspective its the same.

-- 
blue skies,
   Martin.

"Reality continues to ruin my life." - Calvin.

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ