diff mbox

[U-Boot,PATCHv2] check u-boot SPL size to avoid producing non-working images

Message ID 20160528194124.GA27144@amd
State Changes Requested
Delegated to: Wolfgang Denk
Headers show

Commit Message

Pavel Machek May 28, 2016, 7:41 p.m. UTC
Debugging SPL is hard, and if SPL is too big, it tends to crash in
mysterious ways.

(I'm not sure what the exact threshold is, 49762 bytes works, 52426
bytes does not, so 50000 should be good value).

Signed-off-by: Pavel Machek <pavel@denx.de>

---

> Please use CONFIG_SPL_MAX_*

Ok, that's simple enough. It computes the size different way, thus the
different number.

Comments

Wolfgang Denk May 30, 2016, 8:10 p.m. UTC | #1
Dear Pavel,

In message <20160528194124.GA27144@amd> you wrote:
> Debugging SPL is hard, and if SPL is too big, it tends to crash in
> mysterious ways.
> 
> (I'm not sure what the exact threshold is, 49762 bytes works, 52426
> bytes does not, so 50000 should be good value).

Can you please make clear in the subject (or at least in the commit
message) that this change is only related to SoCFPGA systems? Thanks.

Best regards,

Wolfgang Denk
diff mbox

Patch

diff --git a/include/configs/socfpga_common.h b/include/configs/socfpga_common.h
index f657766..c82da96 100644
--- a/include/configs/socfpga_common.h
+++ b/include/configs/socfpga_common.h
@@ -323,7 +332,7 @@  unsigned int cm_get_qspi_controller_clk_hz(void);
 #define CONFIG_SPL_FRAMEWORK
 #define CONFIG_SPL_RAM_DEVICE
 #define CONFIG_SPL_TEXT_BASE		CONFIG_SYS_INIT_RAM_ADDR
-#define CONFIG_SPL_MAX_SIZE		(64 * 1024)
+#define CONFIG_SPL_MAX_SIZE		(48 * 1024)
 #ifdef CONFIG_SPL_BUILD
 #define CONFIG_SYS_MALLOC_SIMPLE
 #endif