[tip: irq/drivers] irqchip/gic-v4: Don't advertise VLPIs if no ITS is probed
From: tip-bot2 for Mostafa Saleh
Date: Tue May 26 2026 - 16:18:25 EST
The following commit has been merged into the irq/drivers branch of tip:
Commit-ID: e61654fbc3bc5d07ec9fafe29f33e19b2b5d0fd5
Gitweb: https://git.kernel.org/tip/e61654fbc3bc5d07ec9fafe29f33e19b2b5d0fd5
Author: Mostafa Saleh <smostafa@xxxxxxxxxx>
AuthorDate: Tue, 26 May 2026 12:53:17
Committer: Thomas Gleixner <tglx@xxxxxxxxxx>
CommitterDate: Tue, 26 May 2026 22:17:28 +02:00
irqchip/gic-v4: Don't advertise VLPIs if no ITS is probed
When accidentally setting “kvm-arm.vgic_v4_enable=1” on a system that has
no MSI controller device tree node and GICv4, it results a panic as
“gic_domain” is NULL and the kernel attempts to access it.
Unable to handle kernel NULL pointer dereference at virtual address 0000000000000028
Mem abort info:
ESR = 0x0000000096000006
CPU: 1 UID: 0 PID: 295 Comm: lkvm-static Not tainted 7.1.0-rc4-ge3f15ad3970e #5 PREEMPT
Hardware name: linux,dummy-virt (DT)
pstate: 81402005 (Nzcv daif +PAN -UAO -TCO +DIT -SSBS BTYPE=--)
pc : __irq_domain_instantiate+0x1d4/0x578
lr : __irq_domain_instantiate+0x1cc/0x578
Set vLPI support to false at init time if the host has no ITS, so it
propagates properly to kvm_vgic_global_state.has_gicv4.
Suggested-by: Marc Zyngier <maz@xxxxxxxxxx>
Signed-off-by: Mostafa Saleh <smostafa@xxxxxxxxxx>
Signed-off-by: Thomas Gleixner <tglx@xxxxxxxxxx>
Acked-by: Marc Zyngier <maz@xxxxxxxxxx>
Link: https://patch.msgid.link/20260526125317.3672297-1-smostafa@xxxxxxxxxx
---
drivers/irqchip/irq-gic-v3-its.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/irqchip/irq-gic-v3-its.c b/drivers/irqchip/irq-gic-v3-its.c
index e78795b..b57d81a 100644
--- a/drivers/irqchip/irq-gic-v3-its.c
+++ b/drivers/irqchip/irq-gic-v3-its.c
@@ -5833,6 +5833,7 @@ int __init its_init(struct fwnode_handle *handle, struct rdists *rdists,
its_acpi_probe();
if (list_empty(&its_nodes)) {
+ rdists->has_vlpis = false;
pr_warn("ITS: No ITS available, not enabling LPIs\n");
return -ENXIO;
}