U-Boot 使用

来源:互联网 发布:finale打谱软件汉化版 编辑:程序博客网 时间:2024/05/21 19:49

U-Boot Usage


This page is still a work in progress.  Please verify any information for accuracy.

Contents

 [hide] 
  • 1 Introduction
  • 2 Command Line Interface
  • 3 U-Boot Environment Variables
  • 4 bootargs
    • 4.1 Video

Introduction

Das U-Boot (U-Boot) is the open-source boot loader delivered with Texas Instruments EVMs. It performs the following functions:

  1. Initializes the EVM hardware
  2. Provides boot parameters to the Linux kernel
  3. Starts the Linux kernel

Command Line Interface

A list of the most commonly used U-Boot commands is given here. For a complete list of U-Boot commands, see chapter 5.9 of The DENX U-Boot and Linux Guide (DULG) for canyonlands.

help [command ...]
prints information about command; without arguments, it prints a short usage message for all commands.
bootm [addr [arg ...]]
boot application image stored in memory; arg is the addres of an initrd image
dhcp
invokes the DHCP client to obtain IP parameters
tftpboot [loadAddress] [[hostIPaddr:]bootfilename]
boots a kernel image over a network using the TFTP protocol
printenv [name ...]
prints the environemnt variable name; without arguments, it prints all environment variables
saveenv
saves the environment variables to persistent storage so they are not lost after a reboot
setenv name [value]
sets environment variable name to value;
if value is not specified, deletes environment variable name

U-Boot Environment Variables

A list of the most commonly used U-Boot environment variables is given here. For a complete list of U-Boot commands, see chapter 5.10 of The DENX U-Boot and Linux Guide (DULG) for canyonlands.

bootargs
These are the values passed to the Linux kernel as boot arguments.
bootcmd
This variable defines a command string that is automatically executed when the initial countdown is not interrupted. This command is only executed when the variable bootdelay is also defined.
bootdelay
The number of seconds U-Boot waits before executing the contents of bootcmd
bootfile
The name of the kernel image to load with TFTP

bootargs

A list of the most common boot arguments for TI EVMs is given here. For a more complete list of non-device specific boot args, see chapter 3 of The Linux BootPrompt-HowTo.

root=
This tells the kernel what device to use as the root file system.
For example, to boot over NFS, set
root=/dev/nfs
To boot over MMC/SD, do something like
root=/dev/mmcblk0p2
rw
This tells the kernel to mount the root file system as read/write.
nfsroot=
This tells the kernel which machine and directory to use for NFS mount, as well as the options for the root file system. More details can be found in thelinux/Documentation/nfsroot.txt file. This must also be used with the root=/dev/nfs argument.
For example
nfsroot=192.168.1.100:/home/workdir/filesystem,nolock
ip=
When mounting over NFS, the kernel must configure the network interfaces directly. Typical usage for this would be
ip=dhcp
noinitrd
When specified, this will allow the initial RAM disk to be accessed via /dev/initrd.
mem=
This specifies the amount of memory available to Linux
console=
This tells the kernel where to send the boot messages. Typical usage is to use the 1st serial port at 115200 baud with 8-bit data and no parity. For example:
console=ttyS0,115200n8

Video

video=
This tells the kernel information about how to configure the video devices. Some of the common values specifically related to TI EVMs is given here.
davincifb | omap24xxfb
This specifices the name of the framebuffer driver to use. (Pick davincifb for DaVinci parts and omap24xxfb for OMAP3 parts.)
vid[0-1]=[width x height x bpp,mem]
This specifies the size, bits per pixel and amount of memory to allocate for the frame buffer corresponding to vid0 or vid1. If using the v4l2 driver (instead of davincifb), specify this as vid0=OFF:vid1=OFF. If using the davincifb driver, you could allocate a 720x480 vid0 window with 16 bits per pixel and 2500KB of memory with
vid0=720x480x16,2500K
osd[0-1][width x height x bpp,mem]
This specifies the size, bits per pixel and amount of memory to allocate for the frame buffer corresponding to osd0 or osd1. For example, you could allocate a 720x480 osd0 window with 16 bits per pixel and 2500KB of memory with
osd0=720x480x16,2500K
rotation=n (for use with omap24xxfb only)
This specifies the amount of rotation for the framebuffer. Valid values for n are {0, 90, 180, 270}.
All values part of the video= argument should be seperated by a comma. For example, on a DaVinci device, to use the v4l2 driver for the video windows and set an OSD window, use
video=davincifb:vid0=OFF:vid1=OFF:osd0=720x480x16,2500K
dm365_imp.oper_mode=
This sets the mode for the IPIPE resizer. Set it to 0 for continuous mode and 1 for single shot mode.
davinci_capture.device_type=
This defines which driver to use. Use the following settings:
davinci_capture.device_type=0 for MT9T001davinci_capture.device_type=1 for TVP5146davinci_capture.device_type=2 for MT9T031davinci_capture.device_type=3 for MT9P031davinci_capture.device_type=4 for TVP7002
davinci_enc_mngr.ch0_output=
Valid values are:
   COMPOSITE   COMPOSITE1   SVIDEO   SVIDEO1   COMPONENT   COMPONENT1   LCD   LCD1
davinci_enc_mngr.ch0_mode=
Valid values for DaVinci are:
   NTSC   ntsc   NTSC-RGB   PAL   pal   PAL-RGB   720P-24   720P-25   720P-30   720P-50   720P-60   1080I-25   1080I-30   1080P-25   1080P-30   1080P-50   1080P-60   480P-60   576P-50   640x480   640x400   640x350   800x480
Valid values for DaVinciHD (DM6467) are:
   NTSC   NTSC-RGB   PAL   PAL-RGB   720P-25   720P-30   720P-50   720P-60   1080I-25   1080I-30   1080P-24   1080P-25   1080P-30   1080P-50   1080P-60   480P-60   576P-50   640x480   640x400   640x350
0 0
原创粉丝点击