Skip to contentSkip to conversation

spl: Add option SPL_PAYLOAD

RFC PATCH New York Sun 2 participants 4 messages Jun 14, 2018 – Jul 27, 2018 Kbuild

lore
Share & tools
lore

York Sun

author
#0 lore raw

RFC PATCH 1/1 spl: Add option SPL_PAYLOAD

Some legacy boards use RAW image for SPL boot. Add Kconfig option SPL_PAYLOAD to set alternative image.

---

 Makefile           |  4 ++--
 common/spl/Kconfig | 10 ++++++++++
 2 files changed, 12 insertions(+), 2 deletions(-)
Makefile +2 -2
index 6a190e7..36459f1 100644
@@ -1115,8 +1115,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
common/spl/Kconfig +10 -0
index 1f14797..72b77d7 100644
@@ -552,6 +552,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
Signature · 1 line
2.7.4
author
#1 lore raw

RFC PATCH 1/1 spl: Add option SPL_PAYLOAD

Quoted 38 lines · York Sun

Some legacy boards use RAW image for SPL boot. Add Kconfig option SPL_PAYLOAD to set alternative image.

---

 Makefile           |  4 ++--
 common/spl/Kconfig | 10 ++++++++++
 2 files changed, 12 insertions(+), 2 deletions(-)
Makefile +2 -2
index 6a190e7..36459f1 100644
@@ -1115,8 +1115,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
common/spl/Kconfig +3 -0
index 1f14797..72b77d7 100644
@@ -552,6 +552,16 @@ config SYS_OS_BASE
 
 endif # SPL_OS_BOOT
 
+config SPL_PAYLOAD
+	string "SPL payload"
+	default "tpl/u-boot-with-tpl.bin" if TPL

common/spl/Kconfig config SYS_OS_BASE · line 567

Quoted 10 lines
common/spl/Kconfig +7 -0
+	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

Any comment?

York

#2 lore raw

RFC PATCH 1/1 spl: Add option SPL_PAYLOAD

Quoted 35 lines · York Sun
Quoted 34 lines · York Sun

Some legacy boards use RAW image for SPL boot. Add Kconfig option SPL_PAYLOAD to set alternative image.

---

 Makefile           |  4 ++--
 common/spl/Kconfig | 10 ++++++++++
 2 files changed, 12 insertions(+), 2 deletions(-)
Makefile +2 -2
index 6a190e7..36459f1 100644
@@ -1115,8 +1115,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
common/spl/Kconfig +0 -0
index 1f14797..72b77d7 100644
@@ -552,6 +552,16 @@ config SYS_OS_BASE
 
 endif # SPL_OS_BOOT
 
Quoted 16 lines
Quoted 4 lines
common/spl/Kconfig +3 -0
+config SPL_PAYLOAD
+	string "SPL payload"
+	default "tpl/u-boot-with-tpl.bin" if TPL

common/spl/Kconfig config SYS_OS_BASE · line 567

Quoted 10 lines
common/spl/Kconfig +7 -0
+	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

Any comment?

And feel free to take it via your tree with other patches if needed, thanks!

Signature · 8 lines
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20180709/8316f035/attachment.sig>
author Applied
#3 lore raw

RFC PATCH 1/1 spl: Add option SPL_PAYLOAD

In reply to York Sun
Quoted 6 lines · York Sun

Some legacy boards use RAW image for SPL boot. Add Kconfig option SPL_PAYLOAD to set alternative image.

---

Applied to fsl-qoriq, awaiting upstream.

York