Commit 2d5db193 authored by Masahiro Yamada's avatar Masahiro Yamada Committed by Tom Rini

standalone: use GCC_VERSION defined in compiler-gcc.h

Now GCC_VERSION is defined in include/linux/compiler-gcc.h
(with a little different definition).
Use it and delete the one in examples/standlone/stub.c.

This should work on Clang too because __GNUC__, __GNUC_MINOR__,
__GNUC_PATCHLEVEL__ are also defined on Clang.
Signed-off-by: default avatarMasahiro Yamada <>
Cc: Jeroen Hofstee <>
parent fb8ffd7c
#include <common.h>
#include <exports.h>
#define GCC_VERSION (__GNUC__ * 1000 + __GNUC_MINOR__)
#endif /* GCC_VERSION */
#include <linux/compiler.h>
#if defined(CONFIG_X86)
......@@ -237,7 +234,7 @@ gd_t *global_data;
* implementation. On the other hand, asm() statements with
* arguments can be used only inside the functions (gcc limitation)
#if GCC_VERSION < 3004
#if GCC_VERSION < 30400
#endif /* GCC_VERSION */
void __attribute__((unused)) dummy(void)
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