]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
imx8m{m,n}_venice: update boot_net script to load fdt
authorTim Harvey <tharvey@gateworks.com>
Fri, 18 Feb 2022 23:20:17 +0000 (15:20 -0800)
committerStefano Babic <sbabic@denx.de>
Tue, 12 Apr 2022 19:08:22 +0000 (21:08 +0200)
Update the 'boot_net' script to load the fdt with the kernel.

Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Reviewed-by: Fabio Estevam <festevam@denx.de>
include/configs/imx8mm_venice.h
include/configs/imx8mn_venice.h

index 1952bde8587db5c5164015458b866a41b76cec9e..eee59a4ca57fd9e102770e784d636e18175394b8 100644 (file)
                "setexpr blkcnt $blkcnt / 0x200 && " \
                "mmc dev $dev && " \
                "mmc write $loadaddr 0x42 $blkcnt\0" \
+       "loadfdt=" \
+               "if $fsload $fdt_addr_r $dir/$fdt_file1; " \
+                       "then echo loaded $fdt_file1; " \
+               "elif $fsload $fdt_addr_r $dir/$fdt_file2; " \
+                       "then echo loaded $fdt_file2; " \
+               "elif $fsload $fdt_addr_r $dir/$fdt_file3; " \
+                       "then echo loaded $fdt_file3; " \
+               "elif $fsload $fdt_addr_r $dir/$fdt_file4; " \
+                       "then echo loaded $fdt_file4; " \
+               "elif $fsload $fdt_addr_r $dir/$fdt_file5; " \
+                       "then echo loaded $fdt_file5; " \
+               "fi\0" \
        "boot_net=" \
-               "tftpboot $kernel_addr_r $image && " \
-               "booti $kernel_addr_r - $fdtcontroladdr\0" \
+               "setenv fsload tftpboot; " \
+               "run loadfdt && tftpboot $kernel_addr_r $dir/Image && " \
+               "booti $kernel_addr_r - $fdt_addr_r\0" \
        "update_rootfs=" \
                "tftpboot $loadaddr $image && " \
                "gzwrite mmc $dev $loadaddr $filesize 100000 1000000\0" \
index d954e8e3c56ac16eec779474faedc4689362d8db..d977d3265203cae2139513cfcac55c1f05e957f1 100644 (file)
                "setexpr blkcnt $blkcnt / 0x200 && " \
                "mmc dev $dev && " \
                "mmc write $loadaddr 0x40 $blkcnt\0" \
+       "loadfdt=" \
+               "if $fsload $fdt_addr_r $dir/$fdt_file1; " \
+                       "then echo loaded $fdt_file1; " \
+               "elif $fsload $fdt_addr_r $dir/$fdt_file2; " \
+                       "then echo loaded $fdt_file2; " \
+               "elif $fsload $fdt_addr_r $dir/$fdt_file3; " \
+                       "then echo loaded $fdt_file3; " \
+               "elif $fsload $fdt_addr_r $dir/$fdt_file4; " \
+                       "then echo loaded $fdt_file4; " \
+               "elif $fsload $fdt_addr_r $dir/$fdt_file5; " \
+                       "then echo loaded $fdt_file5; " \
+               "fi\0" \
        "boot_net=" \
-               "tftpboot $kernel_addr_r $image && " \
-               "booti $kernel_addr_r - $fdtcontroladdr\0" \
+               "setenv fsload tftpboot; " \
+               "run loadfdt && tftpboot $kernel_addr_r $dir/Image && " \
+               "booti $kernel_addr_r - $fdt_addr_r\0" \
        "update_rootfs=" \
                "tftpboot $loadaddr $image && " \
                "gzwrite mmc $dev $loadaddr $filesize 100000 1000000\0" \