From: Michal Simek Date: Mon, 5 Jan 2009 12:28:40 +0000 (+0100) Subject: microblaze: Add bootup messages to board.c X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=b4f8dda35bfad447b4106828232705b2e878d168;p=project%2Fbcm63xx%2Fu-boot.git microblaze: Add bootup messages to board.c --- diff --git a/lib_microblaze/board.c b/lib_microblaze/board.c index 4f48341f33..732f81e767 100644 --- a/lib_microblaze/board.c +++ b/lib_microblaze/board.c @@ -111,6 +111,10 @@ void board_init (void) gd = (gd_t *) CONFIG_SYS_GBL_DATA_OFFSET; #if defined(CONFIG_CMD_FLASH) ulong flash_size = 0; +#endif +#if defined(CONFIG_CMD_NET) + char *s, *e; + int i; #endif asm ("nop"); /* FIXME gd is not initialize - wait */ memset ((void *)gd, 0, CONFIG_SYS_GBL_DATA_SIZE); @@ -132,11 +136,37 @@ void board_init (void) } } + puts ("SDRAM :\n"); +#if defined(CONFIG_CMD_CACHE) + puts ("\tEnabling caches :\n"); + printf ("\t\tIcache:%s\n", icache_status() ? "OK" : "FAIL"); + printf ("\t\tDcache:%s\n", dcache_status() ? "OK" : "FAIL"); +#endif + printf ("\tU-Boot Start:0x%08x\n", TEXT_BASE); + #if defined(CONFIG_CMD_FLASH) + puts ("FLASH: "); bd->bi_flashstart = CONFIG_SYS_FLASH_BASE; if (0 < (flash_size = flash_init ())) { bd->bi_flashsize = flash_size; bd->bi_flashoffset = CONFIG_SYS_FLASH_BASE + flash_size; +# ifdef CONFIG_SYS_FLASH_CHECKSUM + print_size (flash_size, ""); + /* + * Compute and print flash CRC if flashchecksum is set to 'y' + * + * NOTE: Maybe we should add some WATCHDOG_RESET()? XXX + */ + s = getenv ("flashchecksum"); + if (s && (*s == 'y')) { + printf (" CRC: %08X", + crc32 (0, (const unsigned char *) CONFIG_SYS_FLASH_BASE, flash_size) + ); + } + putc ('\n'); +# else /* !CONFIG_SYS_FLASH_CHECKSUM */ + print_size (flash_size, "\n"); +# endif /* CONFIG_SYS_FLASH_CHECKSUM */ } else { puts ("Flash init FAILED"); bd->bi_flashstart = 0; @@ -146,10 +176,9 @@ void board_init (void) #endif #if defined(CONFIG_CMD_NET) - char *s, *e; - int i; /* board MAC address */ s = getenv ("ethaddr"); + printf ("MAC:%s\n",s); for (i = 0; i < 6; ++i) { bd->bi_enetaddr[i] = s ? simple_strtoul (s, &e, 16) : 0; if (s)