arm: Make jadecpu board use relocation
authorMatthias Weisser <weisserm@arcor.de>
Tue, 21 Sep 2010 13:37:44 +0000 (15:37 +0200)
committerWolfgang Denk <wd@denx.de>
Tue, 21 Sep 2010 19:42:01 +0000 (21:42 +0200)
This patch modifies jadecpu board so that it is usable
with the relocation patches by Heiko Schocher

Signed-off-by: Matthias Weisser <weisserm@arcor.de>
board/syteco/jadecpu/config.mk
board/syteco/jadecpu/jadecpu.c
include/configs/jadecpu.h

index c661f0b8afda81c45529267cc1a4e57c801e4435..91994b0c33de93ea8756e545debe4f3a46b2f7e7 100644 (file)
@@ -1 +1 @@
-TEXT_BASE = 0x46000000
+TEXT_BASE = 0x10000000
index 04d2f9d5a66539f500c499d7064c7fdb82298a6e..69476f8fc302ae113f2038cf4a34ba945c60c557 100644 (file)
@@ -154,12 +154,19 @@ int misc_init_r(void)
  */
 int dram_init(void)
 {
-       gd->bd->bi_dram[0].start = PHYS_SDRAM;
-       gd->bd->bi_dram[0].size = PHYS_SDRAM_SIZE;
+       /* dram_init must store complete ramsize in gd->ram_size */
+       gd->ram_size = get_ram_size((volatile void *)PHYS_SDRAM,
+                                       PHYS_SDRAM_SIZE);
 
        return 0;
 }
 
+void dram_init_banksize(void)
+{
+       gd->bd->bi_dram[0].start = PHYS_SDRAM;
+       gd->bd->bi_dram[0].size = gd->ram_size;
+}
+
 int board_eth_init(bd_t *bis)
 {
        int rc = 0;
index 29c534c4a9f248050c74f51563eafbb952d72d79..a5d8764b519cae58160bf784f80e07b5fd2c9f56 100644 (file)
 #define PHYS_SDRAM             0x40000000      /* Start address of DDRRAM */
 #define PHYS_SDRAM_SIZE        0x08000000      /* 128 megs */
 
+#define CONFIG_SYS_SDRAM_BASE  PHYS_SDRAM
+#define CONFIG_SYS_INIT_SP_ADDR        0x01008000
+
 /*
  * FLASH and environment organization
  */