summaryrefslogtreecommitdiff
path: root/arch/arm64/include/asm/vdso/compat_barrier.h
diff options
context:
space:
mode:
authorVincenzo Frascino <vincenzo.frascino@arm.com>2019-10-03 18:48:34 +0100
committerWill Deacon <will@kernel.org>2019-10-07 11:07:16 +0100
commit0df2c90eba60791148cee1823c0bf5fc66e3465c (patch)
tree36653009e0f5f743ba09a52bd6f6ac8cc5acfd47 /arch/arm64/include/asm/vdso/compat_barrier.h
parent37a5076098c17f40913c772b017ff8e48e449656 (diff)
arm64: vdso32: Detect binutils support for dmb ishld
Older versions of binutils (prior to 2.24) do not support the "ISHLD" option for memory barrier instructions, which leads to a build failure when assembling the vdso32 library. Add a compilation time mechanism that detects if binutils supports those instructions and configure the kernel accordingly. Cc: Will Deacon <will@kernel.org> Cc: Catalin Marinas <catalin.marinas@arm.com> Reported-by: Will Deacon <will@kernel.org> Signed-off-by: Vincenzo Frascino <vincenzo.frascino@arm.com> Reviewed-by: Catalin Marinas <catalin.marinas@arm.com> Tested-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Will Deacon <will@kernel.org>
Diffstat (limited to 'arch/arm64/include/asm/vdso/compat_barrier.h')
-rw-r--r--arch/arm64/include/asm/vdso/compat_barrier.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/arm64/include/asm/vdso/compat_barrier.h b/arch/arm64/include/asm/vdso/compat_barrier.h
index fb60a88b5ed4..3fd8fd6d8fc2 100644
--- a/arch/arm64/include/asm/vdso/compat_barrier.h
+++ b/arch/arm64/include/asm/vdso/compat_barrier.h
@@ -20,7 +20,7 @@
#define dmb(option) __asm__ __volatile__ ("dmb " #option : : : "memory")
-#if __LINUX_ARM_ARCH__ >= 8
+#if __LINUX_ARM_ARCH__ >= 8 && defined(CONFIG_AS_DMB_ISHLD)
#define aarch32_smp_mb() dmb(ish)
#define aarch32_smp_rmb() dmb(ishld)
#define aarch32_smp_wmb() dmb(ishst)