aboutsummaryrefslogtreecommitdiffstats
path: root/include/asm-powerpc/atomic.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/asm-powerpc/atomic.h')
-rw-r--r--include/asm-powerpc/atomic.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/asm-powerpc/atomic.h b/include/asm-powerpc/atomic.h
index ec4b14468959..248f9aec959c 100644
--- a/include/asm-powerpc/atomic.h
+++ b/include/asm-powerpc/atomic.h
@@ -165,6 +165,7 @@ static __inline__ int atomic_dec_return(atomic_t *v)
165} 165}
166 166
167#define atomic_cmpxchg(v, o, n) ((int)cmpxchg(&((v)->counter), (o), (n))) 167#define atomic_cmpxchg(v, o, n) ((int)cmpxchg(&((v)->counter), (o), (n)))
168#define atomic_xchg(v, new) (xchg(&((v)->counter), new))
168 169
169/** 170/**
170 * atomic_add_unless - add unless the number is a given value 171 * atomic_add_unless - add unless the number is a given value
@@ -402,5 +403,6 @@ static __inline__ long atomic64_dec_if_positive(atomic64_t *v)
402 403
403#endif /* __powerpc64__ */ 404#endif /* __powerpc64__ */
404 405
406#include <asm-generic/atomic.h>
405#endif /* __KERNEL__ */ 407#endif /* __KERNEL__ */
406#endif /* _ASM_POWERPC_ATOMIC_H_ */ 408#endif /* _ASM_POWERPC_ATOMIC_H_ */