diff -Naur u-boot-2006-05-10-1800/cpu/microblaze/cache.c u-boot-2006-05-10-1800-microblaze/cpu/microblaze/cache.c
--- u-boot-2006-05-10-1800/cpu/microblaze/cache.c	1970-01-01 01:00:00.000000000 +0100
+++ u-boot-2006-05-10-1800-microblaze/cpu/microblaze/cache.c	2006-06-15 21:04:28.000000000 +0200
@@ -0,0 +1,45 @@
+/*
+ * (C) Copyright 2006 Michal Simek
+ *
+ * Michal SIMEK <www.monstr.eu>
+ *
+ * See file CREDITS for list of people who contributed to this
+ * project.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of
+ * the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.	 See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ */
+
+#include <common.h>
+
+#if (CONFIG_COMMANDS & CFG_CMD_CACHE)
+
+int dcache_status(void){
+	int i=0;
+        int mask=0x80;
+	__asm__ __volatile__ ("mfs %0,rmsr"::"r"(i):"memory");
+	__asm__ __volatile__ ("and %0,%0,%1"::"r"(i),"r"(mask):"memory"); /* i&=0x80 */
+	return i;
+}
+
+int icache_status(void){
+	int i=0;
+	int mask=0x20;
+	__asm__ __volatile__ ("mfs %0,rmsr"::"r"(i):"memory");
+	__asm__ __volatile__ ("and %0,%0,%1"::"r"(i),"r"(mask):"memory"); /* i&=0x20 */
+	return i;
+}
+#endif
+
diff -Naur u-boot-2006-05-10-1800/cpu/microblaze/dcache.S u-boot-2006-05-10-1800-microblaze/cpu/microblaze/dcache.S
--- u-boot-2006-05-10-1800/cpu/microblaze/dcache.S	1970-01-01 01:00:00.000000000 +0100
+++ u-boot-2006-05-10-1800-microblaze/cpu/microblaze/dcache.S	2006-06-15 21:04:44.000000000 +0200
@@ -0,0 +1,53 @@
+/*
+ * (C) Copyright 2006 Michal Simek
+ *
+ * Michal  SIMEK <www.monstr.eu>
+ *
+ * See file CREDITS for list of people who contributed to this
+ * project.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of
+ * the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.	 See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ */
+	.text
+	.globl	dcache_enable
+	.ent	dcache_enable
+	.align	2
+dcache_enable:
+	addi	r1, r1, -4
+	swi	r12, r1, 0
+	mfs	r12, rmsr
+	ori	r12, r12, 0x80
+	mts	rmsr, r12
+	lwi	r12, r1, 0
+	rtsd	r15, 8
+	addi	r1, r1, 4
+	.end	dcache_enable
+
+	.text
+	.globl	dcache_disable
+	.ent	dcache_disable
+	.align	2
+dcache_disable:
+	addi	r1, r1, -4
+	swi	r12, r1, 0
+	mfs	r12, rmsr
+	andi	r12, r12, ~0x80
+	mts	rmsr, r12
+	lwi	r12, r1, 0
+	rtsd	r15, 8
+	addi	r1, r1, 4
+	.end	dcache_disable
+
diff -Naur u-boot-2006-05-10-1800/cpu/microblaze/icache.S u-boot-2006-05-10-1800-microblaze/cpu/microblaze/icache.S
--- u-boot-2006-05-10-1800/cpu/microblaze/icache.S	1970-01-01 01:00:00.000000000 +0100
+++ u-boot-2006-05-10-1800-microblaze/cpu/microblaze/icache.S	2006-06-15 21:05:09.000000000 +0200
@@ -0,0 +1,53 @@
+/*
+ * (C) Copyright 2006 Michal Simek
+ *
+ * Michal  SIMEK <www.monstr.eu>
+ *
+ * See file CREDITS for list of people who contributed to this
+ * project.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of
+ * the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.	 See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ */
+
+	.text
+	.globl	icache_enable
+	.ent	icache_enable
+	.align	2
+icache_enable:
+	addi	r1, r1, -4
+	swi	r12, r1, 0
+	mfs	r12, rmsr
+	ori	r12, r12, 0x20
+	mts	rmsr, r12
+	lwi	r12, r1, 0
+	rtsd	r15, 8
+	addi	r1, r1, 4
+	.end	icache_enable
+
+	.text
+	.globl	icache_disable
+	.ent	icache_disable
+	.align	2
+icache_disable:
+	addi	r1, r1, -4
+	swi	r12, r1, 0
+	mfs	r12, rmsr
+	andi	r12, r12, ~0x20
+	mts	rmsr, r12
+	lwi	r12, r1, 0
+	rtsd	r15, 8
+	addi	r1, r1, 4
+	.end	icache_disable

