Patchwork [U-Boot,v2] mx27: add function enable_caches

login
register
mail settings
Submitter trem
Date June 14, 2013, 4:21 p.m.
Message ID <1371226882-12727-1-git-send-email-tremyfr@yahoo.fr>
Download mbox | patch
Permalink /patch/251452/
State Awaiting Upstream
Delegated to: Stefano Babic
Headers show

Comments

trem - June 14, 2013, 4:21 p.m.
Signed-off-by: Philippe Reynes <tremyfr@yahoo.fr>
---
 arch/arm/cpu/arm926ejs/mx27/generic.c |    8 ++++++++
 1 files changed, 8 insertions(+), 0 deletions(-)

v2:
- add flag CONFIG_SYS_DCACHE_OFF
Stefano Babic - June 26, 2013, 3:03 p.m.
On 14/06/2013 18:21, Philippe Reynes wrote:
> Signed-off-by: Philippe Reynes <tremyfr@yahoo.fr>
> ---

Applied to u-boot-imx, thanks.

Best regards,
Stefano Babic

Patch

diff --git a/arch/arm/cpu/arm926ejs/mx27/generic.c b/arch/arm/cpu/arm926ejs/mx27/generic.c
index 41bb84b..bffbadd 100644
--- a/arch/arm/cpu/arm926ejs/mx27/generic.c
+++ b/arch/arm/cpu/arm926ejs/mx27/generic.c
@@ -380,3 +380,11 @@  void mx27_sd2_init_pins(void)
 
 }
 #endif /* CONFIG_MXC_MMC */
+
+#ifndef CONFIG_SYS_DCACHE_OFF
+void enable_caches(void)
+{
+	/* Enable D-cache. I-cache is already enabled in start.S */
+	dcache_enable();
+}
+#endif /* CONFIG_SYS_DCACHE_OFF */