blob: c1b76654ee76a8cf79ef87d25bd7a44d45479d46 [file] [log] [blame]
David Howellsd550bbd2012-03-28 18:30:03 +01001#ifndef __SPARC_BARRIER_H
2#define __SPARC_BARRIER_H
3
4/* XXX Change this if we ever use a PSO mode kernel. */
5#define mb() __asm__ __volatile__ ("" : : : "memory")
6#define rmb() mb()
7#define wmb() mb()
8#define read_barrier_depends() do { } while(0)
9#define set_mb(__var, __value) do { __var = __value; mb(); } while(0)
10#define smp_mb() __asm__ __volatile__("":::"memory")
11#define smp_rmb() __asm__ __volatile__("":::"memory")
12#define smp_wmb() __asm__ __volatile__("":::"memory")
13#define smp_read_barrier_depends() do { } while(0)
14
15#endif /* !(__SPARC_BARRIER_H) */