From 3674bfadb503e535250730be5df563f0d9928917 Mon Sep 17 00:00:00 2001 From: Ilya Leoshkevich Date: Thu, 12 Sep 2024 11:28:21 +0200 Subject: linux-user/i386: Emulate orig_ax The kernel uses orig_rax/orig_eax to store the syscall number before a syscall. One can see this value in core dumps and ptrace. Reviewed-by: Richard Henderson Signed-off-by: Ilya Leoshkevich Message-ID: <20240912093012.402366-3-iii@linux.ibm.com> Signed-off-by: Richard Henderson --- linux-user/qemu.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'linux-user/qemu.h') diff --git a/linux-user/qemu.h b/linux-user/qemu.h index 98ad848ab2..895bdd722a 100644 --- a/linux-user/qemu.h +++ b/linux-user/qemu.h @@ -113,6 +113,10 @@ struct TaskState { struct target_vm86plus_struct vm86plus; uint32_t v86flags; uint32_t v86mask; +#endif +#if defined(TARGET_I386) + /* Last syscall number. */ + target_ulong orig_ax; #endif abi_ulong child_tidptr; #ifdef TARGET_M68K -- cgit 1.4.1