projects
/
oweals
/
u-boot.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
8abebe3
)
x86: Add initial memory barrier macros
author
Simon Glass
<sjg@chromium.org>
Wed, 10 Oct 2012 13:12:53 +0000
(13:12 +0000)
committer
Simon Glass
<sjg@chromium.org>
Wed, 28 Nov 2012 19:40:03 +0000
(11:40 -0800)
These are available on other architectures, so add them on x86.
Signed-off-by: Simon Glass <sjg@chromium.org>
arch/x86/include/asm/io.h
patch
|
blob
|
history
diff --git
a/arch/x86/include/asm/io.h
b/arch/x86/include/asm/io.h
index 9b757d489e38091700085f93a76293065f66af97..b12bdd8e2b638edb30af3db7d9c9f44e15fac5e9 100644
(file)
--- a/
arch/x86/include/asm/io.h
+++ b/
arch/x86/include/asm/io.h
@@
-234,4
+234,12
@@
static inline phys_addr_t virt_to_phys(void * vaddr)
return (phys_addr_t)(vaddr);
}
+/*
+ * TODO: The kernel offers some more advanced versions of barriers, it might
+ * have some advantages to use them instead of the simple one here.
+ */
+#define dmb() __asm__ __volatile__ ("" : : : "memory")
+#define __iormb() dmb()
+#define __iowmb() dmb()
+
#endif