powerpc: Implement {cmp}xchg for u8 and u16
authorPan Xinhui <xinhui.pan@linux.vnet.ibm.com>
Wed, 27 Apr 2016 09:16:45 +0000 (17:16 +0800)
committerMichael Ellerman <mpe@ellerman.id.au>
Wed, 23 Nov 2016 11:56:26 +0000 (22:56 +1100)
commitd0563a1297e234ed37f6b51c2e9321accebd1839
tree987960d540a720f242d3f9a38fe5fdef443bbf33
parent8004ca995c24a078ae362f6dd9f8e1056e65c733
powerpc: Implement {cmp}xchg for u8 and u16

Implement xchg{u8,u16}{local,relaxed}, and
cmpxchg{u8,u16}{,local,acquire,relaxed}.

It works on all ppc.

remove volatile of first parameter in __cmpxchg_local and __cmpxchg

Suggested-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Signed-off-by: Pan Xinhui <xinhui.pan@linux.vnet.ibm.com>
Acked-by: Boqun Feng <boqun.feng@gmail.com>
Acked-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
arch/powerpc/include/asm/cmpxchg.h