diff options
author | Matthias Kaehlcke <matthias@kaehlcke.net> | 2009-12-22 23:05:45 +0100 |
---|---|---|
committer | Wolfgang Denk <wd@denx.de> | 2010-01-18 00:28:27 +0100 |
commit | b63815e31355b44e65899b361da1d8ef6940ab90 (patch) | |
tree | e80a0d6b4321b1efa5be27ddf2be852a39707db5 /include/compiler.h | |
parent | c3d7eec6d88945dec0626cdd4f4a35cb5f83ef00 (diff) |
move definition of macros likely and unlikely to compiler.h
the macros likely and unlikely were defined in include/linux/mtd/compat.h,
but used in code not related to MTD. moved the macro definitions to compiler.h
Signed-off-by: Matthias Kaehlcke <matthias@kaehlcke.net>
Diffstat (limited to 'include/compiler.h')
-rw-r--r-- | include/compiler.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/include/compiler.h b/include/compiler.h index e602cce2e9b..332618e9de9 100644 --- a/include/compiler.h +++ b/include/compiler.h @@ -125,4 +125,7 @@ typedef unsigned int uintptr_t; /* compiler options */ #define uninitialized_var(x) x = x +#define likely(x) __builtin_expect(!!(x), 1) +#define unlikely(x) __builtin_expect(!!(x), 0) + #endif |