1 if test ${boot_dev} = ""; then
3 setenv root_dev /dev/mmcblk0p3;
6 if test ${dev_num} = ""; then
10 if test ${boot_part} = ""; then
11 setenv boot_part ${dev_num}:1;
14 if test ${cpu} = "armv8"; then
17 setenv kernel_type -multi;
21 if fatload ${boot_dev} ${boot_part} ${kernel_addr_r} uEnv.txt; then
22 echo Load uEnv.txt...;
23 env import -t ${kernel_addr_r} ${filesize};
24 if test "${uenvcmd}" = ""; then
27 echo Boot with uEnv.txt...;
32 # for compatiblity reasons set DTBSUNXI if we run on sunxi
33 if test "${board}" = "sunxi"; then
34 setenv fdtfile ${DTBSUNXI};
37 # Quirk for RPi on aarch64 becuase u-boot cannot use the
38 # initrd on aarch64 and without ramdisk no UUID
39 if test ${cpu} = "armv8"; then
40 if test ${board} = "rpi"; then
41 setenv root_dev /dev/mmcblk0p3;
45 # Check if serial console is enabled
46 if test "${SERIAL-CONSOLE}" = "ON"; then
47 if test ${console} = ""; then
48 if test "${board}" = "rpi"; then
49 if test ${cpu} = "armv8"; then
50 if test "${fdtfile}" = "broadcom/bcm2837-rpi-3-b-plus.dtb"; then
51 setenv console ttyS1,115200n8;
53 if test "${fdtfile}" = "broadcom/bcm2837-rpi-3-b.dtb"; then
54 setenv console ttyS1,115200n8;
56 setenv console ttyAMA0,115200n8;
60 if test "${fdtfile}" = "bcm2837-rpi-3-b-plus.dtb"; then
61 setenv console ttyS1,115200n8;
63 if test "${fdtfile}" = "bcm2837-rpi-3-b.dtb"; then
64 setenv console ttyS1,115200n8;
66 setenv console ttyAMA0,115200n8;
71 setenv console ttyS0,115200n8;
74 echo Set console to ${console};
75 setenv bootargs console=${console} root=${root_dev} rootwait;
77 echo Set console to tty1 ;
78 setenv bootargs console=tty1 root=${root_dev} rootwait;
81 setenv fdt_high ffffffff;
82 fatload ${boot_dev} ${boot_part} ${kernel_addr_r} vmlinuz-${KVER}-ipfire${kernel_type};
83 fatload ${boot_dev} ${boot_part} ${fdt_addr_r} dtb-${KVER}-ipfire${kernel_type}/${fdtfile};
85 if test "${FDTCMDS}" = ""; then
88 fdt addr ${fdt_addr_r};
92 setenv ramdisk_addr ${ramdisk_addr_r}
93 if fatload ${boot_dev} ${boot_part} ${ramdisk_addr} uInit-${KVER}-ipfire${kernel_type}; then
94 echo Ramdisk loaded...;
96 echo Ramdisk not loaded...;
97 setenv ramdisk_addr -;
100 # Quirk for RPi on aarch64 becuase u-boot cannot use the
102 if test ${cpu} = "armv8"; then
103 if test ${board} = "rpi"; then
104 setenv ramdisk_addr -;
108 bootz ${kernel_addr_r} ${ramdisk_addr} ${fdt_addr_r};
109 booti ${kernel_addr_r} ${ramdisk_addr} ${fdt_addr_r};
111 bootz ${kernel_addr_r} - ${fdt_addr_r};
112 booti ${kernel_addr_r} - ${fdt_addr_r};
115 # mkimage -C none -A arm -T script -d /boot/boot.cmd /boot/boot.scr