Commit ae3a0064 authored by Ingo Molnar's avatar Ingo Molnar Committed by Linus Torvalds

inlining: do not allow gcc below version 4 to optimize inlining

fix the condition to match intention: always use the old inlining
behavior on all gcc versions below 4.

this should solve the UML build problem.
Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 53809d7e
...@@ -29,10 +29,11 @@ ...@@ -29,10 +29,11 @@
BUILD_BUG_ON_ZERO(__builtin_types_compatible_p(typeof(a), typeof(&a[0]))) BUILD_BUG_ON_ZERO(__builtin_types_compatible_p(typeof(a), typeof(&a[0])))
/* /*
* Force always-inline if the user requests it so via the .config: * Force always-inline if the user requests it so via the .config,
* or if gcc is too old:
*/ */
#if !defined(CONFIG_ARCH_SUPPORTS_OPTIMIZED_INLINING) || \ #if !defined(CONFIG_ARCH_SUPPORTS_OPTIMIZED_INLINING) || \
!defined(CONFIG_OPTIMIZE_INLINING) && (__GNUC__ >= 4) !defined(CONFIG_OPTIMIZE_INLINING) || (__GNUC__ < 4)
# define inline inline __attribute__((always_inline)) # define inline inline __attribute__((always_inline))
# define __inline__ __inline__ __attribute__((always_inline)) # define __inline__ __inline__ __attribute__((always_inline))
# define __inline __inline __attribute__((always_inline)) # define __inline __inline __attribute__((always_inline))
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment