Imx28 U-Boot USB boot: Difference between revisions
(Initial creation) |
m (Links auto-updated for 2022 re-branding ( https://files.embeddedarm.com/ts-arm-sbc/ts-7680-linux/distributions/ts7680-latest.tar.bz2 → https://files.embeddedTS.com/ts-arm-sbc/ts-7680-linux/distributions/ts7680-latest.tar.bz2)) |
||
(3 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
By default, U-Boot will attempt to read a U-Boot script from a USB drive when the U-Boot jumper is set. It copies /tsinit.ub into memory and jumps in to the script. To make a bootable drive, create a single | By default, U-Boot will attempt to read a U-Boot script from a USB drive when the U-Boot jumper is set. It copies /tsinit.ub into memory and jumps in to the script. To make a bootable drive, create a single ext3 partition on a USB drive and unpack the rootfs tarball located [https://files.embeddedTS.com/ts-arm-sbc/ts-7680-linux/distributions/ts7680-latest.tar.bz2 here] | ||
The one addition is to create the tsinit.ub file in the root of the USB drive. In order to do this, a U-Boot script must be created and then converted to the .ub format. This process requires a set of U-Boot specific tools. These are available on most every linux distribution, the instructions below are for Debian, either run on a host PC or on the target. See the package installation documentation for other respective distributions. | The one addition is to create the tsinit.ub file in the root of the USB drive. In order to do this, a U-Boot script must be created and then converted to the .ub format. This process requires a set of U-Boot specific tools. These are available on most every linux distribution, the instructions below are for Debian, either run on a host PC or on the target. See the package installation documentation for other respective distributions. | ||
Line 23: | Line 23: | ||
load usb 0:1 ${loadaddr} /boot/uImage; | load usb 0:1 ${loadaddr} /boot/uImage; | ||
setenv bootargs root=/dev/sda1 | setenv bootargs root=/dev/sda1 ${cmdline_append}; | ||
bootm ${loadaddr} - ${fdtaddr}; | bootm ${loadaddr} - ${fdtaddr}; | ||
Latest revision as of 16:35, 17 January 2022
By default, U-Boot will attempt to read a U-Boot script from a USB drive when the U-Boot jumper is set. It copies /tsinit.ub into memory and jumps in to the script. To make a bootable drive, create a single ext3 partition on a USB drive and unpack the rootfs tarball located here
The one addition is to create the tsinit.ub file in the root of the USB drive. In order to do this, a U-Boot script must be created and then converted to the .ub format. This process requires a set of U-Boot specific tools. These are available on most every linux distribution, the instructions below are for Debian, either run on a host PC or on the target. See the package installation documentation for other respective distributions.
Install U-Boot tools in Debian
apt-get update && apt-get install u-boot-tools -y
Create the file tsinit.scr in the root of the USB drive with the linux filesystem:
# Prepare with:
# mkimage -A arm -T script -C none -n 'imx28 usb' -d tsinit.scr tsinit.ub
# DO NOT MANUALLY EDIT THE .UB FILE
if load usb 0:1 ${loadaddr} /boot/ts${model}-fpga.vme;
then fpga load 0 ${loadaddr} ${filesize};
fi;
load usb 0:1 ${fdtaddr} /boot/imx28-ts${model}.dtb;
load usb 0:1 ${loadaddr} /boot/uImage;
setenv bootargs root=/dev/sda1 ${cmdline_append};
bootm ${loadaddr} - ${fdtaddr};
Then in the same directory generate the tsinit.ub file:
mkimage -A arm -T script -C none -n 'imx28 usb' -d tsinit.scr tsinit.ub
You may need to install u-boot-tools or the equivalent package for your distribution.