diff mbox series

[PULL,3/4] linux-user: Fix member types of target_dirent64

Message ID 20211111110504.1574242-4-laurent@vivier.eu
State Superseded
Headers show
Series [PULL,1/4] linux-user: Split out do_getdents, do_getdents64 | expand

Commit Message

Laurent Vivier Nov. 11, 2021, 11:05 a.m. UTC
From: Richard Henderson <richard.henderson@linaro.org>

The host uint64_t (etc) does not have the correct
alignment constraint as the guest: use abi_* types.

Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Reviewed by: Warner Losh <imp@bsdimp.com>
Message-Id: <20211107124845.1174791-4-richard.henderson@linaro.org>
Signed-off-by: Laurent Vivier <laurent@vivier.eu>
---
 linux-user/syscall_defs.h | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
diff mbox series

Patch

diff --git a/linux-user/syscall_defs.h b/linux-user/syscall_defs.h
index 98b09ee6d656..41aaafbac12c 100644
--- a/linux-user/syscall_defs.h
+++ b/linux-user/syscall_defs.h
@@ -437,9 +437,9 @@  struct target_dirent {
 };
 
 struct target_dirent64 {
-	uint64_t	d_ino;
-	int64_t		d_off;
-	unsigned short	d_reclen;
+	abi_ullong      d_ino;
+	abi_llong       d_off;
+	abi_ushort      d_reclen;
 	unsigned char	d_type;
 	char		d_name[];
 };