Skip to contentSkip to conversation

mx27: add function enable_caches

PATCH New Philippe Reynes 2 participants 4 messages Jun 14, 2013 – Jun 26, 2013 Arm (32-bit)

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 mx27: add function enable_caches

---
 arch/arm/cpu/arm926ejs/mx27/generic.c |    8 ++++++++
 1 files changed, 8 insertions(+), 0 deletions(-)

v2:
- add flag CONFIG_SYS_DCACHE_OFF

arch/arm/cpu/arm926ejs/mx27/generic.c +8 -0
index 41bb84b..bffbadd 100644
@@ -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 */
Signature · 1 line
1.7.4.4
#1 lore raw

PATCH RESEND 1/1 mx27: add i2c clock

---
 arch/arm/cpu/arm926ejs/mx27/generic.c  |    2 ++
 arch/arm/include/asm/arch-mx27/clock.h |    1 +
 2 files changed, 3 insertions(+), 0 deletions(-)
arch/arm/cpu/arm926ejs/mx27/generic.c +2 -0
index bffbadd..a9a13cb 100644
@@ -159,6 +159,8 @@ unsigned int mxc_get_clock(enum mxc_clock clk)
 	switch (clk) {
 	case MXC_ARM_CLK:
 		return imx_get_armclk();
+	case MXC_I2C_CLK:
+		return imx_get_ahbclk()/2;
 	case MXC_UART_CLK:
 		return imx_get_perclk1();
 	case MXC_FEC_CLK:
arch/arm/include/asm/arch-mx27/clock.h +1 -0
index fd062d3..2b03a41 100644
@@ -26,6 +26,7 @@
 
 enum mxc_clock {
 	MXC_ARM_CLK,
+	MXC_I2C_CLK,
 	MXC_UART_CLK,
 	MXC_ESDHC_CLK,
 	MXC_FEC_CLK,
Signature · 1 line
1.7.4.4
#2 lore raw

PATCH RESEND 1/1 mx27: add i2c clock

Quoted 3 lines · Philippe Reynes

---

Applied to u-boot-imx, thanks.

Best regards,
Stefano Babic

Signature · 5 lines
=====================================================================
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-53 Fax: +49-8142-66989-80 Email: sbabic at denx.de
=====================================================================
#3 lore raw

PATCH v2 1/1 mx27: add function enable_caches

In reply to Philippe Reynes
Quoted 2 lines · Philippe Reynes

---

Applied to u-boot-imx, thanks.

Best regards,
Stefano Babic

Signature · 5 lines
=====================================================================
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-53 Fax: +49-8142-66989-80 Email: sbabic at denx.de
=====================================================================