tools: Make "__always_inline" just "inline" on Android
tip-bot for Arnaldo Carvalho de Melo
merge botCommit-ID: 8c98abff43616a2a9c208189f86d32cefafbe708 Gitweb: http://git.kernel.org/tip/8c98abff43616a2a9c208189f86d32cefafbe708 Author: Arnaldo Carvalho de Melo <[email protected]> AuthorDate: Thu, 14 Jul 2016 12:03:04 -0300 Committer: Arnaldo Carvalho de Melo <[email protected]> CommitDate: Thu, 14 Jul 2016 12:03:04 -0300
tools: Make "__always_inline" just "inline" on Android
As the gcc there is producing tons of:
"warning: always_inline function might not be inlinable"
At least on android-ndk-r12/platforms/android-24/arch-arm, so, for the time being, use this big hammer.
Cc Adrian Hunter <[email protected]>
Cc Chris Phlipot <[email protected]>
Cc David Ahern <[email protected]>
Cc Jiri Olsa <[email protected]>
Cc Namhyung Kim <[email protected]>
Cc Wang Nan <[email protected]>
Signed-off-by Arnaldo Carvalho de Melo <[email protected]>
--- tools/include/linux/compiler.h | 11 +++++++++++ 1 file changed, 11 insertions(+)
tools/include/linux/compiler.h +11 -0
@@ -9,6 +9,17 @@# define __always_inline inline __attribute__((always_inline))#endif +#ifdef __ANDROID__ +/* +* FIXME: Big hammer to get rid of tons of: +* "warning: always_inline function might not be inlinable" +* +* At least on android-ndk-r12/platforms/android-24/arch-arm +*/ +#undef __always_inline +#define __always_inline inline +#endif +#define __user#ifndef __attribute_const__