All of lore.kernel.org
 help / color / mirror / Atom feed
From: Adam Ford <aford173@gmail.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH 1/2] ARM: imx6qlogic: Cleanup board_init_f and enable spl_early_init
Date: Wed,  7 Aug 2019 11:35:51 -0500	[thread overview]
Message-ID: <20190807163552.25400-1-aford173@gmail.com> (raw)

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
-- 
2.17.1

             reply	other threads:[~2019-08-07 16:35 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-08-07 16:35 Adam Ford [this message]
2019-08-07 16:35 ` [U-Boot] [PATCH 2/2] ARM: imx6q_logic: Enable DM_SERIAL Adam Ford
2019-08-07 16:40   ` Fabio Estevam
2019-08-07 16:42     ` Adam Ford
2019-08-07 16:39 ` [U-Boot] [PATCH 1/2] ARM: imx6qlogic: Cleanup board_init_f and enable spl_early_init Fabio Estevam

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20190807163552.25400-1-aford173@gmail.com \
    --to=aford173@gmail.com \
    --cc=u-boot@lists.denx.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.