]> Pileus Git - ~andy/linux/commitdiff
ARM: 7853/1: cmpxchg: implement cmpxchg64_relaxed
authorWill Deacon <will.deacon@arm.com>
Wed, 9 Oct 2013 16:17:18 +0000 (17:17 +0100)
committerRussell King <rmk+kernel@arm.linux.org.uk>
Tue, 29 Oct 2013 11:06:09 +0000 (11:06 +0000)
This patch introduces cmpxchg64_relaxed for arm, which performs a 64-bit
cmpxchg operation without barrier semantics. cmpxchg64_local is updated
to use the new operation.

Signed-off-by: Will Deacon <will.deacon@arm.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
arch/arm/include/asm/cmpxchg.h

index fbd978fc248fb43e2677fc4280de7b9360f35abf..df2fbba7efc80d57074a6053704a9c70119aae03 100644 (file)
@@ -270,11 +270,13 @@ static inline unsigned long long __cmpxchg64_mb(unsigned long long *ptr,
                                        (unsigned long long)(o),        \
                                        (unsigned long long)(n)))
 
-#define cmpxchg64_local(ptr, o, n)                                     \
+#define cmpxchg64_relaxed(ptr, o, n)                                   \
        ((__typeof__(*(ptr)))__cmpxchg64((ptr),                         \
                                        (unsigned long long)(o),        \
                                        (unsigned long long)(n)))
 
+#define cmpxchg64_local(ptr, o, n)     cmpxchg64_relaxed((ptr), (o), (n))
+
 #endif /* __LINUX_ARM_ARCH__ >= 6 */
 
 #endif /* __ASM_ARM_CMPXCHG_H */