All of lore.kernel.org
 help / color / mirror / Atom feed
From: Deepak Das <deepakdas.linux@gmail.com>
To: xen-devel@lists.xenproject.org
Cc: Deepak Das <deepakdas.linux@gmail.com>,
	Stefano Stabellini <sstabellini@kernel.org>,
	Julien Grall <julien@xen.org>,
	Bertrand Marquis <bertrand.marquis@arm.com>,
	Michal Orzel <michal.orzel@amd.com>,
	Volodymyr Babchuk <Volodymyr_Babchuk@epam.com>
Subject: [PATCH] xen/arm: Do not expose Cortex-A53/A72 PMU nodes to the hardware domain
Date: Thu,  3 Dec 2026 03:51:59 +0000	[thread overview]
Message-ID: <20261203035159.374049-1-deepakdas.linux@gmail.com> (raw)

handle_node() already skips the "arm,cortex-a7-pmu", "arm,cortex-a15-pmu"
and "arm,armv8-pmuv3" nodes when building the hardware domain DT,
because the PMU interrupt is a PPI, which cannot be routed to a guest.

Device trees often describe the PMU with a per-core-type compatible
instead. The Rockchip RK3399 has one PMU node per cluster,
"arm,cortex-a53-pmu" and "arm,cortex-a72-pmu", and each references a
GICv3 "ppi-partitions" child node. Those nodes are copied to the
hardware domain, and map_device_irqs_to_domain() then fails to route
their PPI ("IRQ can only be routed to an SPI"), which aborts domain
construction.

Skip these two compatibles as well, in the same way as the existing
PMU entries.

Found while bringing up Xen on a FriendlyElec NanoPC-T4 (RK3399).

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Deepak Das <deepakdas.linux@gmail.com>
---
 xen/arch/arm/domain_build.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/xen/arch/arm/domain_build.c b/xen/arch/arm/domain_build.c
index 57473507fa..45d6ad102f 100644
--- a/xen/arch/arm/domain_build.c
+++ b/xen/arch/arm/domain_build.c
@@ -1520,6 +1520,8 @@ static int __init handle_node(struct domain *d, struct kernel_info *kinfo,
         DT_MATCH_COMPATIBLE("arm,cortex-a15-pmu"),
         DT_MATCH_COMPATIBLE("arm,cortex-a53-edac"),
         DT_MATCH_COMPATIBLE("arm,armv8-pmuv3"),
+        DT_MATCH_COMPATIBLE("arm,cortex-a53-pmu"),
+        DT_MATCH_COMPATIBLE("arm,cortex-a72-pmu"),
         DT_MATCH_PATH("/cpus"),
         DT_MATCH_TYPE("memory"),
         /* The memory mapped timer is not supported by Xen. */
-- 
2.43.0



             reply	other threads:[~2026-12-03  6:03 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-12-03  3:51 Deepak Das [this message]
2026-12-03  8:31 ` [PATCH] xen/arm: Do not expose Cortex-A53/A72 PMU nodes to the hardware domain Orzel, Michal
2026-12-04  2:45   ` Deepak Das

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=20261203035159.374049-1-deepakdas.linux@gmail.com \
    --to=deepakdas.linux@gmail.com \
    --cc=Volodymyr_Babchuk@epam.com \
    --cc=bertrand.marquis@arm.com \
    --cc=julien@xen.org \
    --cc=michal.orzel@amd.com \
    --cc=sstabellini@kernel.org \
    --cc=xen-devel@lists.xenproject.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 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.