Commit 091b76d6 authored by Greg Ungerer's avatar Greg Ungerer Committed by Linus Torvalds

m68knommu: avoid unneccessary use of xchg() in set_mb()

Avoid unneccessary use of xchg() in set_mb().
Signed-off-by: default avatarGreg Ungerer <gerg@uclinux.org>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 903be1c5
...@@ -104,7 +104,7 @@ asmlinkage void resume(void); ...@@ -104,7 +104,7 @@ asmlinkage void resume(void);
#define mb() asm volatile ("" : : :"memory") #define mb() asm volatile ("" : : :"memory")
#define rmb() asm volatile ("" : : :"memory") #define rmb() asm volatile ("" : : :"memory")
#define wmb() asm volatile ("" : : :"memory") #define wmb() asm volatile ("" : : :"memory")
#define set_mb(var, value) do { xchg(&var, value); } while (0) #define set_mb(var, value) ({ (var) = (value); wmb(); })
#ifdef CONFIG_SMP #ifdef CONFIG_SMP
#define smp_mb() mb() #define smp_mb() mb()
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment