]> git.sur5r.net Git - u-boot/blobdiff - arch/arm/mach-rockchip/rk3288-board-spl.c
rockchip: reserve memory for rk3399 ATF data
[u-boot] / arch / arm / mach-rockchip / rk3288-board-spl.c
index 185b5fdcf7286e4ff7c79b10da8dc6017443b16f..8ca6b1e43925ab2999ce31a09a374cc18564c32f 100644 (file)
@@ -14,6 +14,7 @@
 #include <spl.h>
 #include <asm/gpio.h>
 #include <asm/io.h>
+#include <asm/arch/bootrom.h>
 #include <asm/arch/clock.h>
 #include <asm/arch/hardware.h>
 #include <asm/arch/periph.h>
@@ -64,7 +65,9 @@ u32 spl_boot_device(void)
        }
 
 fallback:
-#elif defined(CONFIG_TARGET_CHROMEBOOK_JERRY)
+#elif defined(CONFIG_TARGET_CHROMEBOOK_JERRY) || \
+               defined(CONFIG_TARGET_CHROMEBIT_MICKEY) || \
+               defined(CONFIG_TARGET_CHROMEBOOK_MINNIE)
        return BOOT_DEVICE_SPI;
 #endif
        return BOOT_DEVICE_MMC1;
@@ -153,7 +156,7 @@ static int configure_emmc(struct udevice *pinctrl)
        return 0;
 }
 #endif
-extern void back_to_bootrom(void);
+
 void board_init_f(ulong dummy)
 {
        struct udevice *pinctrl;
@@ -161,7 +164,6 @@ void board_init_f(ulong dummy)
        int ret;
 
        /* Example code showing how to enable the debug UART on RK3288 */
-#ifdef EARLY_UART
 #include <asm/arch/grf_rk3288.h>
        /* Enable early UART on the RK3288 */
 #define GRF_BASE       0xff770000
@@ -180,11 +182,10 @@ void board_init_f(ulong dummy)
         * printascii("string");
         */
        debug_uart_init();
-#endif
-
-       ret = spl_init();
+       debug("\nspl:debug uart enabled in %s\n", __func__);
+       ret = spl_early_init();
        if (ret) {
-               debug("spl_init() failed: %d\n", ret);
+               debug("spl_early_init() failed: %d\n", ret);
                hang();
        }
 
@@ -202,7 +203,7 @@ void board_init_f(ulong dummy)
                debug("Pinctrl init failed: %d\n", ret);
                return;
        }
-
+       debug("\nspl:init dram\n");
        ret = uclass_get_device(UCLASS_RAM, 0, &dev);
        if (ret) {
                debug("DRAM init failed: %d\n", ret);