[PATCH] arm64: uapi: Use __u128 instead of __uint128_t in UAPI headers
Arnd Bergmann
arnd at arndb.de
Fri Jun 19 06:52:20 PDT 2026
On Fri, Jun 19, 2026, at 15:08, Will Deacon wrote:
> The arm64 UAPI exposes '__uint128_t' types in the members of
> 'struct user_fpsimd_state', 'struct user_pac_address_keys' and in the
> signal frame via 'struct fpsimd_context'. Since the alignment of such
> a type appears to be non-portable (16 bytes on arm64, 8 bytes on s390),
> prefer the '__u128' typedef from uapi/linux/types.h, which makes the
> alignment explicit and allows the definitions to be reused by other
> host architectures.
>
> Cc: Arnd Bergmann <arnd at arndb.de>
> Cc: Nick Desaulniers <nick.desaulniers+lkml at gmail.com>
> Cc: Steffen Eiden <seiden at linux.ibm.com>
> Cc: Andreas Grapentin <gra at linux.ibm.com>
> Cc: Catalin Marinas <catalin.marinas at arm.com>
> Cc: Dave Martin <dave.martin at arm.com>
> Cc: Mark Rutland <mark.rutland at arm.com>
> Cc: Marc Zyngier <maz at kernel.org>
> Signed-off-by: Will Deacon <will at kernel.org>
Reviewed-by: Arnd Bergmann <arnd at arndb.de>
> I think it's a straightforward change, but the only thing that makes me
> pause for thought is whether there are toolchains out there which accept
> __uint128_t but not __int128. Then again, if that crops up as an issue
> we can probably just tweak the typedef we have in uapi/linux/types.h.
clang-3.1 and gcc-4.6 support both and are 15 years old, older versions
only do __uint128_t. I agree that this should be fine.
Arnd
More information about the linux-arm-kernel
mailing list