summaryrefslogtreecommitdiff
path: root/cpu/microblaze/cache.c
diff options
context:
space:
mode:
authorMarkus Klotzbuecher <mk@denx.de>2007-05-29 16:37:57 +0200
committerMarkus Klotzbuecher <mk@pollux.denx.de>2007-05-29 16:37:57 +0200
commit51d8e813222fa3063d423220f6ff1146df58a471 (patch)
treea4951077af841bd87a90854b7fb390d12e37b851 /cpu/microblaze/cache.c
parent3a619dd7bed03e8b4d22a3911f90fd12af5376c2 (diff)
parent19bf91f9628f80a55d4f171df71041574882b3d6 (diff)
downloadu-boot-imx-51d8e813222fa3063d423220f6ff1146df58a471.zip
u-boot-imx-51d8e813222fa3063d423220f6ff1146df58a471.tar.gz
u-boot-imx-51d8e813222fa3063d423220f6ff1146df58a471.tar.bz2
Merge git://www.denx.de/git/u-boot into 2007_05_15-testing
Diffstat (limited to 'cpu/microblaze/cache.c')
-rwxr-xr-x[-rw-r--r--]cpu/microblaze/cache.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/cpu/microblaze/cache.c b/cpu/microblaze/cache.c
index fc388eb..4f36a84 100644..100755
--- a/cpu/microblaze/cache.c
+++ b/cpu/microblaze/cache.c
@@ -23,6 +23,7 @@
*/
#include <common.h>
+#include <asm/asm.h>
#if (CONFIG_COMMANDS & CFG_CMD_CACHE)
@@ -45,4 +46,20 @@ int icache_status (void)
__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