summaryrefslogtreecommitdiffstats
path: root/board/freescale/mpc8540ads/mpc8540ads.c
diff options
context:
space:
mode:
authorKumar Gala <galak@kernel.crashing.org>2008-06-06 13:12:18 -0500
committerKumar Gala <galak@kernel.crashing.org>2008-08-27 11:43:48 -0500
commit9617c8d49a21703eaf13a4033ab1a56eecc033cc (patch)
tree82d74807cf979a8848774b8593c4a7f1d2906672 /board/freescale/mpc8540ads/mpc8540ads.c
parent2a6c2d7ab2a66660f40a6cd3de2eb29ee29d9693 (diff)
downloadblackbird-obmc-uboot-9617c8d49a21703eaf13a4033ab1a56eecc033cc.tar.gz
blackbird-obmc-uboot-9617c8d49a21703eaf13a4033ab1a56eecc033cc.zip
FSL DDR: Convert MPC8540ADS to new DDR code.
Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
Diffstat (limited to 'board/freescale/mpc8540ads/mpc8540ads.c')
-rw-r--r--board/freescale/mpc8540ads/mpc8540ads.c14
1 files changed, 9 insertions, 5 deletions
diff --git a/board/freescale/mpc8540ads/mpc8540ads.c b/board/freescale/mpc8540ads/mpc8540ads.c
index 4f068cc884..005e4d97e9 100644
--- a/board/freescale/mpc8540ads/mpc8540ads.c
+++ b/board/freescale/mpc8540ads/mpc8540ads.c
@@ -1,4 +1,4 @@
- /*
+/*
* Copyright 2004 Freescale Semiconductor.
* (C) Copyright 2002,2003, Motorola Inc.
* Xianghua Xiao, (X.Xiao@motorola.com)
@@ -28,8 +28,9 @@
#include <common.h>
#include <pci.h>
#include <asm/processor.h>
+#include <asm/mmu.h>
#include <asm/immap_85xx.h>
-#include <spd_sdram.h>
+#include <asm/fsl_ddr_sdram.h>
#include <libfdt.h>
#include <fdt_support.h>
@@ -82,10 +83,13 @@ initdram(int board_type)
}
#endif
-#if defined(CONFIG_SPD_EEPROM)
- dram_size = spd_sdram ();
+#ifdef CONFIG_SPD_EEPROM
+ dram_size = fsl_ddr_sdram();
+ dram_size = setup_ddr_tlbs(dram_size / 0x100000);
+
+ dram_size *= 0x100000;
#else
- dram_size = fixed_sdram ();
+ dram_size = fixed_sdram();
#endif
#if defined(CONFIG_DDR_ECC) && !defined(CONFIG_ECC_INIT_VIA_DDRCONTROLLER)
OpenPOWER on IntegriCloud