summaryrefslogtreecommitdiff
path: root/arch/arm/mach-rockchip/spl.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/mach-rockchip/spl.c')
-rw-r--r--arch/arm/mach-rockchip/spl.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/arch/arm/mach-rockchip/spl.c b/arch/arm/mach-rockchip/spl.c
index 46b32eb345..cddf4fd3d5 100644
--- a/arch/arm/mach-rockchip/spl.c
+++ b/arch/arm/mach-rockchip/spl.c
@@ -108,9 +108,6 @@ __weak int arch_cpu_init(void)
void board_init_f(ulong dummy)
{
int ret;
-#if !defined(CONFIG_TPL) || defined(CONFIG_SPL_OS_BOOT)
- struct udevice *dev;
-#endif
#ifdef CONFIG_DEBUG_UART
/*
@@ -140,13 +137,15 @@ void board_init_f(ulong dummy)
/* Init ARM arch timer in arch/arm/cpu/armv7/arch_timer.c */
timer_init();
#endif
-#if !defined(CONFIG_TPL) || defined(CONFIG_SPL_OS_BOOT)
+#if !defined(CONFIG_TPL) || defined(CONFIG_SPL_RAM)
debug("\nspl:init dram\n");
- ret = uclass_get_device(UCLASS_RAM, 0, &dev);
+ ret = dram_init();
if (ret) {
printf("DRAM init failed: %d\n", ret);
return;
}
+ gd->ram_top = gd->ram_base + get_effective_memsize();
+ gd->ram_top = board_get_usable_ram_top(gd->ram_size);
#endif
preloader_console_init();
}