aboutsummaryrefslogtreecommitdiff
path: root/linux-user
diff options
context:
space:
mode:
authorRichard Henderson <richard.henderson@linaro.org>2025-08-28 21:13:03 +1000
committerRichard Henderson <richard.henderson@linaro.org>2025-08-30 07:04:04 +1000
commit71c2c79815fafe6d509ca1a76bc67d6041aaa37b (patch)
treea9c95900f5415ee0f7505320983f1bf41c0f0422 /linux-user
parent8ad5f12426dd6218db4753722ab240a16a235259 (diff)
downloadqemu-71c2c79815fafe6d509ca1a76bc67d6041aaa37b.zip
qemu-71c2c79815fafe6d509ca1a76bc67d6041aaa37b.tar.gz
qemu-71c2c79815fafe6d509ca1a76bc67d6041aaa37b.tar.bz2
linux-user/s390x: Create target_ptrace.h
Move target_psw_t to target_ptrace.h. Note that abi_ulong already has an attribute for 8-byte alignment, so there's no need to carry another on target_psw_t. Remove the target_pt_regs; add target_s390x_reg to target_ptrace.h, which matches what is actually used. Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Diffstat (limited to 'linux-user')
-rw-r--r--linux-user/s390x/signal.c1
-rw-r--r--linux-user/s390x/target_ptrace.h18
-rw-r--r--linux-user/s390x/target_syscall.h22
3 files changed, 19 insertions, 22 deletions
diff --git a/linux-user/s390x/signal.c b/linux-user/s390x/signal.c
index df49c24..96d1c8d 100644
--- a/linux-user/s390x/signal.c
+++ b/linux-user/s390x/signal.c
@@ -22,6 +22,7 @@
#include "signal-common.h"
#include "linux-user/trace.h"
#include "vdso-asmoffset.h"
+#include "target_ptrace.h"
#define __NUM_GPRS 16
#define __NUM_FPRS 16
diff --git a/linux-user/s390x/target_ptrace.h b/linux-user/s390x/target_ptrace.h
new file mode 100644
index 0000000..a5ceb75
--- /dev/null
+++ b/linux-user/s390x/target_ptrace.h
@@ -0,0 +1,18 @@
+/* SPDX-License-Identifier: GPL-2.0-or-later */
+
+#ifndef S390X_TARGET_PTRACE_H
+#define S390X_TARGET_PTRACE_H
+
+typedef struct {
+ abi_ulong mask;
+ abi_ulong addr;
+} target_psw_t;
+
+struct target_s390_regs {
+ target_psw_t psw;
+ abi_ulong gprs[16];
+ abi_uint acrs[16];
+ abi_ulong orig_gpr2;
+};
+
+#endif /* S390X_TARGET_PTRACE_H */
diff --git a/linux-user/s390x/target_syscall.h b/linux-user/s390x/target_syscall.h
index 4018988..f01f9a0 100644
--- a/linux-user/s390x/target_syscall.h
+++ b/linux-user/s390x/target_syscall.h
@@ -1,28 +1,6 @@
#ifndef S390X_TARGET_SYSCALL_H
#define S390X_TARGET_SYSCALL_H
-/* this typedef defines how a Program Status Word looks like */
-typedef struct {
- abi_ulong mask;
- abi_ulong addr;
-} __attribute__ ((aligned(8))) target_psw_t;
-
-/*
- * The pt_regs struct defines the way the registers are stored on
- * the stack during a system call.
- */
-
-#define TARGET_NUM_GPRS 16
-
-struct target_pt_regs {
- abi_ulong args[1];
- target_psw_t psw;
- abi_ulong gprs[TARGET_NUM_GPRS];
- abi_ulong orig_gpr2;
- unsigned short ilen;
- unsigned short trap;
-};
-
#define UNAME_MACHINE "s390x"
#define UNAME_MINIMUM_RELEASE "2.6.32"