diff options
| author | Luc Van Oostenryck <luc.vanoostenryck@gmail.com> | 2021-04-16 09:52:58 +1000 |
|---|---|---|
| committer | Stephen Rothwell <sfr@canb.auug.org.au> | 2021-04-16 09:52:58 +1000 |
| commit | ef5a3a4c5d5d2be41ac4786a19172744bb18ecec (patch) | |
| tree | ad678aa1aea61bf3a47074e89f851f077c1c1e79 | |
| parent | aa75536647051d6b9f4a42837649ea0272f2a9ed (diff) | |
| download | linux-next-ef5a3a4c5d5d2be41ac4786a19172744bb18ecec.tar.gz | |
include/linux/compiler-gcc.h: sparse can do constant folding of __builtin_bswap*()
Notice: this object is not reachable from any branch.
Sparse can do constant folding of __builtin_bswap*() since 2017. Also, a
much recent version of Sparse is needed anyway, see commit 6ec4476ac825
("Raise gcc version requirement to 4.9").
So, remove the comment about sparse not being yet able to constant fold
__builtin_bswap*() and remove the corresponding test of __CHECKER__.
Link: https://lkml.kernel.org/r/20210226092236.99369-1-luc.vanoostenryck@gmail.com
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
Acked-by: Arnd Bergmann <arnd@arndb.de>
Acked-by: Miguel Ojeda <ojeda@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Notice: this object is not reachable from any branch.
| -rw-r--r-- | include/linux/compiler-gcc.h | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/include/linux/compiler-gcc.h b/include/linux/compiler-gcc.h index 48750243db4c8..5d97ef738a575 100644 --- a/include/linux/compiler-gcc.h +++ b/include/linux/compiler-gcc.h @@ -90,15 +90,11 @@ */ #define asm_volatile_goto(x...) do { asm goto(x); asm (""); } while (0) -/* - * sparse (__CHECKER__) pretends to be gcc, but can't do constant - * folding in __builtin_bswap*() (yet), so don't set these for it. - */ -#if defined(CONFIG_ARCH_USE_BUILTIN_BSWAP) && !defined(__CHECKER__) +#if defined(CONFIG_ARCH_USE_BUILTIN_BSWAP) #define __HAVE_BUILTIN_BSWAP32__ #define __HAVE_BUILTIN_BSWAP64__ #define __HAVE_BUILTIN_BSWAP16__ -#endif /* CONFIG_ARCH_USE_BUILTIN_BSWAP && !__CHECKER__ */ +#endif /* CONFIG_ARCH_USE_BUILTIN_BSWAP */ #if GCC_VERSION >= 70000 #define KASAN_ABI_VERSION 5 |
