qemu-e2k/linux-user/host/arm
Richard Henderson a3310c0397 linux-user: Move syscall error detection into safe_syscall_base
The current api from safe_syscall_base() is to return -errno, which is
the interface provided by *some* linux kernel abis.  The wrapper macro,
safe_syscall(), detects error, stores into errno, and returns -1, to
match the api of the system syscall().

For those kernel abis that do not return -errno natively, this leads
to double syscall error detection.  E.g. Linux ppc64, which sets the
SO flag for error.

Simplify the usage from C by moving the error detection into assembly,
and usage from assembly by providing a C helper with which to set errno.

Reviewed-by: Warner Losh <imp@bsdimp.com>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
2021-12-19 20:47:33 -08:00
..
host-signal.h linux-user: Add host_signal_set_pc to set pc in mcontext 2021-11-23 01:47:01 +01:00
hostdep.h linux-user/signal.c: Create a common rewind_if_in_safe_syscall 2021-11-23 01:47:20 +01:00
safe-syscall.inc.S linux-user: Move syscall error detection into safe_syscall_base 2021-12-19 20:47:33 -08:00