From: Jon Hunter <jonathanh@nvidia.com>
To: Mark Rutland <mark.rutland@arm.com>,
Marc Zyngier <maz@kernel.org>,
"Daniel Lezcano" <daniel.lezcano@kernel.org>,
Thomas Gleixner <tglx@kernel.org>
Cc: <linux-arm-kernel@lists.infradead.org>,
<linux-kernel@vger.kernel.org>, <linux-tegra@vger.kernel.org>,
Jon Hunter <jonathanh@nvidia.com>
Subject: [PATCH] clocksource/drivers/arm_arch_timer: Mark EL2 virtual timer broken for Tegra194/234
Date: Wed, 22 Jul 2026 13:56:51 +0100 [thread overview]
Message-ID: <20260722125651.148595-1-jonathanh@nvidia.com> (raw)
The following warning is being observed on Tegra194 and Tegra234
platforms ...
arch_timer: [Firmware Bug]: VHE-capable CPU without EL2 virtual timer
interrupt
Adding the missing EL2 virtual timer in device-tree for Tegra194 and
Tegra234 is causing boot issues for both devices.
The Tegra194 device includes a GIC-400 which defines PPIs for sec-phys,
phys, virt and hyp-phys timer interrupts (per the dt-binding
arm,arch_timer.yaml) but there is no PPI hyp-virt (EL2 virtual) timer
and hence this is not supported for this device.
The Tegra234 device does have a PPI for the EL2 virtual timer, but
during CPU idle transitions into low-power states this timer is not
preserved currently by firmware and hence causes boot issues when CPU
idle is enabled.
Avoid the warning for Tegra194 and Tegra234 devices by marking the EL2
virtual timer as broken.
Suggested-by: Marc Zyngier <maz@kernel.org>
Signed-off-by: Jon Hunter <jonathanh@nvidia.com>
---
drivers/clocksource/arm_arch_timer.c | 14 ++++++++++++++
1 file changed, 14 insertions(+)
diff --git a/drivers/clocksource/arm_arch_timer.c b/drivers/clocksource/arm_arch_timer.c
index 4adf756423de..b9ccb560ff8f 100644
--- a/drivers/clocksource/arm_arch_timer.c
+++ b/drivers/clocksource/arm_arch_timer.c
@@ -1090,6 +1090,17 @@ static int __init arch_timer_common_init(void)
return arch_timer_arch_init();
}
+static bool __init has_broken_el2_vtimer(void)
+{
+ static const char * const broken_el2_vtimer[] __initconst = {
+ "nvidia,tegra194",
+ "nvidia,tegra234",
+ NULL
+ };
+
+ return of_machine_compatible_match(broken_el2_vtimer);
+}
+
/**
* arch_timer_select_ppi() - Select suitable PPI for the current system.
*
@@ -1115,6 +1126,9 @@ static int __init arch_timer_common_init(void)
static enum arch_timer_ppi_nr __init arch_timer_select_ppi(void)
{
if (is_kernel_in_hyp_mode()) {
+ if (has_broken_el2_vtimer())
+ return ARCH_TIMER_HYP_PPI;
+
if (arch_timer_ppi[ARCH_TIMER_HYP_VIRT_PPI])
return ARCH_TIMER_HYP_VIRT_PPI;
--
2.43.0
next reply other threads:[~2026-07-22 12:57 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-07-22 12:56 Jon Hunter [this message]
2026-07-22 13:42 ` [PATCH] clocksource/drivers/arm_arch_timer: Mark EL2 virtual timer broken for Tegra194/234 Sudeep Holla
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=20260722125651.148595-1-jonathanh@nvidia.com \
--to=jonathanh@nvidia.com \
--cc=daniel.lezcano@kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-tegra@vger.kernel.org \
--cc=mark.rutland@arm.com \
--cc=maz@kernel.org \
--cc=tglx@kernel.org \
/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