wdenk | 57b2d80 | 2003-06-27 21:31:46 +0000 | [diff] [blame] | 1 | /* |
| 2 | * (C) Copyright 2003 |
| 3 | * Wolfgang Denk, DENX Software Engineering, wd@denx.de. |
| 4 | * |
| 5 | * See file CREDITS for list of people who contributed to this |
| 6 | * project. |
| 7 | * |
| 8 | * This program is free software; you can redistribute it and/or |
| 9 | * modify it under the terms of the GNU General Public License as |
| 10 | * published by the Free Software Foundation; either version 2 of |
| 11 | * the License, or (at your option) any later version. |
| 12 | * |
| 13 | * This program is distributed in the hope that it will be useful, |
| 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 16 | * GNU General Public License for more details. |
| 17 | * |
| 18 | * You should have received a copy of the GNU General Public License |
| 19 | * along with this program; if not, write to the Free Software |
| 20 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, |
| 21 | * MA 02111-1307 USA |
| 22 | */ |
| 23 | |
| 24 | /* |
| 25 | * Boot support |
| 26 | */ |
| 27 | #include <common.h> |
| 28 | #include <command.h> |
wdenk | 57b2d80 | 2003-06-27 21:31:46 +0000 | [diff] [blame] | 29 | |
Wolfgang Denk | 6405a15 | 2006-03-31 18:32:53 +0200 | [diff] [blame] | 30 | DECLARE_GLOBAL_DATA_PTR; |
wdenk | 57b2d80 | 2003-06-27 21:31:46 +0000 | [diff] [blame] | 31 | |
wdenk | 57b2d80 | 2003-06-27 21:31:46 +0000 | [diff] [blame] | 32 | static void print_num(const char *, ulong); |
| 33 | |
Simon Glass | 4413ed3 | 2011-09-17 06:48:47 +0000 | [diff] [blame^] | 34 | #if !(defined(CONFIG_ARM) || defined(CONFIG_M68K) || defined(CONFIG_SANDBOX)) \ |
| 35 | || defined(CONFIG_CMD_NET) |
| 36 | #define HAVE_PRINT_ETH |
Mike Frysinger | 9335cc7 | 2009-02-11 18:50:10 -0500 | [diff] [blame] | 37 | static void print_eth(int idx); |
Wolfgang Denk | 770a188 | 2009-03-29 00:54:21 +0100 | [diff] [blame] | 38 | #endif |
Mike Frysinger | 9335cc7 | 2009-02-11 18:50:10 -0500 | [diff] [blame] | 39 | |
Simon Glass | 4413ed3 | 2011-09-17 06:48:47 +0000 | [diff] [blame^] | 40 | #if (!defined(CONFIG_ARM) && !defined(CONFIG_X86) && !defined(CONFIG_SANDBOX)) |
| 41 | #define HAVE_PRINT_LNUM |
Becky Bruce | a36601e | 2008-06-09 20:37:16 -0500 | [diff] [blame] | 42 | static void print_lnum(const char *, u64); |
Reinhard Meyer | 0f8337b | 2010-06-06 19:01:59 +0200 | [diff] [blame] | 43 | #endif |
wdenk | 57b2d80 | 2003-06-27 21:31:46 +0000 | [diff] [blame] | 44 | |
Reinhard Meyer | 0f8337b | 2010-06-06 19:01:59 +0200 | [diff] [blame] | 45 | #if defined(CONFIG_PPC) |
wdenk | 57b2d80 | 2003-06-27 21:31:46 +0000 | [diff] [blame] | 46 | static void print_str(const char *, const char *); |
| 47 | |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 48 | int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) |
wdenk | 57b2d80 | 2003-06-27 21:31:46 +0000 | [diff] [blame] | 49 | { |
wdenk | 57b2d80 | 2003-06-27 21:31:46 +0000 | [diff] [blame] | 50 | bd_t *bd = gd->bd; |
| 51 | char buf[32]; |
| 52 | |
| 53 | #ifdef DEBUG |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 54 | print_num("bd address", (ulong)bd); |
wdenk | 57b2d80 | 2003-06-27 21:31:46 +0000 | [diff] [blame] | 55 | #endif |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 56 | print_num("memstart", bd->bi_memstart); |
| 57 | print_lnum("memsize", bd->bi_memsize); |
| 58 | print_num("flashstart", bd->bi_flashstart); |
| 59 | print_num("flashsize", bd->bi_flashsize); |
| 60 | print_num("flashoffset", bd->bi_flashoffset); |
| 61 | print_num("sramstart", bd->bi_sramstart); |
| 62 | print_num("sramsize", bd->bi_sramsize); |
| 63 | #if defined(CONFIG_5xx) || defined(CONFIG_8xx) || \ |
| 64 | defined(CONFIG_8260) || defined(CONFIG_E500) |
| 65 | print_num("immr_base", bd->bi_immr_base); |
wdenk | 57b2d80 | 2003-06-27 21:31:46 +0000 | [diff] [blame] | 66 | #endif |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 67 | print_num("bootflags", bd->bi_bootflags); |
| 68 | #if defined(CONFIG_405CR) || defined(CONFIG_405EP) || \ |
| 69 | defined(CONFIG_405GP) || \ |
| 70 | defined(CONFIG_440EP) || defined(CONFIG_440EPX) || \ |
| 71 | defined(CONFIG_440GR) || defined(CONFIG_440GRX) || \ |
| 72 | defined(CONFIG_440SP) || defined(CONFIG_440SPE) || \ |
| 73 | defined(CONFIG_XILINX_405) |
| 74 | print_str("procfreq", strmhz(buf, bd->bi_procfreq)); |
| 75 | print_str("plb_busfreq", strmhz(buf, bd->bi_plb_busfreq)); |
| 76 | #if defined(CONFIG_405EP) || defined(CONFIG_405GP) || \ |
| 77 | defined(CONFIG_440EP) || defined(CONFIG_440EPX) || \ |
| 78 | defined(CONFIG_440GR) || defined(CONFIG_440GRX) || \ |
| 79 | defined(CONFIG_440SPE) || defined(CONFIG_XILINX_405) |
| 80 | print_str("pci_busfreq", strmhz(buf, bd->bi_pci_busfreq)); |
wdenk | 57b2d80 | 2003-06-27 21:31:46 +0000 | [diff] [blame] | 81 | #endif |
Michal Simek | 594c7b5 | 2008-06-24 09:54:09 +0200 | [diff] [blame] | 82 | #else /* ! CONFIG_405GP, CONFIG_405CR, CONFIG_405EP, CONFIG_XILINX_405, CONFIG_440EP CONFIG_440GR */ |
Jon Loeliger | f5ad378 | 2005-07-23 10:37:35 -0500 | [diff] [blame] | 83 | #if defined(CONFIG_CPM2) |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 84 | print_str("vco", strmhz(buf, bd->bi_vco)); |
| 85 | print_str("sccfreq", strmhz(buf, bd->bi_sccfreq)); |
| 86 | print_str("brgfreq", strmhz(buf, bd->bi_brgfreq)); |
wdenk | 57b2d80 | 2003-06-27 21:31:46 +0000 | [diff] [blame] | 87 | #endif |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 88 | print_str("intfreq", strmhz(buf, bd->bi_intfreq)); |
Jon Loeliger | f5ad378 | 2005-07-23 10:37:35 -0500 | [diff] [blame] | 89 | #if defined(CONFIG_CPM2) |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 90 | print_str("cpmfreq", strmhz(buf, bd->bi_cpmfreq)); |
wdenk | 57b2d80 | 2003-06-27 21:31:46 +0000 | [diff] [blame] | 91 | #endif |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 92 | print_str("busfreq", strmhz(buf, bd->bi_busfreq)); |
Michal Simek | 594c7b5 | 2008-06-24 09:54:09 +0200 | [diff] [blame] | 93 | #endif /* CONFIG_405GP, CONFIG_405CR, CONFIG_405EP, CONFIG_XILINX_405, CONFIG_440EP CONFIG_440GR */ |
wdenk | 337f565 | 2004-10-28 00:09:35 +0000 | [diff] [blame] | 94 | #if defined(CONFIG_MPC8220) |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 95 | print_str("inpfreq", strmhz(buf, bd->bi_inpfreq)); |
| 96 | print_str("flbfreq", strmhz(buf, bd->bi_flbfreq)); |
| 97 | print_str("pcifreq", strmhz(buf, bd->bi_pcifreq)); |
| 98 | print_str("vcofreq", strmhz(buf, bd->bi_vcofreq)); |
| 99 | print_str("pevfreq", strmhz(buf, bd->bi_pevfreq)); |
wdenk | 337f565 | 2004-10-28 00:09:35 +0000 | [diff] [blame] | 100 | #endif |
wdenk | 0aeb853 | 2004-10-10 21:21:55 +0000 | [diff] [blame] | 101 | |
Mike Frysinger | 9335cc7 | 2009-02-11 18:50:10 -0500 | [diff] [blame] | 102 | print_eth(0); |
wdenk | 54070ab | 2004-12-31 09:32:47 +0000 | [diff] [blame] | 103 | #if defined(CONFIG_HAS_ETH1) |
Mike Frysinger | 9335cc7 | 2009-02-11 18:50:10 -0500 | [diff] [blame] | 104 | print_eth(1); |
wdenk | 0aeb853 | 2004-10-10 21:21:55 +0000 | [diff] [blame] | 105 | #endif |
wdenk | 54070ab | 2004-12-31 09:32:47 +0000 | [diff] [blame] | 106 | #if defined(CONFIG_HAS_ETH2) |
Mike Frysinger | 9335cc7 | 2009-02-11 18:50:10 -0500 | [diff] [blame] | 107 | print_eth(2); |
wdenk | 9c53f40 | 2003-10-15 23:53:47 +0000 | [diff] [blame] | 108 | #endif |
wdenk | 54070ab | 2004-12-31 09:32:47 +0000 | [diff] [blame] | 109 | #if defined(CONFIG_HAS_ETH3) |
Mike Frysinger | 9335cc7 | 2009-02-11 18:50:10 -0500 | [diff] [blame] | 110 | print_eth(3); |
wdenk | 0aeb853 | 2004-10-10 21:21:55 +0000 | [diff] [blame] | 111 | #endif |
richardretanubun | e5167f1 | 2008-09-29 18:28:23 -0400 | [diff] [blame] | 112 | #if defined(CONFIG_HAS_ETH4) |
Mike Frysinger | 9335cc7 | 2009-02-11 18:50:10 -0500 | [diff] [blame] | 113 | print_eth(4); |
richardretanubun | e5167f1 | 2008-09-29 18:28:23 -0400 | [diff] [blame] | 114 | #endif |
richardretanubun | e5167f1 | 2008-09-29 18:28:23 -0400 | [diff] [blame] | 115 | #if defined(CONFIG_HAS_ETH5) |
Mike Frysinger | 9335cc7 | 2009-02-11 18:50:10 -0500 | [diff] [blame] | 116 | print_eth(5); |
richardretanubun | e5167f1 | 2008-09-29 18:28:23 -0400 | [diff] [blame] | 117 | #endif |
| 118 | |
wdenk | 57b2d80 | 2003-06-27 21:31:46 +0000 | [diff] [blame] | 119 | #ifdef CONFIG_HERMES |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 120 | print_str("ethspeed", strmhz(buf, bd->bi_ethspeed)); |
wdenk | 57b2d80 | 2003-06-27 21:31:46 +0000 | [diff] [blame] | 121 | #endif |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 122 | printf("IP addr = %pI4\n", &bd->bi_ip_addr); |
| 123 | printf("baudrate = %6ld bps\n", bd->bi_baudrate); |
| 124 | print_num("relocaddr", gd->relocaddr); |
wdenk | 57b2d80 | 2003-06-27 21:31:46 +0000 | [diff] [blame] | 125 | return 0; |
| 126 | } |
| 127 | |
Reinhard Meyer | 0f8337b | 2010-06-06 19:01:59 +0200 | [diff] [blame] | 128 | #elif defined(CONFIG_NIOS2) |
wdenk | ef3386f | 2004-10-10 21:27:30 +0000 | [diff] [blame] | 129 | |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 130 | int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) |
wdenk | ef3386f | 2004-10-10 21:27:30 +0000 | [diff] [blame] | 131 | { |
wdenk | ef3386f | 2004-10-10 21:27:30 +0000 | [diff] [blame] | 132 | bd_t *bd = gd->bd; |
| 133 | |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 134 | print_num("mem start", (ulong)bd->bi_memstart); |
| 135 | print_lnum("mem size", (u64)bd->bi_memsize); |
| 136 | print_num("flash start", (ulong)bd->bi_flashstart); |
| 137 | print_num("flash size", (ulong)bd->bi_flashsize); |
| 138 | print_num("flash offset", (ulong)bd->bi_flashoffset); |
wdenk | ef3386f | 2004-10-10 21:27:30 +0000 | [diff] [blame] | 139 | |
Jean-Christophe PLAGNIOL-VILLARD | 0383694 | 2008-10-16 15:01:15 +0200 | [diff] [blame] | 140 | #if defined(CONFIG_SYS_SRAM_BASE) |
wdenk | ef3386f | 2004-10-10 21:27:30 +0000 | [diff] [blame] | 141 | print_num ("sram start", (ulong)bd->bi_sramstart); |
| 142 | print_num ("sram size", (ulong)bd->bi_sramsize); |
| 143 | #endif |
| 144 | |
Jon Loeliger | d704d91 | 2007-07-10 11:02:44 -0500 | [diff] [blame] | 145 | #if defined(CONFIG_CMD_NET) |
Mike Frysinger | 9335cc7 | 2009-02-11 18:50:10 -0500 | [diff] [blame] | 146 | print_eth(0); |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 147 | printf("ip_addr = %pI4\n", &bd->bi_ip_addr); |
wdenk | ef3386f | 2004-10-10 21:27:30 +0000 | [diff] [blame] | 148 | #endif |
| 149 | |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 150 | printf("baudrate = %ld bps\n", bd->bi_baudrate); |
wdenk | ef3386f | 2004-10-10 21:27:30 +0000 | [diff] [blame] | 151 | |
| 152 | return 0; |
| 153 | } |
Reinhard Meyer | 0f8337b | 2010-06-06 19:01:59 +0200 | [diff] [blame] | 154 | |
| 155 | #elif defined(CONFIG_MICROBLAZE) |
Michal Simek | 922ce20 | 2007-03-11 13:48:24 +0100 | [diff] [blame] | 156 | |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 157 | int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) |
Michal Simek | 922ce20 | 2007-03-11 13:48:24 +0100 | [diff] [blame] | 158 | { |
Michal Simek | 922ce20 | 2007-03-11 13:48:24 +0100 | [diff] [blame] | 159 | bd_t *bd = gd->bd; |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 160 | print_num("mem start ", (ulong)bd->bi_memstart); |
| 161 | print_lnum("mem size ", (u64)bd->bi_memsize); |
| 162 | print_num("flash start ", (ulong)bd->bi_flashstart); |
| 163 | print_num("flash size ", (ulong)bd->bi_flashsize); |
| 164 | print_num("flash offset ", (ulong)bd->bi_flashoffset); |
Jean-Christophe PLAGNIOL-VILLARD | 0383694 | 2008-10-16 15:01:15 +0200 | [diff] [blame] | 165 | #if defined(CONFIG_SYS_SRAM_BASE) |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 166 | print_num("sram start ", (ulong)bd->bi_sramstart); |
| 167 | print_num("sram size ", (ulong)bd->bi_sramsize); |
Michal Simek | 922ce20 | 2007-03-11 13:48:24 +0100 | [diff] [blame] | 168 | #endif |
Jon Loeliger | d704d91 | 2007-07-10 11:02:44 -0500 | [diff] [blame] | 169 | #if defined(CONFIG_CMD_NET) |
Mike Frysinger | 9335cc7 | 2009-02-11 18:50:10 -0500 | [diff] [blame] | 170 | print_eth(0); |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 171 | printf("ip_addr = %pI4\n", &bd->bi_ip_addr); |
Michal Simek | 922ce20 | 2007-03-11 13:48:24 +0100 | [diff] [blame] | 172 | #endif |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 173 | printf("baudrate = %ld bps\n", (ulong)bd->bi_baudrate); |
Michal Simek | 922ce20 | 2007-03-11 13:48:24 +0100 | [diff] [blame] | 174 | return 0; |
| 175 | } |
wdenk | 60164a8 | 2003-10-08 23:26:14 +0000 | [diff] [blame] | 176 | |
Reinhard Meyer | 0f8337b | 2010-06-06 19:01:59 +0200 | [diff] [blame] | 177 | #elif defined(CONFIG_SPARC) |
| 178 | |
Wolfgang Denk | 6262d021 | 2010-06-28 22:00:46 +0200 | [diff] [blame] | 179 | int do_bdinfo(cmd_tbl_t * cmdtp, int flag, int argc, char * const argv[]) |
Daniel Hellstrom | 83eb3cc | 2008-03-26 22:36:03 +0100 | [diff] [blame] | 180 | { |
| 181 | bd_t *bd = gd->bd; |
Daniel Hellstrom | 83eb3cc | 2008-03-26 22:36:03 +0100 | [diff] [blame] | 182 | |
| 183 | #ifdef DEBUG |
| 184 | print_num("bd address ", (ulong) bd); |
| 185 | #endif |
| 186 | print_num("memstart ", bd->bi_memstart); |
Becky Bruce | a36601e | 2008-06-09 20:37:16 -0500 | [diff] [blame] | 187 | print_lnum("memsize ", bd->bi_memsize); |
Daniel Hellstrom | 83eb3cc | 2008-03-26 22:36:03 +0100 | [diff] [blame] | 188 | print_num("flashstart ", bd->bi_flashstart); |
Jean-Christophe PLAGNIOL-VILLARD | 0383694 | 2008-10-16 15:01:15 +0200 | [diff] [blame] | 189 | print_num("CONFIG_SYS_MONITOR_BASE ", CONFIG_SYS_MONITOR_BASE); |
Jean-Christophe PLAGNIOL-VILLARD | 7e1cda6 | 2008-09-10 22:48:06 +0200 | [diff] [blame] | 190 | print_num("CONFIG_ENV_ADDR ", CONFIG_ENV_ADDR); |
Jean-Christophe PLAGNIOL-VILLARD | 0383694 | 2008-10-16 15:01:15 +0200 | [diff] [blame] | 191 | printf("CONFIG_SYS_RELOC_MONITOR_BASE = 0x%lx (%d)\n", CONFIG_SYS_RELOC_MONITOR_BASE, |
| 192 | CONFIG_SYS_MONITOR_LEN); |
| 193 | printf("CONFIG_SYS_MALLOC_BASE = 0x%lx (%d)\n", CONFIG_SYS_MALLOC_BASE, |
| 194 | CONFIG_SYS_MALLOC_LEN); |
| 195 | printf("CONFIG_SYS_INIT_SP_OFFSET = 0x%lx (%d)\n", CONFIG_SYS_INIT_SP_OFFSET, |
| 196 | CONFIG_SYS_STACK_SIZE); |
| 197 | printf("CONFIG_SYS_PROM_OFFSET = 0x%lx (%d)\n", CONFIG_SYS_PROM_OFFSET, |
| 198 | CONFIG_SYS_PROM_SIZE); |
| 199 | printf("CONFIG_SYS_GBL_DATA_OFFSET = 0x%lx (%d)\n", CONFIG_SYS_GBL_DATA_OFFSET, |
Wolfgang Denk | 0191e47 | 2010-10-26 14:34:52 +0200 | [diff] [blame] | 200 | GENERATED_GBL_DATA_SIZE); |
Daniel Hellstrom | 83eb3cc | 2008-03-26 22:36:03 +0100 | [diff] [blame] | 201 | |
| 202 | #if defined(CONFIG_CMD_NET) |
Mike Frysinger | 9335cc7 | 2009-02-11 18:50:10 -0500 | [diff] [blame] | 203 | print_eth(0); |
Mike Frysinger | d5695f4 | 2009-02-17 00:00:53 -0500 | [diff] [blame] | 204 | printf("ip_addr = %pI4\n", &bd->bi_ip_addr); |
Daniel Hellstrom | 83eb3cc | 2008-03-26 22:36:03 +0100 | [diff] [blame] | 205 | #endif |
Mike Frysinger | d5695f4 | 2009-02-17 00:00:53 -0500 | [diff] [blame] | 206 | printf("baudrate = %6ld bps\n", bd->bi_baudrate); |
Daniel Hellstrom | 83eb3cc | 2008-03-26 22:36:03 +0100 | [diff] [blame] | 207 | return 0; |
| 208 | } |
| 209 | |
Reinhard Meyer | 0f8337b | 2010-06-06 19:01:59 +0200 | [diff] [blame] | 210 | #elif defined(CONFIG_M68K) |
| 211 | |
TsiChungLiew | fc3ca3b | 2007-08-16 15:05:11 -0500 | [diff] [blame] | 212 | static void print_str(const char *, const char *); |
TsiChung Liew | f6afe72 | 2007-06-18 13:50:13 -0500 | [diff] [blame] | 213 | |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 214 | int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) |
TsiChung Liew | f6afe72 | 2007-06-18 13:50:13 -0500 | [diff] [blame] | 215 | { |
TsiChung Liew | f6afe72 | 2007-06-18 13:50:13 -0500 | [diff] [blame] | 216 | bd_t *bd = gd->bd; |
TsiChungLiew | fc3ca3b | 2007-08-16 15:05:11 -0500 | [diff] [blame] | 217 | char buf[32]; |
| 218 | |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 219 | print_num("memstart", (ulong)bd->bi_memstart); |
| 220 | print_lnum("memsize", (u64)bd->bi_memsize); |
| 221 | print_num("flashstart", (ulong)bd->bi_flashstart); |
| 222 | print_num("flashsize", (ulong)bd->bi_flashsize); |
| 223 | print_num("flashoffset", (ulong)bd->bi_flashoffset); |
Jean-Christophe PLAGNIOL-VILLARD | 0383694 | 2008-10-16 15:01:15 +0200 | [diff] [blame] | 224 | #if defined(CONFIG_SYS_INIT_RAM_ADDR) |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 225 | print_num("sramstart", (ulong)bd->bi_sramstart); |
| 226 | print_num("sramsize", (ulong)bd->bi_sramsize); |
TsiChung Liew | f6afe72 | 2007-06-18 13:50:13 -0500 | [diff] [blame] | 227 | #endif |
Jean-Christophe PLAGNIOL-VILLARD | 0383694 | 2008-10-16 15:01:15 +0200 | [diff] [blame] | 228 | #if defined(CONFIG_SYS_MBAR) |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 229 | print_num("mbar", bd->bi_mbar_base); |
TsiChungLiew | fc3ca3b | 2007-08-16 15:05:11 -0500 | [diff] [blame] | 230 | #endif |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 231 | print_str("cpufreq", strmhz(buf, bd->bi_intfreq)); |
| 232 | print_str("busfreq", strmhz(buf, bd->bi_busfreq)); |
TsiChungLiew | fc3ca3b | 2007-08-16 15:05:11 -0500 | [diff] [blame] | 233 | #ifdef CONFIG_PCI |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 234 | print_str("pcifreq", strmhz(buf, bd->bi_pcifreq)); |
TsiChung Liew | f6afe72 | 2007-06-18 13:50:13 -0500 | [diff] [blame] | 235 | #endif |
TsiChungLiew | fc3ca3b | 2007-08-16 15:05:11 -0500 | [diff] [blame] | 236 | #ifdef CONFIG_EXTRA_CLOCK |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 237 | print_str("flbfreq", strmhz(buf, bd->bi_flbfreq)); |
| 238 | print_str("inpfreq", strmhz(buf, bd->bi_inpfreq)); |
| 239 | print_str("vcofreq", strmhz(buf, bd->bi_vcofreq)); |
TsiChungLiew | fc3ca3b | 2007-08-16 15:05:11 -0500 | [diff] [blame] | 240 | #endif |
Stefan Roese | addc447 | 2007-08-18 14:37:52 +0200 | [diff] [blame] | 241 | #if defined(CONFIG_CMD_NET) |
Mike Frysinger | 9335cc7 | 2009-02-11 18:50:10 -0500 | [diff] [blame] | 242 | print_eth(0); |
TsiChung Liew | f6afe72 | 2007-06-18 13:50:13 -0500 | [diff] [blame] | 243 | #if defined(CONFIG_HAS_ETH1) |
Mike Frysinger | 9335cc7 | 2009-02-11 18:50:10 -0500 | [diff] [blame] | 244 | print_eth(1); |
TsiChung Liew | f6afe72 | 2007-06-18 13:50:13 -0500 | [diff] [blame] | 245 | #endif |
TsiChung Liew | f6afe72 | 2007-06-18 13:50:13 -0500 | [diff] [blame] | 246 | #if defined(CONFIG_HAS_ETH2) |
Mike Frysinger | 9335cc7 | 2009-02-11 18:50:10 -0500 | [diff] [blame] | 247 | print_eth(2); |
TsiChung Liew | f6afe72 | 2007-06-18 13:50:13 -0500 | [diff] [blame] | 248 | #endif |
TsiChung Liew | f6afe72 | 2007-06-18 13:50:13 -0500 | [diff] [blame] | 249 | #if defined(CONFIG_HAS_ETH3) |
Mike Frysinger | 9335cc7 | 2009-02-11 18:50:10 -0500 | [diff] [blame] | 250 | print_eth(3); |
TsiChung Liew | f6afe72 | 2007-06-18 13:50:13 -0500 | [diff] [blame] | 251 | #endif |
| 252 | |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 253 | printf("ip_addr = %pI4\n", &bd->bi_ip_addr); |
Stefan Roese | addc447 | 2007-08-18 14:37:52 +0200 | [diff] [blame] | 254 | #endif |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 255 | printf("baudrate = %ld bps\n", bd->bi_baudrate); |
TsiChung Liew | f6afe72 | 2007-06-18 13:50:13 -0500 | [diff] [blame] | 256 | |
| 257 | return 0; |
| 258 | } |
| 259 | |
Mike Frysinger | f443d3c | 2008-02-04 19:26:55 -0500 | [diff] [blame] | 260 | #elif defined(CONFIG_BLACKFIN) |
Reinhard Meyer | 0f8337b | 2010-06-06 19:01:59 +0200 | [diff] [blame] | 261 | |
Mike Frysinger | a267207 | 2008-10-20 16:15:04 -0400 | [diff] [blame] | 262 | static void print_str(const char *, const char *); |
Mike Frysinger | f443d3c | 2008-02-04 19:26:55 -0500 | [diff] [blame] | 263 | |
Wolfgang Denk | 6262d021 | 2010-06-28 22:00:46 +0200 | [diff] [blame] | 264 | int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) |
Mike Frysinger | f443d3c | 2008-02-04 19:26:55 -0500 | [diff] [blame] | 265 | { |
Mike Frysinger | f443d3c | 2008-02-04 19:26:55 -0500 | [diff] [blame] | 266 | bd_t *bd = gd->bd; |
Mike Frysinger | a267207 | 2008-10-20 16:15:04 -0400 | [diff] [blame] | 267 | char buf[32]; |
Mike Frysinger | f443d3c | 2008-02-04 19:26:55 -0500 | [diff] [blame] | 268 | |
| 269 | printf("U-Boot = %s\n", bd->bi_r_version); |
| 270 | printf("CPU = %s\n", bd->bi_cpu); |
| 271 | printf("Board = %s\n", bd->bi_board_name); |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 272 | print_str("VCO", strmhz(buf, bd->bi_vco)); |
| 273 | print_str("CCLK", strmhz(buf, bd->bi_cclk)); |
| 274 | print_str("SCLK", strmhz(buf, bd->bi_sclk)); |
Mike Frysinger | f443d3c | 2008-02-04 19:26:55 -0500 | [diff] [blame] | 275 | |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 276 | print_num("boot_params", (ulong)bd->bi_boot_params); |
| 277 | print_num("memstart", (ulong)bd->bi_memstart); |
| 278 | print_lnum("memsize", (u64)bd->bi_memsize); |
| 279 | print_num("flashstart", (ulong)bd->bi_flashstart); |
| 280 | print_num("flashsize", (ulong)bd->bi_flashsize); |
| 281 | print_num("flashoffset", (ulong)bd->bi_flashoffset); |
Mike Frysinger | f443d3c | 2008-02-04 19:26:55 -0500 | [diff] [blame] | 282 | |
Mike Frysinger | 9335cc7 | 2009-02-11 18:50:10 -0500 | [diff] [blame] | 283 | print_eth(0); |
Mike Frysinger | d5695f4 | 2009-02-17 00:00:53 -0500 | [diff] [blame] | 284 | printf("ip_addr = %pI4\n", &bd->bi_ip_addr); |
| 285 | printf("baudrate = %d bps\n", bd->bi_baudrate); |
Mike Frysinger | f443d3c | 2008-02-04 19:26:55 -0500 | [diff] [blame] | 286 | |
| 287 | return 0; |
| 288 | } |
| 289 | |
Reinhard Meyer | 0f8337b | 2010-06-06 19:01:59 +0200 | [diff] [blame] | 290 | #elif defined(CONFIG_MIPS) |
wdenk | 57b2d80 | 2003-06-27 21:31:46 +0000 | [diff] [blame] | 291 | |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 292 | int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) |
wdenk | 57b2d80 | 2003-06-27 21:31:46 +0000 | [diff] [blame] | 293 | { |
wdenk | 57b2d80 | 2003-06-27 21:31:46 +0000 | [diff] [blame] | 294 | bd_t *bd = gd->bd; |
| 295 | |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 296 | print_num("boot_params", (ulong)bd->bi_boot_params); |
| 297 | print_num("memstart", (ulong)bd->bi_memstart); |
| 298 | print_lnum("memsize", (u64)bd->bi_memsize); |
| 299 | print_num("flashstart", (ulong)bd->bi_flashstart); |
| 300 | print_num("flashsize", (ulong)bd->bi_flashsize); |
| 301 | print_num("flashoffset", (ulong)bd->bi_flashoffset); |
wdenk | 57b2d80 | 2003-06-27 21:31:46 +0000 | [diff] [blame] | 302 | |
Mike Frysinger | 9335cc7 | 2009-02-11 18:50:10 -0500 | [diff] [blame] | 303 | print_eth(0); |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 304 | printf("ip_addr = %pI4\n", &bd->bi_ip_addr); |
| 305 | printf("baudrate = %d bps\n", bd->bi_baudrate); |
wdenk | 57b2d80 | 2003-06-27 21:31:46 +0000 | [diff] [blame] | 306 | |
| 307 | return 0; |
| 308 | } |
Reinhard Meyer | 0f8337b | 2010-06-06 19:01:59 +0200 | [diff] [blame] | 309 | |
| 310 | #elif defined(CONFIG_AVR32) |
| 311 | |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 312 | int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) |
Reinhard Meyer | 0f8337b | 2010-06-06 19:01:59 +0200 | [diff] [blame] | 313 | { |
| 314 | bd_t *bd = gd->bd; |
| 315 | |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 316 | print_num("boot_params", (ulong)bd->bi_boot_params); |
| 317 | print_num("memstart", (ulong)bd->bi_memstart); |
| 318 | print_lnum("memsize", (u64)bd->bi_memsize); |
| 319 | print_num("flashstart", (ulong)bd->bi_flashstart); |
| 320 | print_num("flashsize", (ulong)bd->bi_flashsize); |
| 321 | print_num("flashoffset", (ulong)bd->bi_flashoffset); |
Reinhard Meyer | 0f8337b | 2010-06-06 19:01:59 +0200 | [diff] [blame] | 322 | |
| 323 | print_eth(0); |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 324 | printf("ip_addr = %pI4\n", &bd->bi_ip_addr); |
| 325 | printf("baudrate = %lu bps\n", bd->bi_baudrate); |
Reinhard Meyer | 0f8337b | 2010-06-06 19:01:59 +0200 | [diff] [blame] | 326 | |
| 327 | return 0; |
| 328 | } |
wdenk | 57b2d80 | 2003-06-27 21:31:46 +0000 | [diff] [blame] | 329 | |
Reinhard Meyer | 0f8337b | 2010-06-06 19:01:59 +0200 | [diff] [blame] | 330 | #elif defined(CONFIG_ARM) |
wdenk | 57b2d80 | 2003-06-27 21:31:46 +0000 | [diff] [blame] | 331 | |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 332 | int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) |
wdenk | 57b2d80 | 2003-06-27 21:31:46 +0000 | [diff] [blame] | 333 | { |
wdenk | 57b2d80 | 2003-06-27 21:31:46 +0000 | [diff] [blame] | 334 | int i; |
| 335 | bd_t *bd = gd->bd; |
| 336 | |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 337 | print_num("arch_number", bd->bi_arch_number); |
| 338 | print_num("boot_params", (ulong)bd->bi_boot_params); |
wdenk | 57b2d80 | 2003-06-27 21:31:46 +0000 | [diff] [blame] | 339 | |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 340 | for (i = 0; i < CONFIG_NR_DRAM_BANKS; ++i) { |
wdenk | 57b2d80 | 2003-06-27 21:31:46 +0000 | [diff] [blame] | 341 | print_num("DRAM bank", i); |
| 342 | print_num("-> start", bd->bi_dram[i].start); |
| 343 | print_num("-> size", bd->bi_dram[i].size); |
| 344 | } |
| 345 | |
Hebbar | e6c8528 | 2007-12-18 16:03:07 -0800 | [diff] [blame] | 346 | #if defined(CONFIG_CMD_NET) |
Mike Frysinger | 9335cc7 | 2009-02-11 18:50:10 -0500 | [diff] [blame] | 347 | print_eth(0); |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 348 | printf("ip_addr = %pI4\n", &bd->bi_ip_addr); |
Hebbar | e6c8528 | 2007-12-18 16:03:07 -0800 | [diff] [blame] | 349 | #endif |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 350 | printf("baudrate = %d bps\n", bd->bi_baudrate); |
Aneesh V | ecee9c8 | 2011-06-16 23:30:48 +0000 | [diff] [blame] | 351 | #if !(defined(CONFIG_SYS_ICACHE_OFF) && defined(CONFIG_SYS_DCACHE_OFF)) |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 352 | print_num("TLB addr", gd->tlb_addr); |
Heiko Schocher | aeb2991 | 2010-09-17 13:10:39 +0200 | [diff] [blame] | 353 | #endif |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 354 | print_num("relocaddr", gd->relocaddr); |
| 355 | print_num("reloc off", gd->reloc_off); |
| 356 | print_num("irq_sp", gd->irq_sp); /* irq stack pointer */ |
| 357 | print_num("sp start ", gd->start_addr_sp); |
| 358 | print_num("FB base ", gd->fb_base); |
wdenk | 57b2d80 | 2003-06-27 21:31:46 +0000 | [diff] [blame] | 359 | return 0; |
| 360 | } |
| 361 | |
Nobuhiro Iwamatsu | 3da00e6 | 2010-07-22 16:05:32 +0900 | [diff] [blame] | 362 | #elif defined(CONFIG_SH) |
| 363 | |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 364 | int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) |
Nobuhiro Iwamatsu | 3da00e6 | 2010-07-22 16:05:32 +0900 | [diff] [blame] | 365 | { |
| 366 | bd_t *bd = gd->bd; |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 367 | print_num("mem start ", (ulong)bd->bi_memstart); |
| 368 | print_lnum("mem size ", (u64)bd->bi_memsize); |
| 369 | print_num("flash start ", (ulong)bd->bi_flashstart); |
| 370 | print_num("flash size ", (ulong)bd->bi_flashsize); |
| 371 | print_num("flash offset ", (ulong)bd->bi_flashoffset); |
Nobuhiro Iwamatsu | 3da00e6 | 2010-07-22 16:05:32 +0900 | [diff] [blame] | 372 | |
| 373 | #if defined(CONFIG_CMD_NET) |
| 374 | print_eth(0); |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 375 | printf("ip_addr = %pI4\n", &bd->bi_ip_addr); |
Nobuhiro Iwamatsu | 3da00e6 | 2010-07-22 16:05:32 +0900 | [diff] [blame] | 376 | #endif |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 377 | printf("baudrate = %ld bps\n", (ulong)bd->bi_baudrate); |
Nobuhiro Iwamatsu | 3da00e6 | 2010-07-22 16:05:32 +0900 | [diff] [blame] | 378 | return 0; |
| 379 | } |
| 380 | |
Graeme Russ | 14917a9 | 2010-08-22 16:25:58 +1000 | [diff] [blame] | 381 | #elif defined(CONFIG_X86) |
| 382 | |
| 383 | static void print_str(const char *, const char *); |
| 384 | |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 385 | int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) |
Graeme Russ | 14917a9 | 2010-08-22 16:25:58 +1000 | [diff] [blame] | 386 | { |
| 387 | int i; |
| 388 | bd_t *bd = gd->bd; |
| 389 | char buf[32]; |
| 390 | |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 391 | print_num("boot_params", (ulong)bd->bi_boot_params); |
| 392 | print_num("bi_memstart", bd->bi_memstart); |
| 393 | print_num("bi_memsize", bd->bi_memsize); |
| 394 | print_num("bi_flashstart", bd->bi_flashstart); |
| 395 | print_num("bi_flashsize", bd->bi_flashsize); |
| 396 | print_num("bi_flashoffset", bd->bi_flashoffset); |
| 397 | print_num("bi_sramstart", bd->bi_sramstart); |
| 398 | print_num("bi_sramsize", bd->bi_sramsize); |
| 399 | print_num("bi_bootflags", bd->bi_bootflags); |
| 400 | print_str("cpufreq", strmhz(buf, bd->bi_intfreq)); |
| 401 | print_str("busfreq", strmhz(buf, bd->bi_busfreq)); |
Graeme Russ | 14917a9 | 2010-08-22 16:25:58 +1000 | [diff] [blame] | 402 | |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 403 | for (i = 0; i < CONFIG_NR_DRAM_BANKS; ++i) { |
Graeme Russ | 14917a9 | 2010-08-22 16:25:58 +1000 | [diff] [blame] | 404 | print_num("DRAM bank", i); |
| 405 | print_num("-> start", bd->bi_dram[i].start); |
| 406 | print_num("-> size", bd->bi_dram[i].size); |
| 407 | } |
| 408 | |
| 409 | #if defined(CONFIG_CMD_NET) |
| 410 | print_eth(0); |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 411 | printf("ip_addr = %pI4\n", &bd->bi_ip_addr); |
| 412 | print_str("ethspeed", strmhz(buf, bd->bi_ethspeed)); |
Graeme Russ | 14917a9 | 2010-08-22 16:25:58 +1000 | [diff] [blame] | 413 | #endif |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 414 | printf("baudrate = %d bps\n", bd->bi_baudrate); |
Graeme Russ | 14917a9 | 2010-08-22 16:25:58 +1000 | [diff] [blame] | 415 | |
| 416 | return 0; |
| 417 | } |
| 418 | |
Simon Glass | 4413ed3 | 2011-09-17 06:48:47 +0000 | [diff] [blame^] | 419 | #elif defined(CONFIG_SANDBOX) |
| 420 | |
| 421 | int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) |
| 422 | { |
| 423 | int i; |
| 424 | bd_t *bd = gd->bd; |
| 425 | |
| 426 | print_num("boot_params", (ulong)bd->bi_boot_params); |
| 427 | |
| 428 | for (i = 0; i < CONFIG_NR_DRAM_BANKS; ++i) { |
| 429 | print_num("DRAM bank", i); |
| 430 | print_num("-> start", bd->bi_dram[i].start); |
| 431 | print_num("-> size", bd->bi_dram[i].size); |
| 432 | } |
| 433 | |
| 434 | #if defined(CONFIG_CMD_NET) |
| 435 | print_eth(0); |
| 436 | printf("ip_addr = %pI4\n", &bd->bi_ip_addr); |
| 437 | #endif |
| 438 | print_num("FB base ", gd->fb_base); |
| 439 | return 0; |
| 440 | } |
| 441 | |
Reinhard Meyer | 0f8337b | 2010-06-06 19:01:59 +0200 | [diff] [blame] | 442 | #else |
| 443 | #error "a case for this architecture does not exist!" |
| 444 | #endif |
wdenk | 57b2d80 | 2003-06-27 21:31:46 +0000 | [diff] [blame] | 445 | |
| 446 | static void print_num(const char *name, ulong value) |
| 447 | { |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 448 | printf("%-12s= 0x%08lX\n", name, value); |
wdenk | 57b2d80 | 2003-06-27 21:31:46 +0000 | [diff] [blame] | 449 | } |
| 450 | |
Simon Glass | 4413ed3 | 2011-09-17 06:48:47 +0000 | [diff] [blame^] | 451 | #ifdef HAVE_PRINT_ETH |
Mike Frysinger | 9335cc7 | 2009-02-11 18:50:10 -0500 | [diff] [blame] | 452 | static void print_eth(int idx) |
| 453 | { |
| 454 | char name[10], *val; |
| 455 | if (idx) |
| 456 | sprintf(name, "eth%iaddr", idx); |
| 457 | else |
| 458 | strcpy(name, "ethaddr"); |
| 459 | val = getenv(name); |
| 460 | if (!val) |
| 461 | val = "(not set)"; |
| 462 | printf("%-12s= %s\n", name, val); |
| 463 | } |
Wolfgang Denk | 770a188 | 2009-03-29 00:54:21 +0100 | [diff] [blame] | 464 | #endif |
Mike Frysinger | 9335cc7 | 2009-02-11 18:50:10 -0500 | [diff] [blame] | 465 | |
Simon Glass | 4413ed3 | 2011-09-17 06:48:47 +0000 | [diff] [blame^] | 466 | #ifdef HAVE_PRINT_LNUM |
Becky Bruce | a36601e | 2008-06-09 20:37:16 -0500 | [diff] [blame] | 467 | static void print_lnum(const char *name, u64 value) |
| 468 | { |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 469 | printf("%-12s= 0x%.8llX\n", name, value); |
Becky Bruce | a36601e | 2008-06-09 20:37:16 -0500 | [diff] [blame] | 470 | } |
| 471 | #endif |
| 472 | |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 473 | #if defined(CONFIG_PPC) || \ |
| 474 | defined(CONFIG_M68K) || \ |
| 475 | defined(CONFIG_BLACKFIN) || \ |
| 476 | defined(CONFIG_X86) |
wdenk | 57b2d80 | 2003-06-27 21:31:46 +0000 | [diff] [blame] | 477 | static void print_str(const char *name, const char *str) |
| 478 | { |
Macpaul Lin | dfd7064 | 2011-04-27 16:28:35 +0000 | [diff] [blame] | 479 | printf("%-12s= %6s MHz\n", name, str); |
wdenk | 57b2d80 | 2003-06-27 21:31:46 +0000 | [diff] [blame] | 480 | } |
| 481 | #endif /* CONFIG_PPC */ |
| 482 | |
| 483 | |
| 484 | /* -------------------------------------------------------------------- */ |
| 485 | |
wdenk | f287a24 | 2003-07-01 21:06:45 +0000 | [diff] [blame] | 486 | U_BOOT_CMD( |
| 487 | bdinfo, 1, 1, do_bdinfo, |
Peter Tyser | dfb72b8 | 2009-01-27 18:03:12 -0600 | [diff] [blame] | 488 | "print Board Info structure", |
Wolfgang Denk | c54781c | 2009-05-24 17:06:54 +0200 | [diff] [blame] | 489 | "" |
wdenk | 57b2d80 | 2003-06-27 21:31:46 +0000 | [diff] [blame] | 490 | ); |