uboot命令


Monitor Commands - Overview:
============================


go    - start application at address 'addr'
run    - run commands in an environment variable
bootm    - boot application image from memory
bootp    - boot image via network using BootP/TFTP protocol
tftpboot- boot image via network using TFTP protocol
           and env variables "ipaddr" and "serverip"
           (and eventually "gatewayip")
rarpboot- boot image via network using RARP/TFTP protocol
diskboot- boot from IDE devicebootd   - boot default, i.e., run 'bootcmd'
loads    - load S-Record file over serial line
loadb    - load binary file over serial line (kermit mode)
md    - memory display
mm    - memory modify (auto-incrementing)
nm    - memory modify (constant address)
mw    - memory write (fill)
cp    - memory copy
cmp    - memory compare
crc32    - checksum calculation
imd    - i2c memory display
imm    - i2c memory modify (auto-incrementing)
inm    - i2c memory modify (constant address)
imw    - i2c memory write (fill)
icrc32    - i2c checksum calculation
iprobe    - probe to discover valid I2C chip addresses
iloop    - infinite loop on address range
isdram    - print SDRAM configuration information
sspi    - SPI utility commands
base    - print or set address offset
printenv- print environment variables
setenv    - set environment variables
saveenv - save environment variables to persistent storage
protect - enable or disable FLASH write protection
erase    - erase FLASH memory
flinfo    - print FLASH memory information
bdinfo    - print Board Info structure
iminfo    - print header information for application image
coninfo - print console devices and informations
ide    - IDE sub-system
loop    - infinite loop on address range
loopw    - infinite write loop on address range
mtest    - simple RAM test
icache    - enable or disable instruction cache
dcache    - enable or disable data cache
reset    - Perform RESET of the CPU
echo    - echo args to console
version - print monitor version
help    - print online help
?    - alias for 'help'


Environment Variables:
======================


U-Boot supports user configuration using Environment Variables which
can be made persistent by saving to Flash memory.

Environment Variables are set using "setenv", printed using
"printenv", and saved to Flash using "saveenv". Using "setenv"
without a value can be used to delete a variable from the
environment. As long as you don't save the environment you are
working with an in-memory copy. In case the Flash area containing the
environment is erased by accident, a default environment is provided.

Some configuration options can be set using Environment Variables:

  baudrate    - see CONFIG_BAUDRATE

  bootdelay    - see CONFIG_BOOTDELAY

  bootcmd    - see CONFIG_BOOTCOMMAND

  bootargs    - Boot arguments when booting an RTOS image

  bootfile    - Name of the image to load with TFTP

  autoload    - if set to "no" (any string beginning with 'n'),
          "bootp" will just load perform a lookup of the
          configuration from the BOOTP server, but not try to
          load any image using TFTP

  autostart    - if set to "yes", an image loaded using the "bootp",
          "rarpboot", "tftpboot" or "diskboot" commands will
          be automatically started (by internally calling
          "bootm")

          If set to "no", a standalone image passed to the
          "bootm" command will be copied to the load address
          (and eventually uncompressed), but NOT be started.
          This can be used to load and uncompress arbitrary
          data.

  i2cfast    - (PPC405GP|PPC405EP only)
          if set to 'y' configures Linux I2C driver for fast
          mode (400kHZ). This environment variable is used in
          initialization code. So, for changes to be effective
          it must be saved and board must be reset.

  initrd_high    - restrict positioning of initrd images:
          If this variable is not set, initrd images will be
          copied to the highest possible address in RAM; this
          is usually what you want since it allows for
          maximum initrd size. If for some reason you want to
          make sure that the initrd image is loaded below the
          CFG_BOOTMAPSZ limit, you can set this environment
          variable to a value of "no" or "off" or "0".
          Alternatively, you can set it to a maximum upper
          address to use (U-Boot will still check that it
          does not overwrite the U-Boot stack and data).

          For instance, when you have a system with 16 MB
          RAM, and want to reserve 4 MB from use by Linux,
          you can do this by adding "mem=12M" to the value of
          the "bootargs" variable. However, now you must make
          sure that the initrd image is placed in the first
          12 MB as well - this can be done with

          setenv initrd_high 00c00000

          If you set initrd_high to 0xFFFFFFFF, this is an
          indication to U-Boot that all addresses are legal
          for the Linux kernel, including addresses in flash
          memory. In this case U-Boot will NOT COPY the
          ramdisk at all. This may be useful to reduce the
          boot time on your system, but requires that this
          feature is supported by your Linux kernel.

  ipaddr    - IP address; needed for tftpboot command

  loadaddr    - Default load address for commands like "bootp",
          "rarpboot", "tftpboot", "loadb" or "diskboot"

  loads_echo    - see CONFIG_LOADS_ECHO

  serverip    - TFTP server IP address; needed for tftpboot command

  bootretry    - see CONFIG_BOOT_RETRY_TIME

  bootdelaykey    - see CONFIG_AUTOBOOT_DELAY_STR

  bootstopkey    - see CONFIG_AUTOBOOT_STOP_STR

  ethprime    - When CONFIG_NET_MULTI is enabled controls which
          interface is used first.

  ethact    - When CONFIG_NET_MULTI is enabled controls which
          interface is currently active. For example you
          can do the following

          => setenv ethact FEC ETHERNET
          => ping 192.168.0.1 # traffic sent on FEC ETHERNET
          => setenv ethact SCC ETHERNET
          => ping 10.0.0.1 # traffic sent on SCC ETHERNET

   netretry    - When set to "no" each network operation will
          either succeed or fail without retrying.
          When set to "once" the network operation will
          fail when all the available network interfaces
          are tried once without success.
          Useful on scripts which control the retry operation
          themselves.

  tftpsrcport    - If this is set, the value is used for TFTP's
          UDP source port.

  tftpdstport    - If this is set, the value is used for TFTP's UDP
          destination port instead of the Well Know Port 69.

   vlan        - When set to a value < 4095 the traffic over
          ethernet is encapsulated/received over 802.1q
          VLAN tagged frames.

The following environment variables may be used and automatically
updated by the network boot commands ("bootp" and "rarpboot"),
depending the information provided by your boot server:

  bootfile    - see above
  dnsip        - IP address of your Domain Name Server
  dnsip2    - IP address of your secondary Domain Name Server
  gatewayip    - IP address of the Gateway (Router) to use
  hostname    - Target hostname
  ipaddr    - see above
  netmask    - Subnet Mask
  rootpath    - Pathname of the root filesystem on the NFS server
  serverip    - see above

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值