]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
spl: Add option SPL_PAYLOAD
authorYork Sun <york.sun@nxp.com>
Thu, 14 Jun 2018 21:38:48 +0000 (14:38 -0700)
committerYork Sun <york.sun@nxp.com>
Thu, 26 Jul 2018 17:59:35 +0000 (10:59 -0700)
Some legacy boards use RAW image for SPL boot. Add Kconfig option
SPL_PAYLOAD to set alternative image.

Signed-off-by: York Sun <york.sun@nxp.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
Makefile
common/spl/Kconfig

index 79cbad22db82502725a23845f0dd8cf4693e5d53..36c145b71b8796e1c59789ef7779f3d0b8665bde 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -1111,8 +1111,8 @@ u-boot.sha1:      u-boot.bin
 u-boot.dis:    u-boot
                $(OBJDUMP) -d $< > $@
 
-ifdef CONFIG_TPL
-SPL_PAYLOAD := tpl/u-boot-with-tpl.bin
+ifneq ($(CONFIG_SPL_PAYLOAD),)
+SPL_PAYLOAD := $(CONFIG_SPL_PAYLOAD:"%"=%)
 else
 SPL_PAYLOAD := u-boot.bin
 endif
index 99c9053ab8302353681834a17720808bb885d9cd..2af26a881af05a3cec061ccdb68e5ee4eb9fa237 100644 (file)
@@ -553,6 +553,16 @@ config SYS_OS_BASE
 
 endif # SPL_OS_BOOT
 
+config SPL_PAYLOAD
+       string "SPL payload"
+       default "tpl/u-boot-with-tpl.bin" if TPL
+       default "u-boot.bin"
+       help
+         Payload for SPL boot. For backward compability, default to
+         u-boot.bin, i.e. RAW image without any header. In case of
+         TPL, tpl/u-boot-with-tpl.bin. For new boards, suggest to
+         use u-boot.img.
+
 config SPL_PCI_SUPPORT
        bool "Support PCI drivers"
        help