From: Ahmad Fatoum <a.fatoum@pengutronix.de>
To: barebox@lists.infradead.org
Cc: Ahmad Fatoum <a.fatoum@pengutronix.de>,
Michael Tretter <m.tretter@pengutronix.de>
Subject: [PATCH master] ARM64: clocksource: drop too early error message
Date: Fri, 4 Sep 2026 12:13:45 +0200 [thread overview]
Message-ID: <20260904101345.399568-1-a.fatoum@pengutronix.de> (raw)
Constructors are executed directly after relocations were applied.
But only after applying relocations is it safe to run arbitrary C code.
This causes an issue: If arm_arch_timer_init() fails and CONFIG_DEBUG_LL
is enabled, the hardcoded serial port will be used, which may hang the
system if serial setup has not happened yet.
Avoid this issue by skipping the error message.
I have declarative PBL entry point support in the works, which would side
step this issue anyway, so doing anything fancy here right now is not
worth the effort.
Reported-by: Michael Tretter <m.tretter@pengutronix.de>
Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
---
arch/arm/lib64/clocksource.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/arch/arm/lib64/clocksource.c b/arch/arm/lib64/clocksource.c
index f992be09b8a7..f5fef1f3d410 100644
--- a/arch/arm/lib64/clocksource.c
+++ b/arch/arm/lib64/clocksource.c
@@ -5,6 +5,5 @@
__attribute__((constructor)) static void init_arch_clock(void)
{
- if (arm_arch_timer_init(0))
- puts_ll("Failed to setup architected timer\n");
+ arm_arch_timer_init(0);
}
--
2.47.3
next reply other threads:[~2026-09-04 10:14 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-04 10:13 Ahmad Fatoum [this message]
2026-09-04 10:34 ` Michael Tretter
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=20260904101345.399568-1-a.fatoum@pengutronix.de \
--to=a.fatoum@pengutronix.de \
--cc=barebox@lists.infradead.org \
--cc=m.tretter@pengutronix.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