You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
22 lines
846 B
22 lines
846 B
# Standard Boot-Script
|
|
# use only well-known variable names provided by U-Boot Distro boot
|
|
# This script assumes that there is a boot partition,
|
|
# and that the root partition is always the next one.
|
|
|
|
# generate bootargs for rootfs on MMC
|
|
if test "${devtype}" = "mmc"; then
|
|
setexpr openwrt_rootpart ${distro_bootpart} + 1
|
|
setenv bootargs ${bootargs} root=/dev/mmcblk${devnum}p${openwrt_rootpart} rootfstype=auto rootwait
|
|
fi
|
|
|
|
# here one could add logic for other rootfs device types such as scsi and usb
|
|
|
|
# add console= option to bootargs, if any
|
|
if test -n "${console}"; then
|
|
setenv bootargs ${bootargs} console=${console}
|
|
fi
|
|
|
|
echo "Booting Linux with ${bootargs}"
|
|
load ${devtype} ${devnum}:${distro_bootpart} ${fdt_addr_r} ${fdtfile}
|
|
load ${devtype} ${devnum}:${distro_bootpart} ${kernel_addr_r} zImage
|
|
bootz ${kernel_addr_r} - ${fdt_addr_r}
|
|
|