1. 程式人生 > >[uboot]MLO和uboot-spl.bin, uboot.img和uboot.bin

[uboot]MLO和uboot-spl.bin, uboot.img和uboot.bin

mpi pict bsp with end .com eterm rmi 啟動

前段時間使用TI的am4378芯片,發現系統在SD卡啟動的時候,啟動文件使用的是MLO和uboot.img;而Norflash和eMMC啟動的時候使用的是 uboot-spl.bin和uboot.bin,有如下疑問:

1. MLO和Uboot-spl.bin有什麽區別?uboot.img和uboot.bin有什麽區別

2. 為什麽後者需要Norflash再配合eMMC,而不是直接eMMC

---------------------------------------------------------------------------------------------

For MLO use the spl/u-boot-spl.bin file. The difference between u-boot-spl.bin and MLO is that u-boot-spl.bin does not contain header information. Peripheral boot needs an MLO without header

理解:MLO只是比uboot-spl.bin多個Header,如果沒記錯的話是叫GP Header。但是問題是MLO和uboot-spl.bin是分開編譯,分別使用不同的config文件,所以MLO只是簡單的在uboot-spl.bin上加1個Header不成立,否則一次做完即可。

u-boot.bin is the binary compiled U-Boot bootloader.

u-boot.img contains u-boot.bin along with an additional header to be used by the boot ROM to determine how and where to load and execute U-Boot.

The way in which these files are deployed can depend upon the nature of your device, its boot ROM and where the files are loaded from.

Boot ROMs are generally provided by the SoC/CPU vendor.

  • These days, many boot ROMs are capable of loading u-boot.img, reading the file‘s header, loading u-boot.bin into memory and finally executing it.
  • Some boot ROMs are complex enough to load u-boot.bin directly or even the OS kernel.
  • While others may load an intermediate bootloader (MLO/X-Loader) first which then takes responsibility for loading U-Boot as the secondary bootloader once external memory is initialized.

This image depicts the latter case as implemented by some TI OMAP processors: 技術分享

This boot process is reduced by some devices by moving many of the X-Loader tasks into U-Boot and placing boot parameters (such as memory addresses) into the header of u-boot.img avoiding the need for an intermediate bootloader.

You will need to investigate the properties of your device to determine how you should go about deploying U-Boot.

理解:uboot.img只是比uboot.bin多了個頭,而這個頭包括了如何/從哪裏執行這個uboot. uboot.bin一般是按照具體地址燒寫,而uboot.img則包含地址等信息,無需按照地址下載,所以這個也決定了uboot.bin適用於Norflash,而uboot.img更適合SD卡。

[uboot]MLO和uboot-spl.bin, uboot.img和uboot.bin