
According to the the documentation, call spl_early_init from board_init_f to make the device tree and driver model early before board_init_r. Per the workflow found in crt0.S, we don't need to clear BSS in board_init_f nor do we need to call board_init_r since that will be done for us.
This patch removes the unneeded function calls from board_init_f and enables early access to device tree and DM which will permit the use of SPL_DM_SERIAL in the future.
Signed-off-by: Adam Ford aford173@gmail.com
diff --git a/board/logicpd/imx6/imx6logic.c b/board/logicpd/imx6/imx6logic.c index 6e3ffa72d7..2eea7aade5 100644 --- a/board/logicpd/imx6/imx6logic.c +++ b/board/logicpd/imx6/imx6logic.c @@ -347,13 +347,9 @@ void board_init_f(ulong dummy) /* setup GP timer */ timer_init();
+ spl_early_init(); + /* UART clocks enabled and gd valid - init serial console */ preloader_console_init(); - - /* Clear the BSS. */ - memset(__bss_start, 0, __bss_end - __bss_start); - - /* load/boot image from boot device */ - board_init_r(NULL, 0); } #endif