[tip: irq/urgent] irqchip/gic-v5: Check for NULL LPI domain on domain teardown
From: tip-bot2 for Lorenzo Pieralisi
Date: Thu Aug 20 2026 - 04:28:07 EST
The following commit has been merged into the irq/urgent branch of tip:
Commit-ID: aa079dbf4c2598c2613a0e464efcb2c232753c51
Gitweb: https://git.kernel.org/tip/aa079dbf4c2598c2613a0e464efcb2c232753c51
Author: Lorenzo Pieralisi <lpieralisi@xxxxxxxxxx>
AuthorDate: Wed, 12 Aug 2026 11:10:30 +02:00
Committer: Thomas Gleixner <tglx@xxxxxxxxxx>
CommitterDate: Thu, 20 Aug 2026 10:23:53 +02:00
irqchip/gic-v5: Check for NULL LPI domain on domain teardown
In gicv5_free_lpi_domain() the LPI domain being freed can be NULL.
Check it and return before trying to free it if it is.
Fixes: 0f0101325876 ("irqchip/gic-v5: Add GICv5 LPI/IPI support")
Signed-off-by: Lorenzo Pieralisi <lpieralisi@xxxxxxxxxx>
Signed-off-by: Thomas Gleixner <tglx@xxxxxxxxxx>
Link: https://sashiko.dev/#/message/20260810104747.E5CE71F000E9%40smtp.kernel.org
Link: https://patch.msgid.link/20260812-gicv5-7-2-fixes-v1-2-3743e82c69a4@xxxxxxxxxx
---
drivers/irqchip/irq-gic-v5.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/irqchip/irq-gic-v5.c b/drivers/irqchip/irq-gic-v5.c
index ca48c8b..2151464 100644
--- a/drivers/irqchip/irq-gic-v5.c
+++ b/drivers/irqchip/irq-gic-v5.c
@@ -862,6 +862,9 @@ void __init gicv5_init_lpi_domain(void)
void __init gicv5_free_lpi_domain(void)
{
+ if (!gicv5_global_data.lpi_domain)
+ return;
+
irq_domain_remove(gicv5_global_data.lpi_domain);
gicv5_global_data.lpi_domain = NULL;
}