blob: 30339b62028957ca36736d8c0b780e4639de78d4 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
|
#ifndef _HACK_ASM_SYSTEM_H
#define _HACK_ASM_SYSTEM_H
/* We don't need atomicity in the Linux code because we serialize all
entries to it. */
#include <stdint.h>
#define xchg(ptr, x) \
({ \
__typeof__ (*(ptr)) *_ptr = (ptr), _x = *_ptr; \
*_ptr = (x); _x; \
})
#define mb() ((void) 0) /* memory barrier */
#define rmb() mb()
#define wmb() mb()
#endif
|