[PATCH 5/9] ls1088a: Guard get_board_ddr_clk function correctly

Tom Rini trini at konsulko.com
Tue Dec 14 19:36:37 CET 2021


When we have CONFIG_DYNAMIC_DDR_CLK_FREQ set is the only time we should
have this function, so guard it so that we can include <clock_legacy.h>
in this file later on.

Signed-off-by: Tom Rini <trini at konsulko.com>
---
 board/freescale/ls1088a/ls1088a.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/board/freescale/ls1088a/ls1088a.c b/board/freescale/ls1088a/ls1088a.c
index 7046fbaeb5d6..73c2077ecdb6 100644
--- a/board/freescale/ls1088a/ls1088a.c
+++ b/board/freescale/ls1088a/ls1088a.c
@@ -398,6 +398,7 @@ unsigned long get_board_sys_clk(void)
 	return 66666666;
 }
 
+#ifdef CONFIG_DYNAMIC_DDR_CLK_FREQ
 unsigned long get_board_ddr_clk(void)
 {
 	u8 ddrclk_conf = QIXIS_READ(brdcfg[1]);
@@ -415,6 +416,7 @@ unsigned long get_board_ddr_clk(void)
 
 	return 66666666;
 }
+#endif
 
 #if !defined(CONFIG_SPL_BUILD)
 void board_retimer_init(void)
-- 
2.25.1



More information about the U-Boot mailing list