public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [U-Boot] [PATCH 01/13] mxs: Reset the EMI block on mx23
@ 2013-02-23 12:42 Marek Vasut
  2013-02-23 12:42 ` [U-Boot] [PATCH 02/13] mxs: mmc: spi: dma: Better wrap the MXS differences Marek Vasut
                   ` (13 more replies)
  0 siblings, 14 replies; 25+ messages in thread
From: Marek Vasut @ 2013-02-23 12:42 UTC (permalink / raw)
  To: u-boot

The real reason for memory instability was the fact that the EMI block
was gated and not reset throughout the boards' operation. This patch
resets the EMI block properly while also reverts the memory voltage bump.
The memory stability issues were caused by the EMI not being reset properly
and thus there is no longer need to run the memory at higher voltage than
it ought to run at.

This partly reverts 8303ed128a55519f19c5f11087032d4bc4e0537a .

Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Fabio Estevam <fabio.estevam@freescale.com>
Cc: Otavio Salvador <otavio@ossystems.com.br>
Cc: Stefano Babic <sbabic@denx.de>
---
 arch/arm/cpu/arm926ejs/mxs/spl_mem_init.c |   12 ++++++++++--
 1 file changed, 10 insertions(+), 2 deletions(-)

diff --git a/arch/arm/cpu/arm926ejs/mxs/spl_mem_init.c b/arch/arm/cpu/arm926ejs/mxs/spl_mem_init.c
index f8392f6..4a0a5aa 100644
--- a/arch/arm/cpu/arm926ejs/mxs/spl_mem_init.c
+++ b/arch/arm/cpu/arm926ejs/mxs/spl_mem_init.c
@@ -27,6 +27,7 @@
 #include <config.h>
 #include <asm/io.h>
 #include <asm/arch/imx-regs.h>
+#include <asm/arch/sys_proto.h>
 #include <linux/compiler.h>
 
 #include "mxs_init.h"
@@ -229,7 +230,7 @@ static void mx23_mem_setup_vddmem(void)
 	struct mxs_power_regs *power_regs =
 		(struct mxs_power_regs *)MXS_POWER_BASE;
 
-	writel((0x12 << POWER_VDDMEMCTRL_TRG_OFFSET) |
+	writel((0x10 << POWER_VDDMEMCTRL_TRG_OFFSET) |
 		POWER_VDDMEMCTRL_ENABLE_ILIMIT |
 		POWER_VDDMEMCTRL_ENABLE_LINREG |
 		POWER_VDDMEMCTRL_PULLDOWN_ACTIVE,
@@ -237,13 +238,20 @@ static void mx23_mem_setup_vddmem(void)
 
 	early_delay(10000);
 
-	writel((0x12 << POWER_VDDMEMCTRL_TRG_OFFSET) |
+	writel((0x10 << POWER_VDDMEMCTRL_TRG_OFFSET) |
 		POWER_VDDMEMCTRL_ENABLE_LINREG,
 		&power_regs->hw_power_vddmemctrl);
 }
 
 static void mx23_mem_init(void)
 {
+	/*
+	 * Reset/ungate the EMI block. This is essential, otherwise the system
+	 * suffers from memory instability. This thing is mx23 specific and is
+	 * no longer present on mx28.
+	 */
+	mxs_reset_block((struct mxs_register_32 *)MXS_EMI_BASE);
+
 	mx23_mem_setup_vddmem();
 
 	/*
-- 
1.7.10.4

^ permalink raw reply related	[flat|nested] 25+ messages in thread

end of thread, other threads:[~2013-03-07 16:56 UTC | newest]

Thread overview: 25+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-02-23 12:42 [U-Boot] [PATCH 01/13] mxs: Reset the EMI block on mx23 Marek Vasut
2013-02-23 12:42 ` [U-Boot] [PATCH 02/13] mxs: mmc: spi: dma: Better wrap the MXS differences Marek Vasut
2013-02-23 12:42 ` [U-Boot] [PATCH 03/13] mxs: spi: Fix the MXS SPI for mx23 Marek Vasut
2013-02-23 15:28   ` Otavio Salvador
2013-02-23 17:41     ` Marek Vasut
2013-02-23 12:43 ` [U-Boot] [PATCH 04/13] mxs: spi: Remove CONFIG_MXS_SPI_DMA_ENABLE Marek Vasut
2013-02-23 14:11   ` Fabio Estevam
2013-02-23 17:25     ` Marek Vasut
2013-02-23 12:43 ` [U-Boot] [PATCH 05/13] mxs: Squash the header file usage in ehci-mxs Marek Vasut
2013-02-23 15:32   ` Otavio Salvador
2013-02-23 12:43 ` [U-Boot] [PATCH 06/13] mxs: Make ehci-mxs multiport capable Marek Vasut
2013-02-23 15:31   ` Otavio Salvador
2013-02-23 12:43 ` [U-Boot] [PATCH 07/13] mxs: m28: Enable power to USB port 0 Marek Vasut
2013-02-23 12:43 ` [U-Boot] [PATCH 08/13] mxs: Rename CONFIG_SPL_MX28_PSWITCH_WAIT to CONFIG_SPL_MXS_PSWITCH_WAIT Marek Vasut
2013-02-23 12:43 ` [U-Boot] [PATCH 09/13] mx23: Document the tRAS lockout setting in memory initialization Marek Vasut
2013-02-23 12:43 ` [U-Boot] [PATCH 10/13] mx23evk: Adjust DRAM control register to use full 128MB of RAM Marek Vasut
2013-02-23 12:43 ` [U-Boot] [PATCH 11/13] led: Use STATUS_LED_ON and STATUS_LED_OFF when calling __led_set Marek Vasut
2013-02-23 12:43 ` [U-Boot] [PATCH 12/13] mxs: Fix iomux.h to not break build during assembly stage Marek Vasut
2013-02-23 12:43 ` [U-Boot] [PATCH 13/13] mx23_olinuxino: Add support for status LED Marek Vasut
2013-02-23 15:27 ` [U-Boot] [PATCH 01/13] mxs: Reset the EMI block on mx23 Otavio Salvador
2013-02-23 17:41   ` Marek Vasut
2013-02-23 17:54     ` Otavio Salvador
2013-02-23 18:48       ` Marek Vasut
2013-02-23 17:55   ` Marek Vasut
2013-03-07 16:56 ` Stefano Babic

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox