bdinfo: nios2: Use the generic bd command
authorSimon Glass <sjg@chromium.org>
Sun, 10 May 2020 20:16:30 +0000 (14:16 -0600)
committerTom Rini <trini@konsulko.com>
Thu, 25 Jun 2020 17:24:11 +0000 (13:24 -0400)
Nios2 currently has some code to output SRAM information which is behind
an #ifdef. No nios2 boards define this option, so the code can be removed.

Move Nios2 over to use the generic function.

Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
cmd/bdinfo.c

index 761bcc18621b823b783343ce8d508a1ff85ae9fe..a8f25cc2fbf7f39361f0cbdcc5492827366c1aab 100644 (file)
@@ -222,24 +222,7 @@ int do_bdinfo(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[])
 
 #elif defined(CONFIG_NIOS2)
 
-int do_bdinfo(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[])
-{
-       bd_t *bd = gd->bd;
-
-       print_bi_dram(bd);
-       print_bi_flash(bd);
-
-#if defined(CONFIG_SYS_SRAM_BASE)
-       print_num ("sram start",        (ulong)bd->bi_sramstart);
-       print_num ("sram size",         (ulong)bd->bi_sramsize);
-#endif
-
-       print_eth_ip_addr();
-       print_baudrate();
-       print_cpu_word_size();
-
-       return 0;
-}
+#define USE_GENERIC
 
 #elif defined(CONFIG_MICROBLAZE)