diff options
| author | Olivier Certner <olce@FreeBSD.org> | 2026-02-13 17:20:13 +0000 |
|---|---|---|
| committer | Olivier Certner <olce@FreeBSD.org> | 2026-02-16 10:29:04 +0000 |
| commit | 4ccca2100887943b11187787004bc8efc2a149c6 (patch) | |
| tree | 04b6f66ed990d2d0d3fed09594b91f21d1fa0f58 /gnu/libexec/uucp/uuto | |
| parent | 7c2fc4419db43a8a7d1886b0b8e08aa97bfa31e4 (diff) | |
As long as 'sys/compat/freebsd32/freebsd32.h' is used unconditionally on
all platforms (in 'kern_umtx.c' at least), the rule of thumb is to
ensure that 'struct foo32' on a 32-bit arch is type-compatible with
'struct foo' on the same arch. In practice, this is very simple to
achieve: All 'foo32' types should be compatible with 'foo' on 32-bit
architectures, which is what we are supposed to do already for compat'
structures by design. The recently introduced 'freebsd32_uint64_t' type
typically supports that.
This change fixes commit 87632ddf67b0 ("openzfs sys/types32.h: use
abi_compat.h for time32_t") which was defining 'time32_t' to 'in32_t'
for all 32-bit architectures, which is wrong but on i386. By luck, this
did not change the size of whole 'struct ffclock_estimate32' (whose size
is compile-time asserted) because 'struct bintime32''s one would stay
the same, as even if its field 'sec' was incorrectly sized after that
commit, the 'frac' one is 64-bit and 64-bit aligned on all non-x86
architectures so its offset in 'struct bintime32' would stay the same.
Reviewed by: kib
Fixes: 87632ddf67b0 ("openzfs sys/types32.h: use abi_compat.h for time32_t")
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D55283
Diffstat (limited to 'gnu/libexec/uucp/uuto')
0 files changed, 0 insertions, 0 deletions
