Andrew Davis | 9d75eee | 2023-07-25 13:15:21 -0500 | [diff] [blame] | 1 | name_fw_rd=k2-fw-initrd.cpio.gz |
| 2 | set_rd_spec=setenv rd_spec ${rdaddr}:${filesize} |
| 3 | init_fw_rd_net=dhcp ${rdaddr} ${tftp_root}/${name_fw_rd}; run set_rd_spec |
| 4 | init_fw_rd_nfs=nfs ${rdaddr} ${nfs_root}/boot/${name_fw_rd}; run set_rd_spec |
| 5 | init_fw_rd_ramfs=setenv rd_spec - |
| 6 | init_fw_rd_ubi=ubifsload ${rdaddr} ${bootdir}/${name_fw_rd}; run set_rd_spec |
| 7 | |
| 8 | dfu_bufsiz=0x10000 |
| 9 | dfu_alt_info_mmc= |
| 10 | MLO fat 0 1; |
| 11 | u-boot.img fat 0 1; |
| 12 | uEnv.txt fat 0 1 |
| 13 | |
| 14 | bootdir=/boot |
| 15 | tftp_root=/ |
| 16 | nfs_root=/export |
| 17 | mem_lpae=1 |
| 18 | uinitrd_fixup=1 |
| 19 | addr_ubi=0x82000000 |
| 20 | addr_secdb_key=0xc000000 |
| 21 | name_kern=zImage |
| 22 | addr_mon=0x87000000 |
| 23 | addr_non_sec_mon=0x0c097fc0 |
| 24 | addr_load_sec_bm=0x0c09c000 |
| 25 | run_mon=mon_install ${addr_mon} |
| 26 | run_mon_hs=mon_install ${addr_non_sec_mon} ${addr_load_sec_bm} |
| 27 | run_kern=bootz ${loadaddr} ${rd_spec} ${fdtaddr} |
| 28 | init_net=run args_all args_net |
| 29 | init_nfs=setenv autoload no; dhcp; run args_all args_net |
| 30 | init_ubi=run args_all args_ubi; ubi part ubifs; ubifsmount ubi:rootfs; |
| 31 | get_fdt_net=dhcp ${fdtaddr} ${tftp_root}/${name_fdt} |
| 32 | get_fdt_nfs=nfs ${fdtaddr} ${nfs_root}/boot/${name_fdt} |
| 33 | get_fdt_ubi=ubifsload ${fdtaddr} ${bootdir}/${name_fdt} |
| 34 | get_kern_net=dhcp ${loadaddr} ${tftp_root}/${name_kern} |
| 35 | get_kern_nfs=nfs ${loadaddr} ${nfs_root}/boot/${name_kern} |
| 36 | get_kern_ubi=ubifsload ${loadaddr} ${bootdir}/${name_kern} |
| 37 | get_mon_net=dhcp ${addr_mon} ${tftp_root}/${name_mon} |
| 38 | get_mon_nfs=nfs ${addr_mon} ${nfs_root}/boot/${name_mon} |
| 39 | get_mon_ubi=ubifsload ${addr_mon} ${bootdir}/${name_mon} |
| 40 | get_fit_net=dhcp ${addr_fit} ${tftp_root}/${name_fit} |
| 41 | get_fit_nfs=nfs ${addr_fit} ${nfs_root}/boot/${name_fit} |
| 42 | get_fit_ubi=ubifsload ${addr_fit} ${bootdir}/${name_fit} |
| 43 | get_fit_mmc=load mmc ${bootpart} ${addr_fit} ${bootdir}/${name_fit} |
| 44 | get_uboot_net=dhcp ${loadaddr} ${tftp_root}/${name_uboot} |
| 45 | get_uboot_nfs=nfs ${loadaddr} ${nfs_root}/boot/${name_uboot} |
| 46 | burn_uboot_spi=sf probe; sf erase 0 0x100000; sf write ${loadaddr} 0 ${filesize} |
| 47 | burn_uboot_nand=nand erase 0 0x100000; nand write ${loadaddr} 0 ${filesize} |
| 48 | args_all=setenv bootargs console=ttyS0,115200n8 rootwait |
| 49 | args_net=setenv bootargs ${bootargs} rootfstype=nfs root=/dev/nfs rw nfsroot=${serverip}:${nfs_root},${nfs_options} ip=dhcp |
| 50 | nfs_options=v3,tcp,rsize=4096,wsize=4096 |
| 51 | get_fdt_ramfs=dhcp ${fdtaddr} ${tftp_root}/${name_fdt} |
| 52 | get_kern_ramfs=dhcp ${loadaddr} ${tftp_root}/${name_kern} |
| 53 | get_mon_ramfs=dhcp ${addr_mon} ${tftp_root}/${name_mon} |
| 54 | get_fit_ramfs=dhcp ${addr_fit} ${tftp_root}/${name_fit} |
| 55 | get_fs_ramfs=dhcp ${rdaddr} ${tftp_root}/${name_fs} |
| 56 | get_ubi_net=dhcp ${addr_ubi} ${tftp_root}/${name_ubi} |
| 57 | get_ubi_nfs=nfs ${addr_ubi} ${nfs_root}/boot/${name_ubi} |
| 58 | burn_ubi=nand erase.part ubifs; nand write ${addr_ubi} ubifs ${filesize} |
| 59 | init_ramfs=run args_all args_ramfs get_fs_ramfs |
| 60 | args_ramfs=setenv bootargs ${bootargs} rdinit=/sbin/init rw root=/dev/ram0 initrd=0x808080000,80M |
| 61 | no_post=1 |