]> git.baikalelectronics.ru Git - kernel.git/commit
powerpc: Update ptrace to use ppc_breakpoint_available()
authorMichael Neuling <mikey@neuling.org>
Tue, 27 Mar 2018 04:37:18 +0000 (15:37 +1100)
committerMichael Ellerman <mpe@ellerman.id.au>
Tue, 27 Mar 2018 12:52:44 +0000 (23:52 +1100)
commit0137a686352429996f2a8b87ac506c079c887f76
tree4c787a07c93c73500e80833bc5a31a150fea98be
parent0f74b1bb10f7d6e924d3a5b114fe7f81961a0703
powerpc: Update ptrace to use ppc_breakpoint_available()

This updates the ptrace code to use ppc_breakpoint_available().

We now advertise via PPC_PTRACE_GETHWDBGINFO zero breakpoints when the
DAWR is missing (ie. POWER9). This results in GDB falling back to
software emulation of the breakpoint (which is slow).

For the features advertised by PPC_PTRACE_GETHWDBGINFO, we keep
advertising DAWR as if we don't GDB assumes 1 breakpoint irrespective
of the number of breakpoints advertised. GDB then fails later when
trying to set this one breakpoint.

Signed-off-by: Michael Neuling <mikey@neuling.org>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
arch/powerpc/kernel/hw_breakpoint.c
arch/powerpc/kernel/ptrace.c