Blackfin: use common strmhz() in system output
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
This commit is contained in:
parent
5df70e91c7
commit
6dadc9195a
|
@ -328,18 +328,20 @@ int do_bdinfo ( cmd_tbl_t *cmdtp, int flag, int argc, char *argv[])
|
||||||
}
|
}
|
||||||
|
|
||||||
#elif defined(CONFIG_BLACKFIN)
|
#elif defined(CONFIG_BLACKFIN)
|
||||||
|
static void print_str(const char *, const char *);
|
||||||
|
|
||||||
int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char *argv[])
|
int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char *argv[])
|
||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
bd_t *bd = gd->bd;
|
bd_t *bd = gd->bd;
|
||||||
|
char buf[32];
|
||||||
|
|
||||||
printf("U-Boot = %s\n", bd->bi_r_version);
|
printf("U-Boot = %s\n", bd->bi_r_version);
|
||||||
printf("CPU = %s\n", bd->bi_cpu);
|
printf("CPU = %s\n", bd->bi_cpu);
|
||||||
printf("Board = %s\n", bd->bi_board_name);
|
printf("Board = %s\n", bd->bi_board_name);
|
||||||
printf("VCO = %lu MHz\n", bd->bi_vco / 1000000);
|
print_str("VCO", strmhz(buf, bd->bi_vco));
|
||||||
printf("CCLK = %lu MHz\n", bd->bi_cclk / 1000000);
|
print_str("CCLK", strmhz(buf, bd->bi_cclk));
|
||||||
printf("SCLK = %lu MHz\n", bd->bi_sclk / 1000000);
|
print_str("SCLK", strmhz(buf, bd->bi_sclk));
|
||||||
|
|
||||||
print_num("boot_params", (ulong)bd->bi_boot_params);
|
print_num("boot_params", (ulong)bd->bi_boot_params);
|
||||||
print_num("memstart", (ulong)bd->bi_memstart);
|
print_num("memstart", (ulong)bd->bi_memstart);
|
||||||
|
@ -430,7 +432,7 @@ static void print_lnum(const char *name, u64 value)
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined(CONFIG_PPC) || defined(CONFIG_M68K)
|
#if defined(CONFIG_PPC) || defined(CONFIG_M68K) || defined(CONFIG_BLACKFIN)
|
||||||
static void print_str(const char *name, const char *str)
|
static void print_str(const char *name, const char *str)
|
||||||
{
|
{
|
||||||
printf ("%-12s= %6s MHz\n", name, str);
|
printf ("%-12s= %6s MHz\n", name, str);
|
||||||
|
|
|
@ -257,6 +257,7 @@ void board_init_f(ulong bootflag)
|
||||||
{
|
{
|
||||||
ulong addr;
|
ulong addr;
|
||||||
bd_t *bd;
|
bd_t *bd;
|
||||||
|
char buf[32];
|
||||||
|
|
||||||
#ifdef CONFIG_BOARD_EARLY_INIT_F
|
#ifdef CONFIG_BOARD_EARLY_INIT_F
|
||||||
serial_early_puts("Board early init flash\n");
|
serial_early_puts("Board early init flash\n");
|
||||||
|
@ -315,8 +316,9 @@ void board_init_f(ulong bootflag)
|
||||||
checkboard();
|
checkboard();
|
||||||
timer_init();
|
timer_init();
|
||||||
|
|
||||||
printf("Clock: VCO: %lu MHz, Core: %lu MHz, System: %lu MHz\n",
|
printf("Clock: VCO: %s MHz, ", strmhz(buf, get_vco()));
|
||||||
get_vco() / 1000000, get_cclk() / 1000000, get_sclk() / 1000000);
|
printf("Core: %s MHz, ", strmhz(buf, get_cclk()));
|
||||||
|
printf("System: %s MHz\n", strmhz(buf, get_sclk()));
|
||||||
|
|
||||||
printf("RAM: ");
|
printf("RAM: ");
|
||||||
print_size(initdram(0), "\n");
|
print_size(initdram(0), "\n");
|
||||||
|
|
Loading…
Reference in New Issue