From: Paul Mundt Date: Wed, 28 Mar 2007 08:26:19 +0000 (+0900) Subject: sh: Fixup __cmpxchg() compile breakage with gcc4. X-Git-Tag: v2.6.21-rc6~78^2~1 X-Git-Url: http://pilppa.com/gitweb/?a=commitdiff_plain;h=310f7963c24ab8fa56a539fa060dd84560ce26e9;p=linux-2.6-omap-h63xx.git sh: Fixup __cmpxchg() compile breakage with gcc4. As reported by Manuel: When I build linux with GCC-4.x and enable CONFIG_CC_OPTIMIZE_FOR_SIZE linking fails with this error: LD .tmp_vmlinux1 kernel/built-in.o: In function '__cmpxchg_called_with_bad_pointer' make[1]: *** [.tmp_vmlinux1] Error 1 make: *** [_all] Error 2 This ended up being an inlining problem, fixed by explicitly including linux/compiler.h and grabbing the definitions from there. Signed-off-by: Paul Mundt --- diff --git a/include/asm-sh/system.h b/include/asm-sh/system.h index b1e42e7f998..4a6a19f4f8a 100644 --- a/include/asm-sh/system.h +++ b/include/asm-sh/system.h @@ -7,6 +7,7 @@ */ #include +#include #include /*