aboutsummaryrefslogtreecommitdiff
path: root/linux-user/syscall_defs.h
diff options
context:
space:
mode:
authorPeter Maydell <peter.maydell@linaro.org>2016-06-08 18:34:32 +0100
committerPeter Maydell <peter.maydell@linaro.org>2016-06-08 18:34:32 +0100
commitb66e10e4c9ae738412b9742db49457f6b703e349 (patch)
tree3e4544fbfb64b34e2b6f0fa01cad544e0d43f0e8 /linux-user/syscall_defs.h
parent6f50f25c825fbd0edd2dc43b9a63edfecfd4a3e9 (diff)
parent014628a705bdaf31c09915c29e61f4088956564d (diff)
Merge remote-tracking branch 'remotes/riku/tags/pull-linux-user-20160608' into staging
linux-user pull request for June 2016 # gpg: Signature made Wed 08 Jun 2016 14:27:14 BST # gpg: using RSA key 0xB44890DEDE3C9BC0 # gpg: Good signature from "Riku Voipio <riku.voipio@iki.fi>" # gpg: aka "Riku Voipio <riku.voipio@linaro.org>" * remotes/riku/tags/pull-linux-user-20160608: (44 commits) linux-user: In fork_end(), remove correct CPUs from CPU list linux-user: Special-case ERESTARTSYS in target_strerror() linux-user: Make target_strerror() return 'const char *' linux-user: Correct signedness of target_flock l_start and l_len fields linux-user: Use safe_syscall wrapper for ioctl linux-user: Use safe_syscall wrapper for accept and accept4 syscalls linux-user: Use safe_syscall wrapper for semop linux-user: Use safe_syscall wrapper for epoll_wait syscalls linux-user: Use safe_syscall wrapper for poll and ppoll syscalls linux-user: Use safe_syscall wrapper for sleep syscalls linux-user: Use safe_syscall wrapper for rt_sigtimedwait syscall linux-user: Use safe_syscall wrapper for flock linux-user: Use safe_syscall wrapper for mq_timedsend and mq_timedreceive linux-user: Use safe_syscall wrapper for msgsnd and msgrcv linux-user: Use safe_syscall wrapper for send* and recv* syscalls linux-user: Use safe_syscall wrapper for connect syscall linux-user: Use safe_syscall wrapper for readv and writev syscalls linux-user: Fix error conversion in 64-bit fadvise syscall linux-user: Fix NR_fadvise64 and NR_fadvise64_64 for 32-bit guests linux-user: Fix handling of arm_fadvise64_64 syscall ... Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Conflicts: configure scripts/qemu-binfmt-conf.sh
Diffstat (limited to 'linux-user/syscall_defs.h')
-rw-r--r--linux-user/syscall_defs.h49
1 files changed, 32 insertions, 17 deletions
diff --git a/linux-user/syscall_defs.h b/linux-user/syscall_defs.h
index 34af15a683..6ee9251c50 100644
--- a/linux-user/syscall_defs.h
+++ b/linux-user/syscall_defs.h
@@ -673,6 +673,21 @@ typedef struct {
#define TARGET_SI_PAD_SIZE ((TARGET_SI_MAX_SIZE - TARGET_SI_PREAMBLE_SIZE) / sizeof(int))
+/* Within QEMU the top 16 bits of si_code indicate which of the parts of
+ * the union in target_siginfo is valid. This only applies between
+ * host_to_target_siginfo_noswap() and tswap_siginfo(); it does not
+ * appear either within host siginfo_t or in target_siginfo structures
+ * which we get from the guest userspace program. (The Linux kernel
+ * does a similar thing with using the top bits for its own internal
+ * purposes but not letting them be visible to userspace.)
+ */
+#define QEMU_SI_KILL 0
+#define QEMU_SI_TIMER 1
+#define QEMU_SI_POLL 2
+#define QEMU_SI_FAULT 3
+#define QEMU_SI_CHLD 4
+#define QEMU_SI_RT 5
+
typedef struct target_siginfo {
#ifdef TARGET_MIPS
int si_signo;
@@ -2274,34 +2289,34 @@ struct target_statfs64 {
#endif
struct target_flock {
- short l_type;
- short l_whence;
- abi_ulong l_start;
- abi_ulong l_len;
- int l_pid;
+ short l_type;
+ short l_whence;
+ abi_long l_start;
+ abi_long l_len;
+ int l_pid;
};
struct target_flock64 {
- short l_type;
- short l_whence;
+ short l_type;
+ short l_whence;
#if defined(TARGET_PPC) || defined(TARGET_X86_64) || defined(TARGET_MIPS) \
|| defined(TARGET_SPARC) || defined(TARGET_HPPA) \
|| defined(TARGET_MICROBLAZE) || defined(TARGET_TILEGX)
- int __pad;
+ int __pad;
#endif
- unsigned long long l_start;
- unsigned long long l_len;
- int l_pid;
+ abi_llong l_start;
+ abi_llong l_len;
+ int l_pid;
} QEMU_PACKED;
#ifdef TARGET_ARM
struct target_eabi_flock64 {
- short l_type;
- short l_whence;
- int __pad;
- unsigned long long l_start;
- unsigned long long l_len;
- int l_pid;
+ short l_type;
+ short l_whence;
+ int __pad;
+ abi_llong l_start;
+ abi_llong l_len;
+ int l_pid;
} QEMU_PACKED;
#endif