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-Tag: v3.0-rc1~192 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=746a2a838deec3ef86ef6b7c3edd4207b9a351aa;p=platform%2Fupstream%2Fkernel-adaptation-pc.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 64b7c00..dfadc96 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