Add cmpxchg_local to sparc64
commit80af4eeb726f038eddc32826e4238feba5b1dfb4
authorMathieu Desnoyers <mathieu.desnoyers@polymtl.ca>
Thu, 7 Feb 2008 08:16:25 +0000 (7 00:16 -0800)
committerLinus Torvalds <torvalds@woody.linux-foundation.org>
Thu, 7 Feb 2008 16:42:33 +0000 (7 08:42 -0800)
tree004867c90a5294a8902fc01f1181beacab587300
parent405321d3ab2b41960e2874f2f74609daffbc7a4c
Add cmpxchg_local to sparc64

Use cmpxchg_u32 and cmpxchg_u64 for cmpxchg_local and cmpxchg64_local. For other
type sizes, use the new generic cmpxchg_local (disables interrupt).

Change:
Since the header depends on local_irqsave/local_irqrestore, it must be
included after their declaration.

Actually, being below the
#include <linux/irqflags.h> should be enough, and on sparc64 it is
included at the beginning of system.h.

So it makes sense to move it up for sparc64.

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@polymtl.ca>
Cc: "David S. Miller" <davem@davemloft.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
include/asm-sparc64/system.h