projects
/
oweals
/
u-boot.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge git://www.denx.de/git/u-boot
[oweals/u-boot.git]
/
cpu
/
microblaze
/
cache.c
diff --git
a/cpu/microblaze/cache.c
b/cpu/microblaze/cache.c
index fc388ebb5629d97480998be75916cee1acad1927..4b7866fae50721a705f2eb8ca7a62ca0e369844d 100644
(file)
--- a/
cpu/microblaze/cache.c
+++ b/
cpu/microblaze/cache.c
@@
-1,7
+1,7
@@
/*
* (C) Copyright 2007 Michal Simek
*
/*
* (C) Copyright 2007 Michal Simek
*
- * Michal SIMEK <mo
o
nstr@monstr.eu>
+ * Michal SIMEK <monstr@monstr.eu>
*
* See file CREDITS for list of people who contributed to this
* project.
*
* See file CREDITS for list of people who contributed to this
* project.
@@
-23,8
+23,9
@@
*/
#include <common.h>
*/
#include <common.h>
+#include <asm/asm.h>
-#if
(CONFIG_COMMANDS & CF
G_CMD_CACHE)
+#if
defined(CONFI
G_CMD_CACHE)
int dcache_status (void)
{
int dcache_status (void)
{
@@
-45,4
+46,20
@@
int icache_status (void)
__asm__ __volatile__ ("and %0,%0,%1"::"r" (i), "r" (mask):"memory");
return i;
}
__asm__ __volatile__ ("and %0,%0,%1"::"r" (i), "r" (mask):"memory");
return i;
}
+
+void icache_enable (void) {
+ MSRSET(0x20);
+}
+
+void icache_disable(void) {
+ MSRCLR(0x20);
+}
+
+void dcache_enable (void) {
+ MSRSET(0x80);
+}
+
+void dcache_disable(void) {
+ MSRCLR(0x80);
+}
#endif
#endif