]> git.kernelconcepts.de Git - karo-tx-uboot.git/blobdiff - common/cmd_bdinfo.c
README: add explanation about patch policy
[karo-tx-uboot.git] / common / cmd_bdinfo.c
index 28be4b65c8e51aefc4065c273c7b36decc2ae82a..ca834732b82f45808b16b5712f36a390ac7583b8 100644 (file)
@@ -55,15 +55,17 @@ int do_bdinfo ( cmd_tbl_t *cmdtp, int flag, int argc, char *argv[])
        print_num ("flashoffset",   bd->bi_flashoffset  );
        print_num ("sramstart",     bd->bi_sramstart    );
        print_num ("sramsize",      bd->bi_sramsize     );
-#if defined(CONFIG_5xx) || defined(CONFIG_8xx) || defined(CONFIG_8260) || defined(CONFIG_E500)
+#if defined(CONFIG_5xx)  || defined(CONFIG_8xx) || \
+    defined(CONFIG_8260) || defined(CONFIG_E500)
        print_num ("immr_base",     bd->bi_immr_base    );
 #endif
        print_num ("bootflags",     bd->bi_bootflags    );
-#if defined(CONFIG_405GP) || defined(CONFIG_405CR) || defined(CONFIG_405EP) || defined(CONFIG_XILINX_ML300)
+#if defined(CONFIG_405GP) || defined(CONFIG_405CR) || \
+    defined(CONFIG_405EP) || defined(CONFIG_XILINX_ML300)
        print_str ("procfreq",      strmhz(buf, bd->bi_procfreq));
-       print_str ("plb_busfreq",           strmhz(buf, bd->bi_plb_busfreq));
+       print_str ("plb_busfreq",   strmhz(buf, bd->bi_plb_busfreq));
 #if defined(CONFIG_405GP) || defined(CONFIG_405EP) || defined(CONFIG_XILINX_ML300)
-       print_str ("pci_busfreq",           strmhz(buf, bd->bi_pci_busfreq));
+       print_str ("pci_busfreq",   strmhz(buf, bd->bi_pci_busfreq));
 #endif
 #else  /* ! CONFIG_405GP, CONFIG_405CR, CONFIG_405EP, CONFIG_XILINX_ML300 */
 #if defined(CONFIG_8260) || defined(CONFIG_MPC8560)
@@ -77,23 +79,40 @@ int do_bdinfo ( cmd_tbl_t *cmdtp, int flag, int argc, char *argv[])
 #endif
        print_str ("busfreq",       strmhz(buf, bd->bi_busfreq));
 #endif /* CONFIG_405GP, CONFIG_405CR, CONFIG_405EP, CONFIG_XILINX_ML300 */
+#if defined(CONFIG_MPC8220)
+       print_str ("inpfreq",       strmhz(buf, bd->bi_inpfreq));
+       print_str ("flbfreq",       strmhz(buf, bd->bi_flbfreq));
+       print_str ("pcifreq",       strmhz(buf, bd->bi_pcifreq));
+       print_str ("vcofreq",       strmhz(buf, bd->bi_vcofreq));
+       print_str ("pevfreq",       strmhz(buf, bd->bi_pevfreq));
+#endif
+
        puts ("ethaddr     =");
        for (i=0; i<6; ++i) {
                printf ("%c%02X", i ? ':' : ' ', bd->bi_enetaddr[i]);
        }
-#if (defined CONFIG_PN62) || (defined CONFIG_PPCHAMELEONEVB) \
-    || (defined CONFIG_MPC8540ADS) || (defined CONFIG_MPC8560ADS)
+
+#if defined(CONFIG_HAS_ETH1)
        puts ("\neth1addr    =");
        for (i=0; i<6; ++i) {
                printf ("%c%02X", i ? ':' : ' ', bd->bi_enet1addr[i]);
        }
-#endif /* CONFIG_PN62 */
-#if defined(CONFIG_MPC8540ADS) || defined(CONFIG_MPC8560ADS)
+#endif
+
+#if defined(CONFIG_HAS_ETH2)
        puts ("\neth2addr    =");
        for (i=0; i<6; ++i) {
                printf ("%c%02X", i ? ':' : ' ', bd->bi_enet2addr[i]);
        }
 #endif
+
+#if defined(CONFIG_HAS_ETH3)
+       puts ("\neth3addr    =");
+       for (i=0; i<6; ++i) {
+               printf ("%c%02X", i ? ':' : ' ', bd->bi_enet3addr[i]);
+       }
+#endif
+
 #ifdef CONFIG_HERMES
        print_str ("ethspeed",      strmhz(buf, bd->bi_ethspeed));
 #endif
@@ -128,6 +147,39 @@ int do_bdinfo ( cmd_tbl_t *cmdtp, int flag, int argc, char *argv[])
        return 0;
 }
 
+#elif defined(CONFIG_NIOS2) /* Nios-II */
+
+int do_bdinfo ( cmd_tbl_t *cmdtp, int flag, int argc, char *argv[])
+{
+       DECLARE_GLOBAL_DATA_PTR;
+
+       int i;
+       bd_t *bd = gd->bd;
+
+       print_num ("mem start",         (ulong)bd->bi_memstart);
+       print_num ("mem size",          (ulong)bd->bi_memsize);
+       print_num ("flash start",       (ulong)bd->bi_flashstart);
+       print_num ("flash size",        (ulong)bd->bi_flashsize);
+       print_num ("flash offset",      (ulong)bd->bi_flashoffset);
+
+#if defined(CFG_SRAM_BASE)
+       print_num ("sram start",        (ulong)bd->bi_sramstart);
+       print_num ("sram size",         (ulong)bd->bi_sramsize);
+#endif
+
+#if defined(CFG_CMD_NET)
+       puts ("ethaddr     =");
+       for (i=0; i<6; ++i) {
+               printf ("%c%02X", i ? ':' : ' ', bd->bi_enetaddr[i]);
+       }
+       puts ("\nip_addr     = ");
+       print_IPaddr (bd->bi_ip_addr);
+#endif
+
+       printf ("\nbaudrate    = %ld bps\n", bd->bi_baudrate);
+
+       return 0;
+}
 
 #else /* ! PPC, which leaves MIPS */