summary refs log tree commit diff
path: root/fs
diff options
context:
space:
mode:
authorSven Schnelle <svens@stackframe.org>2021-11-13 20:41:17 +0100
committerHelge Deller <deller@gmx.de>2021-11-13 22:10:56 +0100
commit3ec18fc7831e7d79e2d536dd1f3bc0d3ba425e8a (patch)
treec07716bb390f5f21a05b90e9894bba0c21d86a15 /fs
parent38860b2c8bb1b92f61396eb06a63adff916fc31d (diff)
downloadlinux-3ec18fc7831e7d79e2d536dd1f3bc0d3ba425e8a.tar.gz
parisc/entry: fix trace test in syscall exit path
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>
Diffstat (limited to 'fs')
0 files changed, 0 insertions, 0 deletions