summaryrefslogtreecommitdiffstats
path: root/arch/x86/include/asm/atomic64_64.h
diff options
context:
space:
mode:
authorAnton Blanchard <anton@samba.org>2010-05-17 14:33:53 +1000
committerLinus Torvalds <torvalds@linux-foundation.org>2010-05-17 07:57:27 -0700
commitf3d46f9d3194e0329216002a8724d4c0957abc79 (patch)
tree6d9413e4a448d7b8d342c40297c4fbe0b9c4c2f0 /arch/x86/include/asm/atomic64_64.h
parente40152ee1e1c7a63f4777791863215e3faa37a86 (diff)
atomic_t: Cast to volatile when accessing atomic variables
In preparation for removing volatile from the atomic_t definition, this patch adds a volatile cast to all the atomic read functions. Signed-off-by: Anton Blanchard <anton@samba.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'arch/x86/include/asm/atomic64_64.h')
-rw-r--r--arch/x86/include/asm/atomic64_64.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/x86/include/asm/atomic64_64.h b/arch/x86/include/asm/atomic64_64.h
index 51c5b405692..b014e235ea8 100644
--- a/arch/x86/include/asm/atomic64_64.h
+++ b/arch/x86/include/asm/atomic64_64.h
@@ -18,7 +18,7 @@
*/
static inline long atomic64_read(const atomic64_t *v)
{
- return v->counter;
+ return (*(volatile long *)&(v)->counter);
}
/**