]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
board: sama5d3_xplained: add pda detect call at init time
authorEugen Hristev <eugen.hristev@microchip.com>
Tue, 18 Sep 2018 07:35:44 +0000 (10:35 +0300)
committerTom Rini <trini@konsulko.com>
Sat, 29 Sep 2018 00:22:40 +0000 (20:22 -0400)
Call the PDA detection mechanism at boot time so we can have
the pda environment variable ready for use.

Signed-off-by: Eugen Hristev <eugen.hristev@microchip.com>
arch/arm/mach-at91/Kconfig
board/atmel/sama5d3_xplained/sama5d3_xplained.c

index 69856c89428591850641646e1192d202effbb882..3784cbb70b9922f113e87c62e30bf75d0713c14f 100644 (file)
@@ -177,6 +177,7 @@ config TARGET_SAMA5D3_XPLAINED
        select BOARD_EARLY_INIT_F
        select SAMA5D3
        select SUPPORT_SPL
+       select BOARD_LATE_INIT
 
 config TARGET_SAMA5D3XEK
        bool "SAMA5D3X-EK board"
index c47f63864b4c5cfa17e2542329745812ec03a2d4..289f8d84999183cfcd0daf8bfedb9be9d6aedf57 100644 (file)
@@ -18,6 +18,8 @@
 
 DECLARE_GLOBAL_DATA_PTR;
 
+extern void at91_pda_detect(void);
+
 #ifdef CONFIG_NAND_ATMEL
 void sama5d3_xplained_nand_hw_init(void)
 {
@@ -72,6 +74,14 @@ void board_debug_uart_init(void)
 }
 #endif
 
+#ifdef CONFIG_BOARD_LATE_INIT
+int board_late_init(void)
+{
+       at91_pda_detect();
+       return 0;
+}
+#endif
+
 #ifdef CONFIG_BOARD_EARLY_INIT_F
 int board_early_init_f(void)
 {