|
From: | Richard Henderson |
Subject: | Re: [PATCH for 6.2 33/49] bsd-user: Rewrite target system call definintion glue |
Date: | Tue, 10 Aug 2021 05:18:38 -1000 |
User-agent: | Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.11.0 |
On 8/7/21 11:42 AM, Warner Losh wrote:
From: Warner Losh <imp@FreeBSD.org> Rewrite target definnitions to interface with the FreeBSD system calls. This covers basic types (time_t, iovec, umtx_time, timespec, timeval, rusage, rwusage) and basic defines (mmap, rusage). Also included are FreeBSD version-specific variations. Signed-off-by: Stacey Son <sson@FreeBSD.org> Signed-off-by: Warner Losh <imp@bsdimp.com> --- bsd-user/bsd-mman.h | 121 -------------------- bsd-user/mmap.c | 2 - bsd-user/syscall_defs.h | 247 ++++++++++++++++++++++++++-------------- 3 files changed, 162 insertions(+), 208 deletions(-) delete mode 100644 bsd-user/bsd-mman.h
Oof. Well, I guess it's progress, but it's hard to read.
+struct target_freebsd_timeval { + target_freebsd_time_t tv_sec; /* seconds */ + target_freebsd_suseconds_t tv_usec;/* and microseconds */ +#if !defined(TARGET_I386) && TARGET_ABI_BITS == 32 + abi_long _pad; +#endif +} __packed;
I question the use of packed here. You do realize that removes all alignment requirements? This is probably not what you want. It's certainly not present in the real freebsd _timeval.h.
Similarly with _timespec.h. r~
[Prev in Thread] | Current Thread | [Next in Thread] |