mirror of https://github.com/torvalds/linux.git
Introduce tests to cover simple scenarios where user is watching memory which can be accessed by kernel as well. We also support _MODE_EXACT with _SETHWDEBUG interface. Move those testcases outside of _BP_RANGE condition. This will help to test _MODE_EXACT scenarios when CONFIG_HAVE_HW_BREAKPOINT is not set, eg: $ ./ptrace-hwbreak ... PTRACE_SET_DEBUGREG, Kernel Access Userspace, len: 8: Ok PPC_PTRACE_SETHWDEBUG, MODE_EXACT, WO, len: 1: Ok PPC_PTRACE_SETHWDEBUG, MODE_EXACT, RO, len: 1: Ok PPC_PTRACE_SETHWDEBUG, MODE_EXACT, RW, len: 1: Ok PPC_PTRACE_SETHWDEBUG, MODE_EXACT, Kernel Access Userspace, len: 1: Ok success: ptrace-hwbreak Suggested-by: Pedro Miraglia Franco de Carvalho <pedromfc@linux.ibm.com> Signed-off-by: Ravi Bangoria <ravi.bangoria@linux.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> Link: https://lore.kernel.org/r/20200902042945.129369-9-ravi.bangoria@linux.ibm.com |
||
|---|---|---|
| .. | ||
| .gitignore | ||
| Makefile | ||
| child.h | ||
| core-pkey.c | ||
| perf-hwbreak.c | ||
| ptrace-gpr.c | ||
| ptrace-gpr.h | ||
| ptrace-hwbreak.c | ||
| ptrace-pkey.c | ||
| ptrace-syscall.c | ||
| ptrace-tar.c | ||
| ptrace-tar.h | ||
| ptrace-tm-gpr.c | ||
| ptrace-tm-spd-gpr.c | ||
| ptrace-tm-spd-tar.c | ||
| ptrace-tm-spd-vsx.c | ||
| ptrace-tm-spr.c | ||
| ptrace-tm-tar.c | ||
| ptrace-tm-vsx.c | ||
| ptrace-vsx.c | ||
| ptrace-vsx.h | ||
| ptrace.h | ||