diff options
Diffstat (limited to 'arch/avr32/include/asm/barrier.h')
-rw-r--r-- | arch/avr32/include/asm/barrier.h | 17 |
1 files changed, 5 insertions, 12 deletions
diff --git a/arch/avr32/include/asm/barrier.h b/arch/avr32/include/asm/barrier.h index 0961275373db..715100790fd0 100644 --- a/arch/avr32/include/asm/barrier.h +++ b/arch/avr32/include/asm/barrier.h | |||
@@ -8,22 +8,15 @@ | |||
8 | #ifndef __ASM_AVR32_BARRIER_H | 8 | #ifndef __ASM_AVR32_BARRIER_H |
9 | #define __ASM_AVR32_BARRIER_H | 9 | #define __ASM_AVR32_BARRIER_H |
10 | 10 | ||
11 | #define nop() asm volatile("nop") | 11 | /* |
12 | 12 | * Weirdest thing ever.. no full barrier, but it has a write barrier! | |
13 | #define mb() asm volatile("" : : : "memory") | 13 | */ |
14 | #define rmb() mb() | 14 | #define wmb() asm volatile("sync 0" : : : "memory") |
15 | #define wmb() asm volatile("sync 0" : : : "memory") | ||
16 | #define read_barrier_depends() do { } while(0) | ||
17 | #define set_mb(var, value) do { var = value; mb(); } while(0) | ||
18 | 15 | ||
19 | #ifdef CONFIG_SMP | 16 | #ifdef CONFIG_SMP |
20 | # error "The AVR32 port does not support SMP" | 17 | # error "The AVR32 port does not support SMP" |
21 | #else | ||
22 | # define smp_mb() barrier() | ||
23 | # define smp_rmb() barrier() | ||
24 | # define smp_wmb() barrier() | ||
25 | # define smp_read_barrier_depends() do { } while(0) | ||
26 | #endif | 18 | #endif |
27 | 19 | ||
20 | #include <asm-generic/barrier.h> | ||
28 | 21 | ||
29 | #endif /* __ASM_AVR32_BARRIER_H */ | 22 | #endif /* __ASM_AVR32_BARRIER_H */ |