diff options
| author | Arnd Bergmann <arnd@arndb.de> | 2021-03-11 16:18:29 +0100 |
|---|---|---|
| committer | Arnd Bergmann <arnd@arndb.de> | 2021-03-18 15:06:39 +0100 |
| commit | 4add9311d7e505da69b887a4e24388b41f2528cf (patch) | |
| tree | ed655c20b487c6244d3f5f79e20010f349e88eb0 | |
| parent | 3d246b8de29e0f1b6a3b995601e9adffdbc3120c (diff) | |
| download | playground-4add9311d7e505da69b887a4e24388b41f2528cf.tar.gz | |
fixup compiler-clang.h
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
| -rw-r--r-- | include/linux/compiler-clang.h | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/include/linux/compiler-clang.h b/include/linux/compiler-clang.h index 74ec6014e7c79..2a03bcd0096bb 100644 --- a/include/linux/compiler-clang.h +++ b/include/linux/compiler-clang.h @@ -78,27 +78,33 @@ #define __diag_str1(s) #s #define __diag_str(s) __diag_str1(s) -#define __diag(s) _Pragma(__diag_str(GCC diagnostic s)) +#define __diag(s) _Pragma(__diag_str(clang diagnostic s)) -#if CLANG_VERSION >= 100000 +#if CONFIG_CLANG_VERSION >= 90000 +#define __diag_CLANG_9(s) __diag(s) +#else +#define __diag_CLANG_9(s) +#endif + +#if CONFIG_CLANG_VERSION >= 100000 #define __diag_CLANG_10(s) __diag(s) #else #define __diag_CLANG_10(s) #endif -#if CLANG_VERSION >= 110000 +#if CONFIG_CLANG_VERSION >= 110000 #define __diag_CLANG_11(s) __diag(s) #else #define __diag_CLANG_11(s) #endif -#if CLANG_VERSION >= 120000 +#if CONFIG_CLANG_VERSION >= 120000 #define __diag_CLANG_12(s) __diag(s) #else #define __diag_CLANG_12(s) #endif -#if CLANG_VERSION >= 130000 +#if CONFIG_CLANG_VERSION >= 130000 #define __diag_CLANG_13(s) __diag(s) #else #define __diag_CLANG_13(s) |
