ARM: 7852/1: cmpxchg: implement barrier-less cmpxchg64_local
authorWill Deacon <will.deacon@arm.com>
Wed, 9 Oct 2013 16:01:21 +0000 (17:01 +0100)
committerRussell King <rmk+kernel@arm.linux.org.uk>
Tue, 29 Oct 2013 11:06:06 +0000 (11:06 +0000)
commit2523c67bb6962f98193dce1c73b6efb65a6ea92c
tree0c23d146be95ffcb82405c6b6770ae52421ba19e
parent494e492dd88d36cd201eae99873492450d1e9b4f
ARM: 7852/1: cmpxchg: implement barrier-less cmpxchg64_local

Our cmpxchg64 macros are wrappers around atomic64_cmpxchg. Whilst this is
great for code re-use, there is a case for barrier-less cmpxchg where it
is known to be safe (for example cmpxchg64_local and cmpxchg-based
lockrefs).

This patch introduces a 64-bit cmpxchg implementation specifically
for the cmpxchg64_* macros, so that it can be later used by the lockref
code.

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