xemu/linux-user
Laurent Vivier 86e636951d linux-user: fix __NR_semtimedop undeclared error
In current code, __NR_msgrcv and__NR_semtimedop are supposed to be
defined if __NR_msgsnd is defined.

But linux headers 5.2-rc1 for MIPS define __NR_msgsnd without defining
__NR_semtimedop and it breaks the QEMU build.

__NR_semtimedop is defined in asm-mips/unistd_n64.h and asm-mips/unistd_n32.h
but not in asm-mips/unistd_o32.h.

Commit d9cb433615 ("linux headers: update against Linux 5.2-rc1") has
updated asm-mips/unistd_o32.h and added __NR_msgsnd but not __NR_semtimedop.
It introduces __NR_semtimedop_time64 instead.

This patch fixes the problem by checking for each __NR_XXX symbol
before defining the corresponding syscall.

Fixes: d9cb433615 ("linux headers: update against Linux 5.2-rc1")
Reported-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Signed-off-by: Laurent Vivier <laurent@vivier.eu>
Signed-off-by: Aleksandar Markovic <amarkovic@wavecomp.com>
Tested-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Reviewed-by: Cornelia Huck <cohuck@redhat.com>
Reviewed-by: Alex Bennée <alex.bennee@linaro.org>
Tested-by: Alex Bennée <alex.bennee@linaro.org>
Message-Id: <20190523175413.14448-1-laurent@vivier.eu>
2019-05-26 17:44:33 +02:00
..
aarch64 target/arm: Put all PAC keys into a structure 2019-05-22 12:38:54 -04:00
alpha qom/cpu: Simplify how CPUClass:cpu_dump_state() prints 2019-04-18 22:18:59 +02:00
arm linux-user: Don't call gdb_handlesig() before queue_signal() 2018-11-12 15:48:00 +01:00
cris qom/cpu: Simplify how CPUClass:cpu_dump_state() prints 2019-04-18 22:18:59 +02:00
generic linux-user: move generic signal definitions to generic/signal.h 2018-06-04 01:30:44 +02:00
host linux-user: Add safe_syscall for riscv64 host 2018-12-26 06:40:02 +11:00
hppa linux-user: Don't call gdb_handlesig() before queue_signal() 2018-11-12 15:48:00 +01:00
i386 linux-user: Don't call gdb_handlesig() before queue_signal() 2018-11-12 15:48:00 +01:00
m68k target/m68k: Fix LGPL information in the file headers 2019-01-30 14:20:13 +01:00
microblaze qom/cpu: Simplify how CPUClass:cpu_dump_state() prints 2019-04-18 22:18:59 +02:00
mips target/mips: reimplement SC instruction emulation and use cmpxchg 2019-02-14 17:47:28 +01:00
mips64 linux-user: Add prctl() PR_SET_FP_MODE and PR_GET_FP_MODE implementations 2018-10-29 15:50:31 +01:00
nios2 linux-user/nios2 linux-user/riscv: Clean up header guards 2019-05-13 08:58:55 +02:00
openrisc target/openrisc: Fix LGPL information in the file headers 2019-05-08 17:45:54 +02:00
ppc target/ppc: move FP and VMX registers into aligned vsr register array 2019-01-09 09:28:14 +11:00
riscv linux-user/nios2 linux-user/riscv: Clean up header guards 2019-05-13 08:58:55 +02:00
s390x qom/cpu: Simplify how CPUClass:cpu_dump_state() prints 2019-04-18 22:18:59 +02:00
sh4 target/sh4: Fix LGPL information in the file headers 2019-05-08 17:45:54 +02:00
sparc qom/cpu: Simplify how CPUClass:cpu_dump_state() prints 2019-04-18 22:18:59 +02:00
sparc64 linux-user/sparc64: Add inotify_rm_watch and tee syscalls 2018-06-11 14:47:45 +02:00
tilegx linux-user: move generic signal definitions to generic/signal.h 2018-06-04 01:30:44 +02:00
x86_64 remove space-tab sequences 2019-01-11 15:46:55 +01:00
xtensa Clean up ill-advised or unusual header guards 2019-05-13 08:58:55 +02:00
cpu_loop-common.h qom/cpu: Simplify how CPUClass:cpu_dump_state() prints 2019-04-18 22:18:59 +02:00
elfload.c Add /proc/hardware and /proc/cpuinfo, 2019-05-24 12:47:49 +01:00
errno_defs.h linux-user: Handle ERFKILL and EHWPOISON 2017-01-22 18:14:10 -08:00
exit.c linux-user: fix GPROF build failure 2019-05-10 12:44:23 +02:00
fd-trans.c linux-user: add new netlink types 2019-03-07 11:02:33 +01:00
fd-trans.h linux-user: move TargetFdTrans functions to their own file 2018-09-25 22:36:47 +02:00
flat.h
flatload.c linux-user/flatload: fix initial stack pointer alignment 2018-10-30 11:23:32 -07:00
ioctls.h linux-user: Add support for SIOC<G|S>IFPFLAGS ioctls for all targets 2019-05-22 20:50:55 +02:00
linux_loop.h linux-user: Add loop control ioctls 2016-07-19 15:22:33 +03:00
linuxload.c avoid TABs in files that only contain a few 2019-01-11 15:46:56 +01:00
m68k-sim.c linux-user: Clean up includes 2016-01-29 15:07:22 +00:00
main.c linux-user: Remove srand call 2019-05-22 12:38:54 -04:00
Makefile.objs linux-user: move TargetFdTrans functions to their own file 2018-09-25 22:36:47 +02:00
mmap.c linux-user: Align mmap_find_vma to host page size 2019-05-24 13:16:21 +02:00
qemu.h linux-user: Fix shmat emulation by honoring host SHMLBA 2019-05-24 13:16:21 +02:00
safe-syscall.S linux-user: Provide safe_syscall for fixing races between signals and syscalls 2016-05-27 14:49:51 +03:00
signal-common.h linux-user: introduce target_sigsp() and target_save_altstack() 2018-05-03 18:29:15 +02:00
signal.c linux-user: avoid treading on gprof's SIGPROF signals 2019-05-10 12:44:23 +02:00
socket.h linux-user: update ARCH_HAS_SOCKET_TYPES use 2018-05-25 10:10:55 +02:00
strace.c linux-user: Nicer strace output of chroot() syscall 2019-03-07 10:57:29 +01:00
strace.list linux-user: Nicer strace output of chroot() syscall 2019-03-07 10:57:29 +01:00
syscall_defs.h linux-user: Pass through nanosecond timestamp components for stat syscalls 2019-05-24 13:16:21 +02:00
syscall_types.h linux-user: Implement special usbfs ioctls. 2018-10-19 14:05:10 +02:00
syscall.c linux-user: fix __NR_semtimedop undeclared error 2019-05-26 17:44:33 +02:00
target_flat.h
trace-events trace-events: Fix attribution of trace points to source 2019-03-22 16:18:07 +00:00
uaccess.c avoid TABs in files that only contain a few 2019-01-11 15:46:56 +01:00
uname.c linux-user: avoid string truncation warnings in uname field copying 2019-05-09 17:27:38 +02:00
uname.h Clean up decorations and whitespace around header guards 2016-07-12 16:20:46 +02:00
vm86.c avoid TABs in files that only contain a few 2019-01-11 15:46:56 +01:00