aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm64
diff options
context:
space:
mode:
authorWill Deacon <will.deacon@arm.com>2014-05-02 11:24:12 -0400
committerCatalin Marinas <catalin.marinas@arm.com>2014-05-09 12:03:52 -0400
commitbe6209a6107e0f63544e3e7d00fd5c95434ec80a (patch)
treedfddaa0fc846a8b2c1a833b4bf5252161fcb5b6e /arch/arm64
parent493e68747e07b69da3d746352525a1ebd6b61d82 (diff)
arm64: barriers: use barrier() instead of smp_mb() when !SMP
The recently introduced acquire/release accessors refer to smp_mb() in the !CONFIG_SMP case. This is confusing when reading the code, so use barrier() directly when we know we're UP. Acked-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
Diffstat (limited to 'arch/arm64')
-rw-r--r--arch/arm64/include/asm/barrier.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/arm64/include/asm/barrier.h b/arch/arm64/include/asm/barrier.h
index 71a42d6599fb..709f1f6d6bbd 100644
--- a/arch/arm64/include/asm/barrier.h
+++ b/arch/arm64/include/asm/barrier.h
@@ -40,7 +40,7 @@
40#define smp_store_release(p, v) \ 40#define smp_store_release(p, v) \
41do { \ 41do { \
42 compiletime_assert_atomic_type(*p); \ 42 compiletime_assert_atomic_type(*p); \
43 smp_mb(); \ 43 barrier(); \
44 ACCESS_ONCE(*p) = (v); \ 44 ACCESS_ONCE(*p) = (v); \
45} while (0) 45} while (0)
46 46
@@ -48,7 +48,7 @@ do { \
48({ \ 48({ \
49 typeof(*p) ___p1 = ACCESS_ONCE(*p); \ 49 typeof(*p) ___p1 = ACCESS_ONCE(*p); \
50 compiletime_assert_atomic_type(*p); \ 50 compiletime_assert_atomic_type(*p); \
51 smp_mb(); \ 51 barrier(); \
52 ___p1; \ 52 ___p1; \
53}) 53})
54 54