We want to access the target errno indepently of the rest of the linux-user code. Extract it to a new target-specific header: 'target_errno_defs.h'.
Signed-off-by: Philippe Mathieu-Daudé <f4...@amsat.org> --- linux-user/aarch64/target_errno_defs.h | 6 ++++++ linux-user/alpha/target_errno_defs.h | 4 ++++ linux-user/arm/target_errno_defs.h | 6 ++++++ linux-user/cris/target_errno_defs.h | 6 ++++++ linux-user/errno_defs.h | 3 +++ linux-user/hexagon/target_errno_defs.h | 6 ++++++ linux-user/hppa/target_errno_defs.h | 4 ++++ linux-user/i386/target_errno_defs.h | 6 ++++++ linux-user/m68k/target_errno_defs.h | 6 ++++++ linux-user/microblaze/target_errno_defs.h | 6 ++++++ linux-user/mips/target_errno_defs.h | 4 ++++ linux-user/mips64/target_errno_defs.h | 4 ++++ linux-user/nios2/target_errno_defs.h | 6 ++++++ linux-user/openrisc/target_errno_defs.h | 6 ++++++ linux-user/ppc/target_errno_defs.h | 6 ++++++ linux-user/riscv/target_errno_defs.h | 6 ++++++ linux-user/s390x/target_errno_defs.h | 6 ++++++ linux-user/sh4/target_errno_defs.h | 6 ++++++ linux-user/sparc/target_syscall.h | 2 -- linux-user/x86_64/target_errno_defs.h | 6 ++++++ linux-user/xtensa/target_errno_defs.h | 6 ++++++ 21 files changed, 109 insertions(+), 2 deletions(-) create mode 100644 linux-user/aarch64/target_errno_defs.h create mode 100644 linux-user/alpha/target_errno_defs.h create mode 100644 linux-user/arm/target_errno_defs.h create mode 100644 linux-user/cris/target_errno_defs.h create mode 100644 linux-user/hexagon/target_errno_defs.h create mode 100644 linux-user/hppa/target_errno_defs.h create mode 100644 linux-user/i386/target_errno_defs.h create mode 100644 linux-user/m68k/target_errno_defs.h create mode 100644 linux-user/microblaze/target_errno_defs.h create mode 100644 linux-user/mips/target_errno_defs.h create mode 100644 linux-user/mips64/target_errno_defs.h create mode 100644 linux-user/nios2/target_errno_defs.h create mode 100644 linux-user/openrisc/target_errno_defs.h create mode 100644 linux-user/ppc/target_errno_defs.h create mode 100644 linux-user/riscv/target_errno_defs.h create mode 100644 linux-user/s390x/target_errno_defs.h create mode 100644 linux-user/sh4/target_errno_defs.h create mode 100644 linux-user/x86_64/target_errno_defs.h create mode 100644 linux-user/xtensa/target_errno_defs.h diff --git a/linux-user/aarch64/target_errno_defs.h b/linux-user/aarch64/target_errno_defs.h new file mode 100644 index 00000000000..a809381165a --- /dev/null +++ b/linux-user/aarch64/target_errno_defs.h @@ -0,0 +1,6 @@ +#ifndef AARCH64_TARGET_ERRNO_H +#define AARCH64_TARGET_ERRNO_H + +/* Target uses generic errno */ + +#endif diff --git a/linux-user/alpha/target_errno_defs.h b/linux-user/alpha/target_errno_defs.h new file mode 100644 index 00000000000..13770b14b82 --- /dev/null +++ b/linux-user/alpha/target_errno_defs.h @@ -0,0 +1,4 @@ +#ifndef ALPHA_TARGET_ERRNO_H +#define ALPHA_TARGET_ERRNO_H + +#endif diff --git a/linux-user/arm/target_errno_defs.h b/linux-user/arm/target_errno_defs.h new file mode 100644 index 00000000000..3d0dc8a6fb3 --- /dev/null +++ b/linux-user/arm/target_errno_defs.h @@ -0,0 +1,6 @@ +#ifndef ARM_TARGET_ERRNO_H +#define ARM_TARGET_ERRNO_H + +/* Target uses generic errno */ + +#endif diff --git a/linux-user/cris/target_errno_defs.h b/linux-user/cris/target_errno_defs.h new file mode 100644 index 00000000000..c6ea84f2366 --- /dev/null +++ b/linux-user/cris/target_errno_defs.h @@ -0,0 +1,6 @@ +#ifndef CRIS_TARGET_ERRNO_H +#define CRIS_TARGET_ERRNO_H + +/* Target uses generic errno */ + +#endif diff --git a/linux-user/errno_defs.h b/linux-user/errno_defs.h index aaf5208d62d..01cfb08b802 100644 --- a/linux-user/errno_defs.h +++ b/linux-user/errno_defs.h @@ -164,4 +164,7 @@ */ #define TARGET_QEMU_ESIGRETURN 513 /* Return from signal */ +/* Override with target specific definitions of errnos (keep last). */ +#include "target_errno_defs.h" + #endif diff --git a/linux-user/hexagon/target_errno_defs.h b/linux-user/hexagon/target_errno_defs.h new file mode 100644 index 00000000000..5daac4f5a83 --- /dev/null +++ b/linux-user/hexagon/target_errno_defs.h @@ -0,0 +1,6 @@ +#ifndef HEXAGON_TARGET_ERRNO_H +#define HEXAGON_TARGET_ERRNO_H + +/* Target uses generic errno */ + +#endif diff --git a/linux-user/hppa/target_errno_defs.h b/linux-user/hppa/target_errno_defs.h new file mode 100644 index 00000000000..5ae6b8d0ba2 --- /dev/null +++ b/linux-user/hppa/target_errno_defs.h @@ -0,0 +1,4 @@ +#ifndef HPPA_TARGET_ERRNO_H +#define HPPA_TARGET_ERRNO_H + +#endif diff --git a/linux-user/i386/target_errno_defs.h b/linux-user/i386/target_errno_defs.h new file mode 100644 index 00000000000..14f9fc44bec --- /dev/null +++ b/linux-user/i386/target_errno_defs.h @@ -0,0 +1,6 @@ +#ifndef I386_TARGET_ERRNO_H +#define I386_TARGET_ERRNO_H + +/* Target uses generic errno */ + +#endif diff --git a/linux-user/m68k/target_errno_defs.h b/linux-user/m68k/target_errno_defs.h new file mode 100644 index 00000000000..00b98c619e5 --- /dev/null +++ b/linux-user/m68k/target_errno_defs.h @@ -0,0 +1,6 @@ +#ifndef M68K_TARGET_ERRNO_H +#define M68K_TARGET_ERRNO_H + +/* Target uses generic errno */ + +#endif diff --git a/linux-user/microblaze/target_errno_defs.h b/linux-user/microblaze/target_errno_defs.h new file mode 100644 index 00000000000..014f19ffbc5 --- /dev/null +++ b/linux-user/microblaze/target_errno_defs.h @@ -0,0 +1,6 @@ +#ifndef MICROBLAZE_TARGET_ERRNO_H +#define MICROBLAZE_TARGET_ERRNO_H + +/* Target uses generic errno */ + +#endif diff --git a/linux-user/mips/target_errno_defs.h b/linux-user/mips/target_errno_defs.h new file mode 100644 index 00000000000..05e0bea44bc --- /dev/null +++ b/linux-user/mips/target_errno_defs.h @@ -0,0 +1,4 @@ +#ifndef MIPS_TARGET_ERRNO_H +#define MIPS_TARGET_ERRNO_H + +#endif diff --git a/linux-user/mips64/target_errno_defs.h b/linux-user/mips64/target_errno_defs.h new file mode 100644 index 00000000000..0dd5966d1af --- /dev/null +++ b/linux-user/mips64/target_errno_defs.h @@ -0,0 +1,4 @@ +#ifndef MIPS64_TARGET_ERRNO_H +#define MIPS64_TARGET_ERRNO_H + +#endif diff --git a/linux-user/nios2/target_errno_defs.h b/linux-user/nios2/target_errno_defs.h new file mode 100644 index 00000000000..81f86566f26 --- /dev/null +++ b/linux-user/nios2/target_errno_defs.h @@ -0,0 +1,6 @@ +#ifndef NIOS2_TARGET_ERRNO_H +#define NIOS2_TARGET_ERRNO_H + +/* Target uses generic errno */ + +#endif diff --git a/linux-user/openrisc/target_errno_defs.h b/linux-user/openrisc/target_errno_defs.h new file mode 100644 index 00000000000..4dabdc1a43f --- /dev/null +++ b/linux-user/openrisc/target_errno_defs.h @@ -0,0 +1,6 @@ +#ifndef OR1K_TARGET_ERRNO_H +#define OR1K_TARGET_ERRNO_H + +/* Target uses generic errno */ + +#endif diff --git a/linux-user/ppc/target_errno_defs.h b/linux-user/ppc/target_errno_defs.h new file mode 100644 index 00000000000..743e65cf4ef --- /dev/null +++ b/linux-user/ppc/target_errno_defs.h @@ -0,0 +1,6 @@ +#ifndef PPC_TARGET_ERRNO_H +#define PPC_TARGET_ERRNO_H + +/* Target uses generic errno */ + +#endif diff --git a/linux-user/riscv/target_errno_defs.h b/linux-user/riscv/target_errno_defs.h new file mode 100644 index 00000000000..bf06966dc18 --- /dev/null +++ b/linux-user/riscv/target_errno_defs.h @@ -0,0 +1,6 @@ +#ifndef RISCV_TARGET_ERRNO_H +#define RISCV_TARGET_ERRNO_H + +/* Target uses generic errno */ + +#endif diff --git a/linux-user/s390x/target_errno_defs.h b/linux-user/s390x/target_errno_defs.h new file mode 100644 index 00000000000..1f0003166df --- /dev/null +++ b/linux-user/s390x/target_errno_defs.h @@ -0,0 +1,6 @@ +#ifndef S390X_TARGET_ERRNO_H +#define S390X_TARGET_ERRNO_H + +/* Target uses generic errno */ + +#endif diff --git a/linux-user/sh4/target_errno_defs.h b/linux-user/sh4/target_errno_defs.h new file mode 100644 index 00000000000..ee5eb96af88 --- /dev/null +++ b/linux-user/sh4/target_errno_defs.h @@ -0,0 +1,6 @@ +#ifndef SH4_TARGET_ERRNO_H +#define SH4_TARGET_ERRNO_H + +/* Target uses generic errno */ + +#endif diff --git a/linux-user/sparc/target_syscall.h b/linux-user/sparc/target_syscall.h index dad501d008c..087b39d39c4 100644 --- a/linux-user/sparc/target_syscall.h +++ b/linux-user/sparc/target_syscall.h @@ -1,8 +1,6 @@ #ifndef SPARC_TARGET_SYSCALL_H #define SPARC_TARGET_SYSCALL_H -#include "target_errno_defs.h" - #if defined(TARGET_SPARC64) && !defined(TARGET_ABI32) struct target_pt_regs { abi_ulong u_regs[16]; diff --git a/linux-user/x86_64/target_errno_defs.h b/linux-user/x86_64/target_errno_defs.h new file mode 100644 index 00000000000..69cc6f988ba --- /dev/null +++ b/linux-user/x86_64/target_errno_defs.h @@ -0,0 +1,6 @@ +#ifndef X86_64_TARGET_ERRNO_H +#define X86_64_TARGET_ERRNO_H + +/* Target uses generic errno */ + +#endif diff --git a/linux-user/xtensa/target_errno_defs.h b/linux-user/xtensa/target_errno_defs.h new file mode 100644 index 00000000000..4a5d19319d0 --- /dev/null +++ b/linux-user/xtensa/target_errno_defs.h @@ -0,0 +1,6 @@ +#ifndef XTENSA_TARGET_ERRNO_H +#define XTENSA_TARGET_ERRNO_H + +/* FIXME */ + +#endif -- 2.31.1