acrn-kernel/arch/x86
Andy Lutomirski 5e99cb7c35 x86/entry/64/compat: Fix bad fast syscall arg failure path
If user code does SYSCALL32 or SYSENTER without a valid stack,
then our attempt to determine the syscall args will result in a
failed uaccess fault.  Previously, we would try to recover by
jumping to the syscall exit code, but we'd run the syscall exit
work even though we never made it to the syscall entry work.

Clean it up by treating the failure path as a non-syscall entry
and exit pair.

This fixes strace's output when running the syscall_arg_fault
test. Without this fix, strace would get out of sync and would
fail to associate syscall entries with syscall exits.

Signed-off-by: Andy Lutomirski <luto@kernel.org>
Cc: Andy Lutomirski <luto@amacapital.net>
Cc: Borislav Petkov <bp@alien8.de>
Cc: Brian Gerst <brgerst@gmail.com>
Cc: Denys Vlasenko <dvlasenk@redhat.com>
Cc: Denys Vlasenko <vda.linux@googlemail.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: H. Peter Anvin <hpa@zytor.com>
Cc: Kees Cook <keescook@chromium.org>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Oleg Nesterov <oleg@redhat.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Rik van Riel <riel@redhat.com>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: paulmck@linux.vnet.ibm.com
Link: http://lkml.kernel.org/r/903010762c07a3d67df914fea2da84b52b0f8f1d.1435952415.git.luto@kernel.org
Signed-off-by: Ingo Molnar <mingo@kernel.org>
2015-07-07 10:58:30 +02:00
..
boot x86/asm/tsc: Rename native_read_tsc() to rdtsc() 2015-07-06 15:23:28 +02:00
configs
crypto crypto: aesni - fix failing setkey for rfc4106-gcm-aesni 2015-06-29 16:06:30 +08:00
entry x86/entry/64/compat: Fix bad fast syscall arg failure path 2015-07-07 10:58:30 +02:00
ia32 x86/compat: Move copy_siginfo_*_user32() to signal_compat.c 2015-07-06 15:28:55 +02:00
include x86/compat: Don't build the 32-bit VDSO if not needed 2015-07-06 15:28:56 +02:00
kernel x86/compat: Remove unneeded #include 2015-07-06 15:28:57 +02:00
kvm x86/asm/tsc: Add rdtsc_ordered() and use it in trivial call sites 2015-07-06 15:23:29 +02:00
lguest
lib x86/asm/tsc: Add rdtsc_ordered() and use it in trivial call sites 2015-07-06 15:23:29 +02:00
math-emu
mm mm/memblock: add extra "flags" to memblock to allow selection of memory based on attribute 2015-06-24 17:49:44 -07:00
net
oprofile
pci
platform Replace module_init with equivalent device_initcall in non modules. 2015-07-02 10:30:48 -07:00
power
purgatory
realmode
tools
um x86/asm/tsc: Remove rdtsc_barrier() 2015-07-06 15:23:30 +02:00
video
xen x86/asm/tsc, x86/paravirt: Remove read_tsc() and read_tscp() paravirt hooks 2015-07-06 15:23:26 +02:00
.gitignore
Kbuild
Kconfig x86/compat: Separate ia32 and x32 compat ABIs 2015-07-06 15:28:58 +02:00
Kconfig.cpu
Kconfig.debug
Makefile
Makefile.um
Makefile_32.cpu