Skip to contentSkip to conversation

ddr: fsl: Do not allow for interactive mode in SPL

PATCH New Tom Rini 3 participants 14 messages Dec 22, 2017 – Jan 10, 2018

Subsystems (11)
lore
Share & tools
lore

Tom Rini

author
#0 lore raw

PATCH 1/3 ddr: fsl: Do not allow for interactive mode in SPL

While the code in question here is used in SPL, it cannot be used in interactive mode in SPL. We need a compile-time guard here in order to be able to not include further bits of code.

---
 drivers/ddr/fsl/main.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/ddr/fsl/main.c +1 -1
index d0a7b3f10763..b9f177f71d10 100644
@@ -633,7 +633,7 @@ phys_size_t __fsl_ddr_sdram(fsl_ddr_info_t *pinfo)
 	last_ctrl = first_ctrl + pinfo->num_ctrls - 1;
 
 	/* Compute it once normally. */
-#ifdef CONFIG_FSL_DDR_INTERACTIVE
+#if defined(CONFIG_FSL_DDR_INTERACTIVE) && !defined(CONFIG_SPL_BUILD)
 	if (tstc() && (getc() == 'd')) {	/* we got a key press of 'd' */
 		total_memory = fsl_ddr_interactive(pinfo, 0);
 	} else if (fsl_ddr_interactive_env_var_exists()) {
Signature · 1 line
2.7.4
author
#1 lore raw

PATCH 2/3 build: Drop CONFIG_SPL_BUILD guards in some cases

Given gcc-6.1 and later we can now safely have strings discarded when the functions are unused. This lets us drop certain cases of not building something so that we don't have the strings brought in when the code was discarded. Simplify the code now by dropping guards we don't need now.

Cc Stefano Babic <[email protected]>
Cc Fabio Estevam <[email protected]>
Cc Chander Kashyap <[email protected]>
Cc Thomas Abraham <[email protected]>
Cc Vipin Kumar <[email protected]>
Cc Wenyou Yang <[email protected]>
---
 arch/arm/cpu/arm1136/mx31/Makefile   | 5 +----
 arch/arm/cpu/arm1136/mx35/Makefile   | 5 +----
 arch/arm/cpu/arm926ejs/mx25/Makefile | 6 +-----
 arch/arm/cpu/arm926ejs/mx27/Makefile | 6 +-----
 arch/sandbox/lib/Makefile            | 2 --
 board/atmel/common/Makefile          | 2 --
 board/samsung/arndale/Makefile       | 3 ---
 board/samsung/espresso7420/Makefile  | 2 --
 board/spear/spear600/Makefile        | 4 +---
 9 files changed, 5 insertions(+), 30 deletions(-)
arch/arm/cpu/arm1136/mx31/Makefile +1 -4
index dcbd57065bbc..774f352ece81 100644
@@ -8,7 +8,4 @@
 obj-y	+= generic.o
 obj-y	+= timer.o
 obj-y	+= devices.o
-
-ifndef CONFIG_SPL_BUILD
-obj-y  += relocate.o
-endif
+obj-y	+= relocate.o
arch/arm/cpu/arm1136/mx35/Makefile +1 -4
index 796db9c7cc75..e4c8e2e6849a 100644
@@ -10,7 +10,4 @@
 obj-y	+= generic.o
 obj-y	+= timer.o
 obj-y	+= mx35_sdram.o
-
-ifndef CONFIG_SPL_BUILD
-obj-y  += relocate.o
-endif
+obj-y	+= relocate.o
arch/arm/cpu/arm926ejs/mx25/Makefile +1 -5
index ebc0407ef42a..7d608c608255 100644
@@ -4,8 +4,4 @@
 #
 # SPDX-License-Identifier:	GPL-2.0+
 
-obj-y	= generic.o timer.o reset.o
-
-ifndef CONFIG_SPL_BUILD
-obj-y	+= relocate.o
-endif
+obj-y	+= generic.o timer.o reset.o relocate.o
arch/arm/cpu/arm926ejs/mx27/Makefile +1 -5
index 0edf1445fe36..7d608c608255 100644
@@ -4,8 +4,4 @@
 #
 # SPDX-License-Identifier:	GPL-2.0+
 
-obj-y	= generic.o reset.o timer.o
-
-ifndef CONFIG_SPL_BUILD
-obj-y	+= relocate.o
-endif
+obj-y	+= generic.o timer.o reset.o relocate.o
arch/sandbox/lib/Makefile +0 -2
index 2e7802feac8a..a79ade7b1102 100644
@@ -8,8 +8,6 @@
 #
 
 obj-y	+= interrupts.o
-ifndef CONFIG_SPL_BUILD
 obj-$(CONFIG_PCI)	+= pci_io.o
-endif
 obj-$(CONFIG_CMD_BOOTM) += bootm.o
 obj-$(CONFIG_CMD_BOOTZ) += bootm.o
board/atmel/common/Makefile +0 -2
index 8a6850bc198b..f68dd74953ed 100644
@@ -6,7 +6,5 @@
 #
 
 obj-y += board.o
-ifndef CONFIG_SPL_BUILD
 obj-$(CONFIG_I2C_EEPROM) += mac_eeprom.o
 obj-$(CONFIG_DM_VIDEO) += video_display.o
-endif
board/samsung/arndale/Makefile +0 -3
index be2b3662ade6..01bbc0798ac9 100644
@@ -5,7 +5,4 @@
 #
 
 obj-y	+= arndale_spl.o
-
-ifndef CONFIG_SPL_BUILD
 obj-y	+= arndale.o
-endif
board/samsung/espresso7420/Makefile +0 -2
index d514dc2a457a..5248265b1f19 100644
@@ -5,6 +5,4 @@
 # SPDX-License-Identifier:	GPL-2.0+
 #
 
-ifndef CONFIG_SPL_BUILD
 obj-y	+= espresso7420.o
-endif
board/spear/spear600/Makefile +1 -3
index 7abfb9ad50ad..86a7fc4c7eda 100644
@@ -5,6 +5,4 @@
 # SPDX-License-Identifier:	GPL-2.0+
 #
 
-ifndef CONFIG_SPL_BUILD
-obj-y	:= spear600.o
-endif
+obj-y	+= spear600.o
Signature · 1 line
2.7.4
author
#2 lore raw

PATCH 2/3 build: Drop CONFIG_SPL_BUILD guards in some cases

Quoted 6 lines · Tom Rini

Given gcc-6.1 and later we can now safely have strings discarded when the functions are unused. This lets us drop certain cases of not building something so that we don't have the strings brought in when the code was discarded. Simplify the code now by dropping guards we don't need now.

Quoted 7 lines
Cc Stefano Babic <[email protected]>
Cc Fabio Estevam <[email protected]>
Cc Chander Kashyap <[email protected]>
Cc Thomas Abraham <[email protected]>
Cc Vipin Kumar <[email protected]>
Cc Wenyou Yang <[email protected]>

Applied to u-boot/master, 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/20180110/2e3f0f7e/attachment.sig>
author
#3 lore raw

PATCH 3/3 SPL: Do not include cmd lists

In reply to Tom Rini

There are no CMDs to be run in SPL and no need for any of their lists.

CC Stefano Babic <[email protected]>
Cc Fabio Estevam <[email protected]>
Cc Jagan Teki <[email protected]>
Cc Maxime Ripard <[email protected]>
Cc "Andreas Bießmann" <[email protected]>
Cc Michal Simek <[email protected]>
Cc Daniel Schwierzeck <[email protected]>
Cc Mario Six <[email protected]>
Cc Wolfgang Denk <[email protected]>
Cc York Sun <[email protected]>
Cc Simon Glass <[email protected]>
Cc Bin Meng <[email protected]>
Cc Wenyou Yang <[email protected]>
Cc Lokesh Vutla <[email protected]>
---
 arch/arm/cpu/arm1136/u-boot-spl.lds           | 3 +++
 arch/arm/cpu/arm926ejs/mxs/u-boot-spl.lds     | 3 +++
 arch/arm/cpu/arm926ejs/orion5x/u-boot-spl.lds | 3 +++
 arch/arm/cpu/arm926ejs/spear/u-boot-spl.lds   | 3 +++
 arch/arm/cpu/armv7/sunxi/u-boot-spl.lds       | 3 +++
 arch/arm/cpu/armv8/u-boot-spl.lds             | 3 +++
 arch/arm/cpu/u-boot-spl.lds                   | 3 +++
 arch/arm/mach-at91/arm926ejs/u-boot-spl.lds   | 3 +++
 arch/arm/mach-at91/armv7/u-boot-spl.lds       | 3 +++
 arch/arm/mach-omap2/u-boot-spl.lds            | 3 +++
 arch/arm/mach-zynq/u-boot-spl.lds             | 3 +++
 arch/microblaze/cpu/u-boot-spl.lds            | 3 +++
 arch/mips/cpu/u-boot-spl.lds                  | 3 +++
 arch/powerpc/cpu/mpc83xx/u-boot-spl.lds       | 3 +++
 arch/powerpc/cpu/mpc85xx/u-boot-spl.lds       | 3 +++
 arch/sandbox/cpu/u-boot-spl.lds               | 2 ++
 arch/x86/cpu/u-boot-spl.lds                   | 3 +--
 17 files changed, 48 insertions(+), 2 deletions(-)
arch/arm/cpu/arm1136/u-boot-spl.lds +3 -0
index 97e4a8bc873f..6668e2edd654 100644
@@ -19,6 +19,9 @@ OUTPUT_ARCH(arm)
 ENTRY(_start)
 SECTIONS
 {
+	/* There are no CMDs in SPL */
+	/DISCARD/ : { *(.u_boot_list_2_cmd_*) }
+
 	.text      :
 	{
 	__start = .;
arch/arm/cpu/arm926ejs/mxs/u-boot-spl.lds +3 -0
index bf2ac13056bd..d39027db23b5 100644
@@ -16,6 +16,9 @@ OUTPUT_ARCH(arm)
 ENTRY(_start)
 SECTIONS
 {
+	/* There are no CMDs in SPL */
+	/DISCARD/ : { *(.u_boot_list_2_cmd_*) }
+
 	. = CONFIG_SPL_TEXT_BASE;
 
 	. = ALIGN(4);
arch/arm/cpu/arm926ejs/orion5x/u-boot-spl.lds +3 -0
index 6f7fca07e371..150451b88fd8 100644
@@ -27,6 +27,9 @@ OUTPUT_ARCH(arm)
 ENTRY(_start)
 SECTIONS
 {
+	/* There are no CMDs in SPL */
+	/DISCARD/ : { *(.u_boot_list_2_cmd_*) }
+
 	.text      :
 	{
 		__start = .;
arch/arm/cpu/arm926ejs/spear/u-boot-spl.lds +3 -0
index 47910d3e4f82..f9af63cd14de 100644
@@ -21,6 +21,9 @@ OUTPUT_ARCH(arm)
 ENTRY(_start)
 SECTIONS
 {
+	/* There are no CMDs in SPL */
+	/DISCARD/ : { *(.u_boot_list_2_cmd_*) }
+
 	.text      :
 	{
 		__start = .;
arch/arm/cpu/armv7/sunxi/u-boot-spl.lds +3 -0
index 53f0cbd2b7ea..f9d27fa0c511 100644
@@ -24,6 +24,9 @@ OUTPUT_ARCH(arm)
 ENTRY(_start)
 SECTIONS
 {
+	/* There are no CMDs in SPL */
+	/DISCARD/ : { *(.u_boot_list_2_cmd_*) }
+
 	.text      :
 	{
 		__start = .;
arch/arm/cpu/armv8/u-boot-spl.lds +3 -0
index 0d1b0c499304..40f112237a60 100644
@@ -22,6 +22,9 @@ OUTPUT_ARCH(aarch64)
 ENTRY(_start)
 SECTIONS
 {
+	/* There are no CMDs in SPL */
+	/DISCARD/ : { *(.u_boot_list_2_cmd_*) }
+
 	.text : {
 		. = ALIGN(8);
 		*(.__image_copy_start)
arch/arm/cpu/u-boot-spl.lds +3 -0
index 65f7b68861e2..b5a89556b6b2 100644
@@ -12,6 +12,9 @@ OUTPUT_ARCH(arm)
 ENTRY(_start)
 SECTIONS
 {
+	/* There are no CMDs in SPL */
+	/DISCARD/ : { *(.u_boot_list_2_cmd_*) }
+
 	. = 0x00000000;
 
 	. = ALIGN(4);
arch/arm/mach-at91/arm926ejs/u-boot-spl.lds +3 -0
index 1b0420611ed3..186dbd88d54e 100644
@@ -15,6 +15,9 @@ OUTPUT_ARCH(arm)
 ENTRY(_start)
 SECTIONS
 {
+	/* There are no CMDs in SPL */
+	/DISCARD/ : { *(.u_boot_list_2_cmd_*) }
+
 	.text      :
 	{
 		__start = .;
arch/arm/mach-at91/armv7/u-boot-spl.lds +3 -0
index d2e41a026c4d..dffd89a78af3 100644
@@ -22,6 +22,9 @@ OUTPUT_ARCH(arm)
 ENTRY(_start)
 SECTIONS
 {
+	/* There are no CMDs in SPL */
+	/DISCARD/ : { *(.u_boot_list_2_cmd_*) }
+
 	.text      :
 	{
 		__start = .;
arch/arm/mach-omap2/u-boot-spl.lds +3 -0
index e9da2a9dd186..c70b19bdced7 100644
@@ -19,6 +19,9 @@ OUTPUT_ARCH(arm)
 ENTRY(_start)
 SECTIONS
 {
+	/* There are no CMDs in SPL */
+	/DISCARD/ : { *(.u_boot_list_2_cmd_*) }
+
 	.text      :
 	{
 		__start = .;
arch/arm/mach-zynq/u-boot-spl.lds +3 -0
index 9a59164c876f..70d0b0fab82f 100644
@@ -18,6 +18,9 @@ OUTPUT_ARCH(arm)
 ENTRY(_start)
 SECTIONS
 {
+	/* There are no CMDs in SPL */
+	/DISCARD/ : { *(.u_boot_list_2_cmd_*) }
+
 	. = ALIGN(4);
 	.text :
 	{
arch/microblaze/cpu/u-boot-spl.lds +3 -0
index c60336ca5ca8..6814aaceb562 100644
@@ -13,6 +13,9 @@ ENTRY(_start)
 
 SECTIONS
 {
+	/* There are no CMDs in SPL */
+	/DISCARD/ : { *(.u_boot_list_2_cmd_*) }
+
 	.text ALIGN(0x4):
 	{
 		__text_start = .;
arch/mips/cpu/u-boot-spl.lds +3 -0
index 07004ea11155..19444e3e600e 100644
@@ -11,6 +11,9 @@ OUTPUT_ARCH(mips)
 ENTRY(_start)
 SECTIONS
 {
+	/* There are no CMDs in SPL */
+	/DISCARD/ : { *(.u_boot_list_2_cmd_*) }
+
 	. = 0x00000000;
 
 	. = ALIGN(4);
arch/powerpc/cpu/mpc83xx/u-boot-spl.lds +3 -0
index 4101eaf3f327..66ba02ce434c 100644
@@ -10,6 +10,9 @@
 OUTPUT_ARCH(powerpc)
 SECTIONS
 {
+	/* There are no CMDs in SPL */
+	/DISCARD/ : { *(.u_boot_list_2_cmd_*) }
+
 	. = 0xfff00000;
 	.text : {
 		*(.text*)
arch/powerpc/cpu/mpc85xx/u-boot-spl.lds +3 -0
index 889a4c24001a..f959272d9703 100644
@@ -19,6 +19,9 @@ PHDRS
 #endif
 SECTIONS
 {
+	/* There are no CMDs in SPL */
+	/DISCARD/ : { *(.u_boot_list_2_cmd_*) }
+
 	. = CONFIG_SPL_TEXT_BASE;
 	.text : {
 		*(.text*)
arch/sandbox/cpu/u-boot-spl.lds +2 -0
index 7e92b4ac66c8..bd4666e2ce88 100644
@@ -8,6 +8,8 @@
 
 SECTIONS
 {
+	/* There are no CMDs in SPL */
+	/DISCARD/ : { *(.u_boot_list_2_cmd_*) }
 
 	. = ALIGN(4);
 	.u_boot_list : {
arch/x86/cpu/u-boot-spl.lds +1 -2
index 8a38d58f123d..d0c804fa829e 100644
@@ -12,9 +12,8 @@ ENTRY(_start)
 
 SECTIONS
 {
-#ifndef CONFIG_CMDLINE
+	/* There are no CMDs in SPL */
 	/DISCARD/ : { *(.u_boot_list_2_cmd_*) }
-#endif
 
 	. = CONFIG_SPL_TEXT_BASE;	/* Location of bootcode in flash */
 	__text_start = .;
Signature · 1 line
2.7.4
#4 lore raw

PATCH 3/3 SPL: Do not include cmd lists

Hi Tom,

Quoted 37 lines · Tom Rini

There are no CMDs to be run in SPL and no need for any of their lists.

CC Stefano Babic <[email protected]>
Cc Fabio Estevam <[email protected]>
Cc Jagan Teki <[email protected]>
Cc Maxime Ripard <[email protected]>
Cc "Andreas Bießmann" <[email protected]>
Cc Michal Simek <[email protected]>
Cc Daniel Schwierzeck <[email protected]>
Cc Mario Six <[email protected]>
Cc Wolfgang Denk <[email protected]>
Cc York Sun <[email protected]>
Cc Simon Glass <[email protected]>
Cc Bin Meng <[email protected]>
Cc Wenyou Yang <[email protected]>
Cc Lokesh Vutla <[email protected]>
---
 arch/arm/cpu/arm1136/u-boot-spl.lds           | 3 +++
 arch/arm/cpu/arm926ejs/mxs/u-boot-spl.lds     | 3 +++
 arch/arm/cpu/arm926ejs/orion5x/u-boot-spl.lds | 3 +++
 arch/arm/cpu/arm926ejs/spear/u-boot-spl.lds   | 3 +++
 arch/arm/cpu/armv7/sunxi/u-boot-spl.lds       | 3 +++
 arch/arm/cpu/armv8/u-boot-spl.lds             | 3 +++
 arch/arm/cpu/u-boot-spl.lds                   | 3 +++
 arch/arm/mach-at91/arm926ejs/u-boot-spl.lds   | 3 +++
 arch/arm/mach-at91/armv7/u-boot-spl.lds       | 3 +++
 arch/arm/mach-omap2/u-boot-spl.lds            | 3 +++
 arch/arm/mach-zynq/u-boot-spl.lds             | 3 +++
 arch/microblaze/cpu/u-boot-spl.lds            | 3 +++
 arch/mips/cpu/u-boot-spl.lds                  | 3 +++
 arch/powerpc/cpu/mpc83xx/u-boot-spl.lds       | 3 +++
 arch/powerpc/cpu/mpc85xx/u-boot-spl.lds       | 3 +++
 arch/sandbox/cpu/u-boot-spl.lds               | 2 ++
 arch/x86/cpu/u-boot-spl.lds                   | 3 +--
 17 files changed, 48 insertions(+), 2 deletions(-)

...

Quoted 5 lines
arch/mips/cpu/u-boot-spl.lds +0 -0
index 07004ea11155..19444e3e600e 100644

arch/mips/cpu/u-boot-spl.lds OUTPUT_ARCH(mips) · line 19

Quoted 9 lines
arch/mips/cpu/u-boot-spl.lds +3 -0
@@ -11,6 +11,9 @@ OUTPUT_ARCH(mips)
 ENTRY(_start)
 SECTIONS
 {
+	/* There are no CMDs in SPL */
+	/DISCARD/ : { *(.u_boot_list_2_cmd_*) }
+
 	. = 0x00000000;
 
 	. = ALIGN(4);

does a DISCARD() work together with the KEEP() in this block?

#ifdef CONFIG_SPL_DM
	. = ALIGN(4);
	.u_boot_list : {
		KEEP(*(SORT(.u_boot_list*)));
	} > .spl_mem

#endif

I suggest to do something like this:

		KEEP(*(SORT(.u_boot_list_2_uclass*)));
		KEEP(*(SORT(.u_boot_list_2_driver*)));

Then all u_boot_list_* would be discarded by default except the two lists above when a board selects CONFIG_SPL_DM. Also this would have the benefit of discarding all u_boot_list_2_env* entries.

Signature · 9 lines
- Daniel

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: OpenPGP digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20171222/5dfff4d2/attachment.sig>
author
#5 lore raw

PATCH 3/3 SPL: Do not include cmd lists

Quoted 4 lines · Daniel Schwierzeck

Hi Tom,

Quoted 1 line · Tom Rini

There are no CMDs to be run in SPL and no need for any of their lists.

[snip]

Quoted 17 lines
Quoted 5 lines
arch/mips/cpu/u-boot-spl.lds +0 -0
index 07004ea11155..19444e3e600e 100644

arch/mips/cpu/u-boot-spl.lds OUTPUT_ARCH(mips) · line 19

Quoted 9 lines
arch/mips/cpu/u-boot-spl.lds +3 -0
@@ -11,6 +11,9 @@ OUTPUT_ARCH(mips)
 ENTRY(_start)
 SECTIONS
 {
+	/* There are no CMDs in SPL */
+	/DISCARD/ : { *(.u_boot_list_2_cmd_*) }
+
 	. = 0x00000000;
 
 	. = ALIGN(4);

does a DISCARD() work together with the KEEP() in this block?

Quoted 6 lines
#ifdef CONFIG_SPL_DM
	. = ALIGN(4);
	.u_boot_list : {
		KEEP(*(SORT(.u_boot_list*)));
	} > .spl_mem

#endif

Yes, we discard th cmd list, and then keep the rest, given the ordering.

Quoted 8 lines

I suggest to do something like this:

		KEEP(*(SORT(.u_boot_list_2_uclass*)));
		KEEP(*(SORT(.u_boot_list_2_driver*)));

Then all u_boot_list_* would be discarded by default except the two lists above when a board selects CONFIG_SPL_DM. Also this would have the benefit of discarding all u_boot_list_2_env* entries.

Ah, but this shows why we glob in all lists today. We do need env in SPL at times. Now, it shouldn't take up space in SPL if we don't ahve SPL_ENV_SUPPORT. But I haven't checked either...

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/20171222/e33a8740/attachment.sig>
#6 lore raw

PATCH 3/3 SPL: Do not include cmd lists

In reply to Tom Rini
Quoted 28 lines · Tom Rini

There are no CMDs to be run in SPL and no need for any of their lists.

CC Stefano Babic <[email protected]>
Cc Fabio Estevam <[email protected]>
Cc Jagan Teki <[email protected]>
Cc Maxime Ripard <[email protected]>
Cc "Andreas Bießmann" <[email protected]>
Cc Michal Simek <[email protected]>
Cc Daniel Schwierzeck <[email protected]>
Cc Mario Six <[email protected]>
Cc Wolfgang Denk <[email protected]>
Cc York Sun <[email protected]>
Cc Simon Glass <[email protected]>
Cc Bin Meng <[email protected]>
Cc Wenyou Yang <[email protected]>
Cc Lokesh Vutla <[email protected]>
---
 arch/arm/cpu/arm1136/u-boot-spl.lds           | 3 +++
 arch/arm/cpu/arm926ejs/mxs/u-boot-spl.lds     | 3 +++
 arch/arm/cpu/arm926ejs/orion5x/u-boot-spl.lds | 3 +++
 arch/arm/cpu/arm926ejs/spear/u-boot-spl.lds   | 3 +++
 arch/arm/cpu/armv7/sunxi/u-boot-spl.lds       | 3 +++
 arch/arm/cpu/armv8/u-boot-spl.lds             | 3 +++
 arch/arm/cpu/u-boot-spl.lds                   | 3 +++
 arch/arm/mach-at91/arm926ejs/u-boot-spl.lds   | 3 +++
 arch/arm/mach-at91/armv7/u-boot-spl.lds       | 3 +++
 arch/arm/mach-omap2/u-boot-spl.lds            | 3 +++
Quoted 9 lines
 arch/arm/mach-zynq/u-boot-spl.lds             | 3 +++
 arch/microblaze/cpu/u-boot-spl.lds            | 3 +++
 arch/mips/cpu/u-boot-spl.lds                  | 3 +++
 arch/powerpc/cpu/mpc83xx/u-boot-spl.lds       | 3 +++
 arch/powerpc/cpu/mpc85xx/u-boot-spl.lds       | 3 +++
 arch/sandbox/cpu/u-boot-spl.lds               | 2 ++
 arch/x86/cpu/u-boot-spl.lds                   | 3 +--
 17 files changed, 48 insertions(+), 2 deletions(-)

for MIPS

Signature · 9 lines
- Daniel

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: OpenPGP digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20171222/b43addc7/attachment.sig>
author
#7 lore raw

PATCH 3/3 SPL: Do not include cmd lists

In reply to Tom Rini
Quoted 17 lines · Tom Rini

There are no CMDs to be run in SPL and no need for any of their lists.

CC Stefano Babic <[email protected]>
Cc Fabio Estevam <[email protected]>
Cc Jagan Teki <[email protected]>
Cc Maxime Ripard <[email protected]>
Cc "Andreas Bießmann" <[email protected]>
Cc Michal Simek <[email protected]>
Cc Daniel Schwierzeck <[email protected]>
Cc Mario Six <[email protected]>
Cc Wolfgang Denk <[email protected]>
Cc York Sun <[email protected]>
Cc Simon Glass <[email protected]>
Cc Bin Meng <[email protected]>
Cc Wenyou Yang <[email protected]>
Cc Lokesh Vutla <[email protected]>

So, discarding doesn't cause everything that could be garbage collected to be garbage collected in this case (and I don't think that's really a bug). So I'm withdrawing this patch as well, 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/20171222/bb6175da/attachment.sig>
#8 lore raw

PATCH 1/3 ddr: fsl: Do not allow for interactive mode in SPL

In reply to Tom Rini

Why not? I used it before.

York

Sent from my iPhone

Quoted 28 lines · Tom Rini

While the code in question here is used in SPL, it cannot be used in interactive mode in SPL. We need a compile-time guard here in order to be able to not include further bits of code.

---
drivers/ddr/fsl/main.c | 2 +-

1 file changed, 1 insertion(+), 1 deletion(-)
drivers/ddr/fsl/main.c +1 -1
index d0a7b3f10763..b9f177f71d10 100644
@@ -633,7 +633,7 @@ phys_size_t __fsl_ddr_sdram(fsl_ddr_info_t *pinfo)
   last_ctrl = first_ctrl + pinfo->num_ctrls - 1;
 
   /* Compute it once normally. */
-#ifdef CONFIG_FSL_DDR_INTERACTIVE
+#if defined(CONFIG_FSL_DDR_INTERACTIVE) && !defined(CONFIG_SPL_BUILD)
   if (tstc() && (getc() == 'd')) {    /* we got a key press of 'd' */
       total_memory = fsl_ddr_interactive(pinfo, 0);
   } else if (fsl_ddr_interactive_env_var_exists()) {
Signature · 1 line
2.7.4
author
#9 lore raw

PATCH 1/3 ddr: fsl: Do not allow for interactive mode in SPL

Quoted 1 line · York Sun

Why not? I used it before.

In SPL, rather than full U-Boot?

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/20171222/0065a5de/attachment.sig>
#10 lore raw

PATCH 1/3 ddr: fsl: Do not allow for interactive mode in SPL

If SPL is used, the full driver is in SPL. It initializes DDR. It only makes sense to have this feature there, not after relocation. We only disable this feature is the SPL size becomes a problem.

York

Sent from my iPhone

Quoted 10 lines · Tom Rini
Quoted 4 lines · York Sun

Why not? I used it before.

In SPL, rather than full U-Boot?

Signature · 1 line
Tom
author
#11 lore raw

PATCH 1/3 ddr: fsl: Do not allow for interactive mode in SPL

Quoted 3 lines · York Sun

If SPL is used, the full driver is in SPL. It initializes DDR. It only makes sense to have this feature there, not after relocation. We only disable this feature is the SPL size becomes a problem.

OK, but I don't understand how you can get into that specific hunk of code. Is someone sending 'd' to the UART and that causes this code to run? 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/20171222/cabc9323/attachment.sig>
#12 lore raw

PATCH 1/3 ddr: fsl: Do not allow for interactive mode in SPL

Either sending 'd' through UART, or save a variable ddr_interactive.

York

Sent from my iPhone

Quoted 14 lines · Tom Rini
Quoted 6 lines · York Sun

If SPL is used, the full driver is in SPL. It initializes DDR. It only makes sense to have this feature there, not after relocation. We only disable this feature is the SPL size becomes a problem.

OK, but I don't understand how you can get into that specific hunk of code. Is someone sending 'd' to the UART and that causes this code to run? Thanks!

Signature · 1 line
Tom
author
#13 lore raw

PATCH 1/3 ddr: fsl: Do not allow for interactive mode in SPL

Quoted 1 line · York Sun

Either sending 'd' through UART, or save a variable ddr_interactive.

OK, thanks, withdrawn!

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/20171222/ee6b0f79/attachment.sig>