Go to the documentation of this file.
5 #ifndef __ASM_SH_BARRIER_H
6 #define __ASM_SH_BARRIER_H
8 #if defined(CONFIG_CPU_SH4A) || defined(CONFIG_CPU_SH5)
26 #if defined(CONFIG_CPU_SH4A) || defined(CONFIG_CPU_SH5)
27 #define mb() __asm__ __volatile__ ("synco": : :"memory")
29 #define wmb() __asm__ __volatile__ ("synco": : :"memory")
30 #define ctrl_barrier() __icbi(PAGE_OFFSET)
31 #define read_barrier_depends() do { } while(0)
33 #define mb() __asm__ __volatile__ ("": : :"memory")
35 #define wmb() __asm__ __volatile__ ("": : :"memory")
36 #define ctrl_barrier() __asm__ __volatile__ ("nop;nop;nop;nop;nop;nop;nop;nop")
37 #define read_barrier_depends() do { } while(0)
42 #define smp_rmb() rmb()
43 #define smp_wmb() wmb()
44 #define smp_read_barrier_depends() read_barrier_depends()
46 #define smp_mb() barrier()
47 #define smp_rmb() barrier()
48 #define smp_wmb() barrier()
49 #define smp_read_barrier_depends() do { } while(0)
52 #define set_mb(var, value) do { (void)xchg(&var, value); } while (0)