[U-Boot] [PATCH 4/8] arm64: zynqmp: Call psu_init from board_early_init_f

Michal Simek michal.simek at xilinx.com
Thu Jul 20 09:07:45 UTC 2017


For some mini platforms there could be a need to include psu_init.
That's why move it to board file instead of spl only file.

Signed-off-by: Michal Simek <michal.simek at xilinx.com>
---

 arch/arm/cpu/armv8/zynqmp/spl.c | 2 +-
 board/xilinx/zynqmp/zynqmp.c    | 5 +++++
 2 files changed, 6 insertions(+), 1 deletion(-)

diff --git a/arch/arm/cpu/armv8/zynqmp/spl.c b/arch/arm/cpu/armv8/zynqmp/spl.c
index 26bf80ec52b4..468dc1dc4d54 100644
--- a/arch/arm/cpu/armv8/zynqmp/spl.c
+++ b/arch/arm/cpu/armv8/zynqmp/spl.c
@@ -17,7 +17,7 @@
 
 void board_init_f(ulong dummy)
 {
-	psu_init();
+	board_early_init_f();
 	board_early_init_r();
 
 #ifdef CONFIG_DEBUG_UART
diff --git a/board/xilinx/zynqmp/zynqmp.c b/board/xilinx/zynqmp/zynqmp.c
index 51a3d9f276b7..442637bcae2c 100644
--- a/board/xilinx/zynqmp/zynqmp.c
+++ b/board/xilinx/zynqmp/zynqmp.c
@@ -118,6 +118,11 @@ int board_early_init_f(void)
 #if !defined(CONFIG_SPL_BUILD) && defined(CONFIG_CLK_ZYNQMP)
 	zynqmp_pmufw_version();
 #endif
+
+#if defined(CONFIG_SPL_BUILD)
+	psu_init();
+#endif
+
 	return 0;
 }
 
-- 
1.9.1



More information about the U-Boot mailing list