]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
riscv: dts: binman: add condition for opensbi os boot
authorRandolph <randolph@andestech.com>
Thu, 12 Oct 2023 06:35:05 +0000 (14:35 +0800)
committerLeo Yu-Chi Liang <ycliang@andestech.com>
Thu, 19 Oct 2023 09:29:33 +0000 (17:29 +0800)
Add condition for OpenSBI OS boot mode, by default it is not enabled.
By default, binman creates the output file u-boot.itb.
If SPL_OPENSBI_OS_BOOT is enabled, linux.itb will be created
after compilation instead of the default u-boot.itb.

Signed-off-by: Randolph <randolph@andestech.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
arch/riscv/dts/binman.dtsi

index b448b2a712b1fd9107412a3ad54fbb021f16591b..6b4eb8dc7b9c9f21654c6cd7c0acb1c2c0875945 100644 (file)
 
 &binman {
        itb {
+
+#ifndef CONFIG_SPL_LOAD_FIT_OPENSBI_OS_BOOT
                filename = "u-boot.itb";
+#else
+               filename = "linux.itb";
+#endif
 
                fit {
                        description = "Configuration to load OpenSBI before U-Boot";
@@ -24,6 +29,7 @@
                        fit,fdt-list = "of-list";
 
                        images {
+#ifndef CONFIG_SPL_LOAD_FIT_OPENSBI_OS_BOOT
                                uboot {
                                        description = "U-Boot";
                                        type = "standalone";
                                                filename = "u-boot-nodtb.bin";
                                        };
                                };
+#else
+                               linux {
+                                       description = "Linux";
+                                       type = "standalone";
+                                       os = "Linux";
+                                       arch = "riscv";
+                                       compression = "none";
+                                       load = <CONFIG_TEXT_BASE>;
+
+                                       linux_blob: blob-ext {
+                                               filename = "Image";
+                                       };
+                               };
+#endif
 
                                opensbi {
                                        description = "OpenSBI fw_dynamic Firmware";
 #endif
                                        description = "NAME";
                                        firmware = "opensbi";
+#ifndef CONFIG_SPL_LOAD_FIT_OPENSBI_OS_BOOT
                                        loadables = "uboot";
+#else
+                                       loadables = "linux";
+#endif
 #ifndef CONFIG_OF_BOARD
                                        fdt = "fdt-SEQ";
 #endif