update ppc atomic
authorMathieu Desnoyers <mathieu.desnoyers@polymtl.ca>
Tue, 22 Sep 2009 22:51:21 +0000 (18:51 -0400)
committerMathieu Desnoyers <mathieu.desnoyers@polymtl.ca>
Tue, 22 Sep 2009 22:51:21 +0000 (18:51 -0400)
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@polymtl.ca>
arch_atomic_ppc.h

index 231a57798598e3da844d6938a95d9502b402da86..16ddc012302dd397038c71da6b2f96cc817e21ff 100644 (file)
 
 #ifndef _INCLUDE_API_H
 
+#define atomic_set(addr, v)                            \
+do {                                                   \
+       ACCESS_ONCE(*(addr)) = (v);                     \
+} while (0)
+
+#define atomic_read(addr)      ACCESS_ONCE(*(addr))
+
 /*
  * Using a isync as second barrier for exchange to provide acquire semantic.
  * According to atomic_ops/sysdeps/gcc/powerpc.h, the documentation is "fairly
This page took 0.025768 seconds and 4 git commands to generate.