mail archive of the barebox mailing list
 help / color / mirror / Atom feed
* [PATCH] edb93xx: Fix SDRAM initialization
@ 2010-02-10 19:56 Matthias Kaehlcke
  2010-02-12  7:09 ` Sascha Hauer
  0 siblings, 1 reply; 2+ messages in thread
From: Matthias Kaehlcke @ 2010-02-10 19:56 UTC (permalink / raw)
  To: barebox

Before programming the SDRAM mode registers, mode register update mode must be
selected by setting the MRS bit and clearing INIT in GlConfig

Signed-off-by: Matthias Kaehlcke <matthias@kaehlcke.net>
---
 board/edb93xx/sdram_cfg.c |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)

diff --git a/board/edb93xx/sdram_cfg.c b/board/edb93xx/sdram_cfg.c
index 9f56f72..25b214b 100644
--- a/board/edb93xx/sdram_cfg.c
+++ b/board/edb93xx/sdram_cfg.c
@@ -111,6 +111,11 @@ static void setup_refresh_timer(void)
 
 static void program_mode_registers(void)
 {
+	struct sdram_regs *sdram = (struct sdram_regs *)SDRAM_BASE;
+
+	/* Select mode register update mode */
+	writel(GLCONFIG_MRS | GLCONFIG_CKE, &sdram->glconfig);
+
 	PROGRAM_MODE_REG(0);
 
 #if (CONFIG_EP93XX_SDRAM_NUM_BANKS >= 2)
-- 
1.6.5


_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

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

end of thread, other threads:[~2010-02-12  7:10 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-02-10 19:56 [PATCH] edb93xx: Fix SDRAM initialization Matthias Kaehlcke
2010-02-12  7:09 ` Sascha Hauer

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