android_kernel_motorola_sm6375/arch
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Sven Schnelle 7186be970c parisc/entry: fix trace test in syscall exit path
commit 3ec18fc7831e7d79e2d536dd1f3bc0d3ba425e8a upstream.

commit 8779e05ba8aa ("parisc: Fix ptrace check on syscall return")
fixed testing of TI_FLAGS. This uncovered a bug in the test mask.
syscall_restore_rfi is only used when the kernel needs to exit to
usespace with single or block stepping and the recovery counter
enabled. The test however used _TIF_SYSCALL_TRACE_MASK, which
includes a lot of bits that shouldn't be tested here.

Fix this by using TIF_SINGLESTEP and TIF_BLOCKSTEP directly.

I encountered this bug by enabling syscall tracepoints. Both in qemu and
on real hardware. As soon as i enabled the tracepoint (sys_exit_read,
but i guess it doesn't really matter which one), i got random page
faults in userspace almost immediately.

Signed-off-by: Sven Schnelle <svens@stackframe.org>
Signed-off-by: Helge Deller <deller@gmx.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2021-11-21 13:38:50 +01:00
..
alpha
arc
arm ARM: 9156/1: drop cc-option fallbacks for architecture selection 2021-11-17 09:48:48 +01:00
arm64 arm64: pgtable: make __pte_to_phys/__phys_to_pte_val inline functions 2021-11-17 09:48:47 +01:00
c6x
csky csky: Fixup regs.sr broken in ptrace 2021-10-20 11:40:12 +02:00
h8300
hexagon
ia64 ia64: don't do IA64_CMPXCHG_DEBUG without CONFIG_PRINTK 2021-11-17 09:48:29 +01:00
m68k m68k: set a default value for MEMORY_RESERVE 2021-11-17 09:48:46 +01:00
microblaze
mips MIPS: Fix assembly error from MIPSr2 code used within MIPS_ISA_ARCH_LEVEL 2021-11-21 13:38:50 +01:00
nds32
nios2 nios2: Make NIOS2_DTB_SOURCE_BOOL depend on !COMPILE_TEST 2021-11-02 19:46:14 +01:00
openrisc
parisc parisc/entry: fix trace test in syscall exit path 2021-11-21 13:38:50 +01:00
powerpc powerpc/powernv/prd: Unregister OPAL_MSG_PRD2 notifier during module unload 2021-11-17 09:48:50 +01:00
riscv RISC-V: Include clone3() on rv32 2021-10-13 10:08:20 +02:00
s390 KVM: s390: Fix handle_sske page fault handling 2021-11-17 09:48:39 +01:00
sh signal/sh: Use force_sig(SIGKILL) instead of do_group_exit(SIGKILL) 2021-11-17 09:48:46 +01:00
sparc
um
unicore32
x86 x86/hyperv: Protect set_hv_tscchange_cb() against getting preempted 2021-11-17 09:48:33 +01:00
xtensa xtensa: xtfpga: Try software restart before simulating CPU reset 2021-10-27 09:54:25 +02:00
.gitignore
Kconfig