int128: move __uint128_t compiler test to Kconfig
In order to use 128-bit integer arithmetic in C code, the architecture needs to have declared support for it by setting ARCH_SUPPORTS_INT128, and it requires a version of the toolchain that supports this at build time. This is why all existing tests for ARCH_SUPPORTS_INT128 also test whether __SIZEOF_INT128__ is defined, since this is only the case for compilers that can support 128-bit integers. Let's fold this additional test into the Kconfig declaration of ARCH_SUPPORTS_INT128 so that we can also use the symbol in Makefiles, e.g., to decide whether a certain object needs to be included in the first place. Cc: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by:Ard Biesheuvel <ardb@kernel.org> Signed-off-by:
Herbert Xu <herbert@gondor.apana.org.au>
Showing
- arch/arm64/Kconfig 1 addition, 1 deletionarch/arm64/Kconfig
- arch/riscv/Kconfig 1 addition, 1 deletionarch/riscv/Kconfig
- arch/x86/Kconfig 1 addition, 1 deletionarch/x86/Kconfig
- crypto/ecc.c 1 addition, 1 deletioncrypto/ecc.c
- init/Kconfig 4 additions, 0 deletionsinit/Kconfig
- lib/ubsan.c 1 addition, 1 deletionlib/ubsan.c
- lib/ubsan.h 1 addition, 1 deletionlib/ubsan.h
Loading
Please register or sign in to comment