Comments
Patch
@@ -93,9 +93,6 @@ car_init_ret:
subl $1b, %ecx
movl %ecx, (GD_LOAD_OFF * 4)(%ebp)
- /* size memory */
- call dram_init_f
-
/* Set parameter to board_init_f() to boot flags */
movl (GD_FLAGS * 4)(%ebp), %eax
@@ -173,6 +173,8 @@ init_fnc_t *init_sequence[] = {
gd_t *gd;
+int dram_init_f(void);
+
/*
* Load U-Boot into RAM, initialize BSS, perform relocation adjustments
*/
@@ -197,6 +199,9 @@ void board_init_f (ulong boot_flags)
gd->flags = boot_flags;
+ if (dram_init_f() != 0)
+ hang();
+
/* Calculate destination RAM Address and relocation offset */
dest_addr = (void *)gd->ram_size;
addr_sp = dest_addr;