summaryrefslogtreecommitdiff
path: root/arch/powerpc/platforms/ps3/setup.c
diff options
context:
space:
mode:
authorNathan Chancellor <nathan@kernel.org>2021-05-28 11:27:52 -0700
committerMichael Ellerman <mpe@ellerman.id.au>2021-06-10 21:44:57 +1000
commit015d98149b326e0f1f02e44413112ca8b4330543 (patch)
treeef47efcdd42a7f93998629fc1fa453f7e8c8948e /arch/powerpc/platforms/ps3/setup.c
parent027f55e87c3094270a3223f7331d033fe15a2b3f (diff)
powerpc/barrier: Avoid collision with clang's __lwsync macro
A change in clang 13 results in the __lwsync macro being defined as __builtin_ppc_lwsync, which emits 'lwsync' or 'msync' depending on what the target supports. This breaks the build because of -Werror in arch/powerpc, along with thousands of warnings: In file included from arch/powerpc/kernel/pmc.c:12: In file included from include/linux/bug.h:5: In file included from arch/powerpc/include/asm/bug.h:109: In file included from include/asm-generic/bug.h:20: In file included from include/linux/kernel.h:12: In file included from include/linux/bitops.h:32: In file included from arch/powerpc/include/asm/bitops.h:62: arch/powerpc/include/asm/barrier.h:49:9: error: '__lwsync' macro redefined [-Werror,-Wmacro-redefined] #define __lwsync() __asm__ __volatile__ (stringify_in_c(LWSYNC) : : :"memory") ^ <built-in>:308:9: note: previous definition is here #define __lwsync __builtin_ppc_lwsync ^ 1 error generated. Undefine this macro so that the runtime patching introduced by commit 2d1b2027626d ("powerpc: Fixup lwsync at runtime") continues to work properly with clang and the build no longer breaks. Cc: stable@vger.kernel.org Signed-off-by: Nathan Chancellor <nathan@kernel.org> Reviewed-by: Nick Desaulniers <ndesaulniers@google.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> Link: https://github.com/ClangBuiltLinux/linux/issues/1386 Link: https://github.com/llvm/llvm-project/commit/62b5df7fe2b3fda1772befeda15598fbef96a614 Link: https://lore.kernel.org/r/20210528182752.1852002-1-nathan@kernel.org
Diffstat (limited to 'arch/powerpc/platforms/ps3/setup.c')
0 files changed, 0 insertions, 0 deletions