diff mbox

[U-Boot,9/9] omap: detect board before spl_early_init()

Message ID 1500570157-24042-10-git-send-email-jjhiblot@ti.com
State Superseded
Delegated to: Tom Rini
Headers show

Commit Message

Jean-Jacques Hiblot July 20, 2017, 5:02 p.m. UTC
In order to be able to select the right DTB, we need to have identified the
board before spl_early_init() is called.

Signed-off-by: Jean-Jacques Hiblot <jjhiblot@ti.com>
---
 arch/arm/mach-omap2/hwinit-common.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

Comments

Tom Rini July 24, 2017, 1:29 p.m. UTC | #1
On Thu, Jul 20, 2017 at 07:02:36PM +0200, Jean-Jacques Hiblot wrote:

> In order to be able to select the right DTB, we need to have identified the
> board before spl_early_init() is called.
> 
> Signed-off-by: Jean-Jacques Hiblot <jjhiblot@ti.com>

Reviewed-by: Tom Rini <trini@konsulko.com>
Simon Glass Aug. 3, 2017, 3:25 p.m. UTC | #2
On 20 July 2017 at 11:02, Jean-Jacques Hiblot <jjhiblot@ti.com> wrote:
> In order to be able to select the right DTB, we need to have identified the
> board before spl_early_init() is called.
>
> Signed-off-by: Jean-Jacques Hiblot <jjhiblot@ti.com>
> ---
>  arch/arm/mach-omap2/hwinit-common.c | 4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)
>

Reviewed-by: Simon Glass <sjg@chromium.org>
diff mbox

Patch

diff --git a/arch/arm/mach-omap2/hwinit-common.c b/arch/arm/mach-omap2/hwinit-common.c
index 7324d52..56890a0 100644
--- a/arch/arm/mach-omap2/hwinit-common.c
+++ b/arch/arm/mach-omap2/hwinit-common.c
@@ -165,9 +165,11 @@  void early_system_init(void)
 	 * to prevent overwrites.
 	 */
 	save_omap_boot_params();
-	spl_early_init();
 #endif
 	do_board_detect();
+#ifdef CONFIG_SPL_BUILD
+	spl_early_init();
+#endif
 	vcores_init();
 #ifdef CONFIG_DEBUG_UART_OMAP
 	debug_uart_init();