Merge branch 'writeback-for-next' of git://git.kernel.org/pub/scm/linux/kernel/git...
[deliverable/linux.git] / arch / x86 / include / asm / cmpxchg_64.h
CommitLineData
1965aae3
PA
1#ifndef _ASM_X86_CMPXCHG_64_H
2#define _ASM_X86_CMPXCHG_64_H
a436ed9c 3
00a41546
JF
4static inline void set_64bit(volatile u64 *ptr, u64 val)
5{
6 *ptr = val;
7}
8
f3834b9e 9#define __HAVE_ARCH_CMPXCHG 1
a436ed9c 10
32f49eab 11#define cmpxchg64(ptr, o, n) \
e52da357 12({ \
32f49eab
MD
13 BUILD_BUG_ON(sizeof(*(ptr)) != 8); \
14 cmpxchg((ptr), (o), (n)); \
e52da357 15})
f3834b9e 16
32f49eab 17#define cmpxchg64_local(ptr, o, n) \
e52da357 18({ \
32f49eab
MD
19 BUILD_BUG_ON(sizeof(*(ptr)) != 8); \
20 cmpxchg_local((ptr), (o), (n)); \
e52da357 21})
a436ed9c 22
3824abd1
CL
23#define system_has_cmpxchg_double() cpu_has_cx16
24
1965aae3 25#endif /* _ASM_X86_CMPXCHG_64_H */
This page took 0.43205 seconds and 5 git commands to generate.