diff options
author | 2021-02-22 21:35:15 -0800 | |
---|---|---|
committer | 2021-02-22 21:35:15 -0800 | |
commit | cbecf716ca618fd44feda6bd9a64a8179d031fc5 (patch) | |
tree | 186c9f69f0d11f773253c440dac85087f67288b7 /include/linux/compiler_types.h | |
parent | Input: st1232 - add IDLE state as ready condition (diff) | |
parent | Input: aiptek - convert sysfs sprintf/snprintf family to sysfs_emit (diff) | |
download | linux-rng-cbecf716ca618fd44feda6bd9a64a8179d031fc5.tar.xz linux-rng-cbecf716ca618fd44feda6bd9a64a8179d031fc5.zip |
Merge branch 'next' into for-linus
Prepare input updates for 5.12 merge window.
Diffstat (limited to 'include/linux/compiler_types.h')
-rw-r--r-- | include/linux/compiler_types.h | 21 |
1 files changed, 11 insertions, 10 deletions
diff --git a/include/linux/compiler_types.h b/include/linux/compiler_types.h index 6e390d58a9f8..e5dd5a4ae946 100644 --- a/include/linux/compiler_types.h +++ b/include/linux/compiler_types.h @@ -64,6 +64,17 @@ static inline void __chk_io_ptr(const volatile void __iomem *ptr) { } /* Attributes */ #include <linux/compiler_attributes.h> +/* Builtins */ + +/* + * __has_builtin is supported on gcc >= 10, clang >= 3 and icc >= 21. + * In the meantime, to support gcc < 10, we implement __has_builtin + * by hand. + */ +#ifndef __has_builtin +#define __has_builtin(x) (0) +#endif + /* Compiler specific macros. */ #ifdef __clang__ #include <linux/compiler-clang.h> @@ -110,12 +121,6 @@ struct ftrace_likely_data { unsigned long constant; }; -#ifdef CONFIG_ENABLE_MUST_CHECK -#define __must_check __attribute__((__warn_unused_result__)) -#else -#define __must_check -#endif - #if defined(CC_USING_HOTPATCH) #define notrace __attribute__((hotpatch(0, 0))) #elif defined(CC_USING_PATCHABLE_FUNCTION_ENTRY) @@ -247,10 +252,6 @@ struct ftrace_likely_data { #define asm_inline asm #endif -#ifndef __no_fgcse -# define __no_fgcse -#endif - /* Are two types/vars the same type (ignoring qualifiers)? */ #define __same_type(a, b) __builtin_types_compatible_p(typeof(a), typeof(b)) |