powerpc/hw-breakpoint: Use generic hw-breakpoint interfaces for new PPC ptrace flags
authorK.Prasad <prasad@linux.vnet.ibm.com>
Thu, 10 May 2012 22:43:38 +0000 (22:43 +0000)
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>
Mon, 14 May 2012 00:48:55 +0000 (10:48 +1000)
commit1b788400bbcbfe25280dc0b8000d2142bfe3be3b
tree2601bdf294a99f2aa03615b67dcc7ceb4750a666
parent404e32e4a8f68d218b73b7db7bb831d887ab6046
powerpc/hw-breakpoint: Use generic hw-breakpoint interfaces for new PPC ptrace flags

PPC_PTRACE_GETHWDBGINFO, PPC_PTRACE_SETHWDEBUG and PPC_PTRACE_DELHWDEBUG are
PowerPC specific ptrace flags that use the watchpoint register. While they are
targeted primarily towards BookE users, user-space applications such as GDB
have started using them for BookS too. This patch enables the use of generic
hardware breakpoint interfaces for these new flags.

Apart from the usual benefits of using generic hw-breakpoint interfaces, these
changes allow debuggers (such as GDB) to use a common set of ptrace flags for
their watchpoint needs and allow more precise breakpoint specification (length
of the variable can be specified).

Signed-off-by: K.Prasad <prasad@linux.vnet.ibm.com>
Acked-by: David Gibson <david@gibson.dropbear.id.au>
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Documentation/powerpc/ptrace.txt
arch/powerpc/kernel/ptrace.c