* [PATCH] ARM: i.MX external NAND boot: Add missing instruction cache invalidate
@ 2013-12-03 9:15 Sascha Hauer
0 siblings, 0 replies; only message in thread
From: Sascha Hauer @ 2013-12-03 9:15 UTC (permalink / raw)
To: barebox
Before we jump to SDRAM where we just copied our code we have to
invalidate the instruction cache.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
---
arch/arm/mach-imx/external-nand-boot.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/arch/arm/mach-imx/external-nand-boot.c b/arch/arm/mach-imx/external-nand-boot.c
index b0aeb43..1af46b7 100644
--- a/arch/arm/mach-imx/external-nand-boot.c
+++ b/arch/arm/mach-imx/external-nand-boot.c
@@ -15,6 +15,7 @@
#include <init.h>
#include <io.h>
#include <linux/mtd/nand.h>
+#include <asm/cache.h>
#include <asm/sections.h>
#include <asm/barebox-arm.h>
#include <asm/barebox-arm-head.h>
@@ -244,6 +245,8 @@ void __bare_init imx_nand_load_image(void *dest, int size, void __iomem *base,
*/
static __bare_init __naked void jump_sdram(unsigned long offset)
{
+ flush_icache();
+
__asm__ __volatile__ (
"sub lr, lr, %0;"
"mov pc, lr;" : : "r"(offset)
--
1.8.4.3
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2013-12-03 9:15 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-12-03 9:15 [PATCH] ARM: i.MX external NAND boot: Add missing instruction cache invalidate Sascha Hauer
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox