From: KOSAKI Motohiro Date: Wed, 25 May 2011 00:13:17 +0000 (-0700) Subject: sparse: Undef __compiletime_{warning,error} if __CHECKER__ is defined X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=746a2a838deec3ef86ef6b7c3edd4207b9a351aa;p=GitHub%2FLineageOS%2Fandroid_kernel_samsung_universal7580.git sparse: Undef __compiletime_{warning,error} if __CHECKER__ is defined sparse can't parse warning and error attribute. then they should be hidden from sparse. Signed-off-by: KOSAKI Motohiro Cc: Arjan van de Ven Cc: Dave Hansen Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/include/linux/compiler-gcc4.h b/include/linux/compiler-gcc4.h index 64b7c003fd7..dfadc96e9d6 100644 --- a/include/linux/compiler-gcc4.h +++ b/include/linux/compiler-gcc4.h @@ -51,7 +51,7 @@ #if __GNUC_MINOR__ > 0 #define __compiletime_object_size(obj) __builtin_object_size(obj, 0) #endif -#if __GNUC_MINOR__ >= 4 +#if __GNUC_MINOR__ >= 4 && !defined(__CHECKER__) #define __compiletime_warning(message) __attribute__((warning(message))) #define __compiletime_error(message) __attribute__((error(message))) #endif