
Introduce common Kconfig symbol for riscv architecture. This symbol SPL_LOAD_FIT_OPENSBI_OS_BOOT is like falcon mode on ARM, the Falcon boot is a shortcut boot method for SD/eMMC targets. It skips the loading the RAM version U-Boot. Instead, it will loads the FIT image and boots directly to Linux.
When SPL_OPENSBI_OS_BOOT is enabled, linux.itb is created after compilation instead of the default u-boot.itb. It initialises memory with the U-Boot SPL at the first stage, just as a normal boot process does at the beginning. Instead of jumping to the U-Boot proper from OpenSBI before booting the Linux kernel, the RISC-V falcon mode process jumps directly to the Linux kernel to gain shorter booting time.
When SPL_OPENSBI_OS_BOOT is enabled, it will change the default FIT configure file "binman.dtsi" to "binman_linux.dtsi" Default is not enabled.
Signed-off-by: Randolph randolph@andestech.com --- arch/riscv/Kconfig | 9 +++++++++ 1 file changed, 9 insertions(+)
diff --git a/arch/riscv/Kconfig b/arch/riscv/Kconfig index ec1cfcaaa7..4f104789a7 100644 --- a/arch/riscv/Kconfig +++ b/arch/riscv/Kconfig @@ -422,8 +422,17 @@ config TPL_USE_ARCH_MEMSET
endmenu
+config SPL_LOAD_FIT_OPENSBI_OS_BOOT + bool "Enable SPL (OpenSBI OS boot mode) applying linux from FIT" + depends on SPL_LOAD_FIT + help + Use fw_dynamic from the FIT image, and u-boot SPL will invoke it directly. + This is a shortcut boot flow, from u-boot SPL -> OpenSBI -> u-boot proper + -> linux to u-boot SPL -> OpenSBI -> linux. + config SPL_LOAD_FIT_CONFIG string "Default FIT configuration for SPL" + default "binman_linux.dtsi" if SPL_LOAD_FIT_OPENSBI_OS_BOOT default "binman.dtsi" depends on SPL_LOAD_FIT help