[PATCH 0/4] powerpc: clean up pt_regs traps handling
Nicholas Piggin
npiggin at gmail.com
Tue Apr 21 12:19:51 AEST 2020
scv support needs to test trap in some cases to distinguish sc from scv,
so it helps to have a few tidy-up patches to start with. This turned
into a slightly bigger job that we needed to do to clean up the double
restart logic that today zeroes traps which is ugly.
Thanks,
Nick
Nicholas Piggin (4):
powerpc/64s: Always has full regs, so remove remnant checks
powerpc: Use SET_TRAP and avoid open-coding trap masking
powerpc: TRAP_IS_SYSCALL helper to hide syscall trap number
powerpc: Use trap metadata to prevent double restart rather than
zeroing trap
arch/powerpc/include/asm/ptrace.h | 31 +++-
arch/powerpc/include/asm/syscall.h | 5 +-
arch/powerpc/kernel/process.c | 4 +-
arch/powerpc/kernel/ptrace/ptrace-tm.c | 2 +-
arch/powerpc/kernel/ptrace/ptrace-view.c | 2 +-
arch/powerpc/kernel/signal.c | 9 +-
arch/powerpc/kernel/signal_32.c | 2 +-
arch/powerpc/kernel/signal_64.c | 10 +-
arch/powerpc/xmon/xmon.c | 4 +-
.../testing/selftests/powerpc/signal/Makefile | 2 +-
.../powerpc/signal/sig_sc_double_restart.c | 174 ++++++++++++++++++
11 files changed, 220 insertions(+), 25 deletions(-)
create mode 100644 tools/testing/selftests/powerpc/signal/sig_sc_double_restart.c
--
2.23.0
More information about the Linuxppc-dev
mailing list