From: Jagan Teki <jagan@amarulasolutions.com>
To: u-boot@lists.denx.de
Subject: [PATCH v5 4/5] rockchip: spl: Move board_early_init_f after cpu timer
Date: Tue, 14 Jul 2020 15:02:28 +0530 [thread overview]
Message-ID: <20200714093229.28763-5-jagan@amarulasolutions.com> (raw)
In-Reply-To: <20200714093229.28763-1-jagan@amarulasolutions.com>
Custom board_early_init_f not only deal with simple gpio
configuration but also have a possibility to access clocks
to process any clock related operations like checking reset
cause state and etc.
So, call it once the rockchip timer initialization done instead
of calling first place of board_init_f which doesn't have any
rockchip init code before.
This specific concern was tested with checking reset reason
via board_early_init_f, which indeed require a clk probe.
Signed-off-by: Jagan Teki <jagan@amarulasolutions.com>
---
Changes for v5:
- new patch
arch/arm/mach-rockchip/spl.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/arch/arm/mach-rockchip/spl.c b/arch/arm/mach-rockchip/spl.c
index cddf4fd3d5..082828de66 100644
--- a/arch/arm/mach-rockchip/spl.c
+++ b/arch/arm/mach-rockchip/spl.c
@@ -122,8 +122,6 @@ void board_init_f(ulong dummy)
debug("\nspl:debug uart enabled in %s\n", __func__);
#endif
- board_early_init_f();
-
ret = spl_early_init();
if (ret) {
printf("spl_early_init() failed: %d\n", ret);
@@ -137,6 +135,9 @@ void board_init_f(ulong dummy)
/* Init ARM arch timer in arch/arm/cpu/armv7/arch_timer.c */
timer_init();
#endif
+
+ board_early_init_f();
+
#if !defined(CONFIG_TPL) || defined(CONFIG_SPL_RAM)
debug("\nspl:init dram\n");
ret = dram_init();
--
2.25.1
next prev parent reply other threads:[~2020-07-14 9:32 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-07-14 9:32 [PATCH v5 0/5] roc-rk3399-pc: Custom SPL Jagan Teki
2020-07-14 9:32 ` [PATCH v5 1/5] roc-rk3399-pc: Move leds setup in SPL Jagan Teki
2020-07-18 12:45 ` Kever Yang
2020-07-14 9:32 ` [PATCH v5 2/5] rockchip: Don't clear the reset status reg Jagan Teki
2020-07-18 12:45 ` Kever Yang
2020-07-14 9:32 ` [PATCH v5 3/5] rockchip: Separate the reset cause from display cpuinfo Jagan Teki
2020-07-18 12:45 ` Kever Yang
2020-07-14 9:32 ` Jagan Teki [this message]
2020-07-18 13:22 ` [PATCH v5 4/5] rockchip: spl: Move board_early_init_f after cpu timer Kever Yang
2020-07-14 9:32 ` [PATCH v5 5/5] roc-rk3399-pc: Set LED only during POR and pwr_key=y Jagan Teki
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=20200714093229.28763-5-jagan@amarulasolutions.com \
--to=jagan@amarulasolutions.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox