• Paul Mundt's avatar
    sh: Fixup __cmpxchg() compile breakage with gcc4. · 310f7963
    Paul Mundt authored
    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: default avatarPaul Mundt <lethal@linux-sh.org>
    310f7963
system.h 7.04 KB