[patch V2 1/6] ARM: uaccess: Implement missing __get_user_asm_dword()
Nathan Chancellor
nathan at kernel.org
Wed Sep 17 10:14:24 PDT 2025
On Wed, Sep 17, 2025 at 04:17:38PM +0100, Russell King (Oracle) wrote:
> For me, this produces:
>
> get-user-test.c:41:16: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
> 41 | (x) = *(__force __typeof__(*(ptr)) *) &__gu_val; \
> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>
> with arm-linux-gnueabihf-gcc (Debian 14.2.0-19) 14.2.0
>
> Maybe you're using a different compiler that doesn't issue that warning?
Maybe because the kernel uses -fno-strict-aliasing, which presumably
turns off -Wstrict-aliasing?
Cheers,
Nathan
More information about the linux-arm-kernel
mailing list