From 4c186846fa8c8b432dfb8fa19b31b121c0e7c06e Mon Sep 17 00:00:00 2001 From: Corentin LABBE Date: Tue, 21 Jun 2022 13:06:16 +0000 Subject: [PATCH] board: ti: am335x: eth_cpsw should depend on CONFIG_NET The origin of this patch is the breaking of am335x-hs boot due to commit e41651fffda7 ("dm: Support parent devices with of-platdata") HS boards have less SRAM for SPL and so this commit increased memory usage beyond am335x limit. This commit added 10 driver binding pass and am335x boot only if one pass is done. SPL try to do more than one pass due to eth_cpsw failing. Since HS SPL does not need network (and NET is already disabled in config), the easiest fix is to "remove" eth_cpsw from SPL by testing if NET is enabled. commit 2f51f946e3e97d3d9463e0f199d055dbcb4eef02 upstream Signed-off-by: Corentin LABBE Reviewed-by: Tom Rini Acked-by: Andrew Davis --- board/ti/am335x/board.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/board/ti/am335x/board.c b/board/ti/am335x/board.c index 4dc04817dc..cc2ba36206 100644 --- a/board/ti/am335x/board.c +++ b/board/ti/am335x/board.c @@ -904,7 +904,7 @@ int board_late_init(void) #endif /* CPSW platdata */ -#if !CONFIG_IS_ENABLED(OF_CONTROL) +#if CONFIG_IS_ENABLED(NET) && !CONFIG_IS_ENABLED(OF_CONTROL) struct cpsw_slave_data slave_data[] = { { .slave_reg_ofs = CPSW_SLAVE0_OFFSET,