]> git.sur5r.net Git - u-boot/blobdiff - arch/arm/cpu/armv7/omap-common/spl.c
omap/spl: actually enable the console
[u-boot] / arch / arm / cpu / armv7 / omap-common / spl.c
index c76fea6188103d1131691750bf51028cfba46c68..2c59d2b36bd515936c0afd68bfd671e4f8b1985e 100644 (file)
 #include <nand.h>
 #include <mmc.h>
 #include <fat.h>
-#include <timestamp_autogenerated.h>
-#include <version_autogenerated.h>
+#include <version.h>
 #include <asm/omap_common.h>
 #include <asm/arch/mmc_host_def.h>
 #include <i2c.h>
 #include <image.h>
+#include <malloc.h>
 
 DECLARE_GLOBAL_DATA_PTR;
 
@@ -106,6 +106,9 @@ void board_init_r(gd_t *id, ulong dummy)
        u32 boot_device;
        debug(">>spl:board_init_r()\n");
 
+       mem_malloc_init(CONFIG_SYS_SPL_MALLOC_START,
+                       CONFIG_SYS_SPL_MALLOC_SIZE);
+
        timer_init();
        i2c_init(CONFIG_SYS_I2C_SPEED, CONFIG_SYS_I2C_SLAVE);
 
@@ -153,6 +156,8 @@ void preloader_console_init(void)
 
        serial_init();          /* serial communications setup */
 
+       gd->have_console = 1;
+
        /* Avoid a second "U-Boot" coming from this string */
        u_boot_rev = &u_boot_rev[7];
 
@@ -161,3 +166,11 @@ void preloader_console_init(void)
        omap_rev_string(rev_string_buffer);
        printf("Texas Instruments %s\n", rev_string_buffer);
 }
+
+void __omap_rev_string(char *str)
+{
+       sprintf(str, "Revision detection unimplemented");
+}
+
+void omap_rev_string(char *str)
+       __attribute__((weak, alias("__omap_rev_string")));