Oliver Graute | abf0e7b | 2023-04-21 12:11:50 +0200 | [diff] [blame] | 1 | script=boot.scr |
| 2 | image=Image |
| 3 | panel=NULL |
| 4 | console=ttyLP0 |
| 5 | earlycon=lpuart32,0x5a060000 |
| 6 | fdt_addr=0x83000000 |
| 7 | boot_fdt=try |
| 8 | fdt_file=imx8qm-dmsse20-a1.dtb |
| 9 | mmcdev= __stringify(CONFIG_SYS_MMC_ENV_DEV) |
| 10 | mmcpart= __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) |
| 11 | mmcroot=/dev/mmcblk1p2 rootwait rw |
| 12 | mmcautodetect=yes |
| 13 | mmcargs=setenv bootargs console=${console},${baudrate} earlycon=${earlycon},${baudrate} root=${mmcroot} |
| 14 | loadbootscript=fatload mmc ${mmcdev}:${mmcpart} ${loadaddr} ${script}; |
| 15 | bootscript=echo Running bootscript from mmc ...; source |
| 16 | loadimage=fatload mmc ${mmcdev}:${mmcpart} ${loadaddr} ${image} |
| 17 | loadfdt=fatload mmc ${mmcdev}:${mmcpart} ${fdt_addr} ${fdt_file} |
| 18 | mmcboot=echo Booting from mmc ...; |
| 19 | run mmcargs; |
| 20 | if test ${boot_fdt} = yes || test ${boot_fdt} = try; then |
| 21 | if run loadfdt; then |
| 22 | booti ${loadaddr} - ${fdt_addr}; |
| 23 | else |
| 24 | echo WARN: Cannot load the DT; |
| 25 | fi; |
| 26 | else |
| 27 | echo wait for boot; |
| 28 | fi; |
| 29 | netargs=setenv bootargs console=${console},${baudrate} earlycon=${earlycon},${baudrate} |
| 30 | root=/dev/nfs |
| 31 | ip=dhcp mac=${ethaddr} nfsroot=${serverip}:${nfsroot},v3,tcp rw |
| 32 | netboot=echo Booting from net ...; |
| 33 | run netargs; |
| 34 | if test ${ip_dyn} = yes; then |
| 35 | setenv get_cmd dhcp; |
| 36 | else |
| 37 | setenv get_cmd tftp; |
| 38 | fi; |
| 39 | ${get_cmd} ${loadaddr} ${image}; |
| 40 | if test ${boot_fdt} = yes || test ${boot_fdt} = try; then |
| 41 | if ${get_cmd} ${fdt_addr} ${fdt_file}; then |
| 42 | booti ${loadaddr} - ${fdt_addr}; |
| 43 | else |
| 44 | echo WARN: Cannot load the DT; |
| 45 | fi; |
| 46 | else |
| 47 | booti; |
| 48 | fi; |