From: Guangshuo Li <liguangshuo@mail.sdu.edu.cn>
To: tglx@kernel.org, nm@ti.com, kristo@kernel.org,
ssantosh@kernel.org, hayashi.kunihiko@socionext.com,
mhiramat@kernel.org, ioana.ciornei@nxp.com,
alexander.stein@ew.tq-group.com, maz@kernel.org,
lokeshvutla@ti.com, yamada.masahiro@socionext.com,
robh@kernel.org
Cc: radu@rendec.net, linux-kernel@vger.kernel.org,
linux-arm-kernel@lists.infradead.org
Subject: [PATCH 1/3] irqchip/ls-extirq: Remove the interrupt domain on unbind
Date: Sat, 28 Nov 2026 17:41:16 +0800 [thread overview]
Message-ID: <20261128-f81b700d6c-u38-1@mail.sdu.edu.cn> (raw)
In-Reply-To: <20261128-f81b700d6c-u38-0@mail.sdu.edu.cn>
The IRQ domain remains registered when the platform device releases
the controller data used by its domain operations. Remove the
domain as part of device teardown.
This issue was found by our static analysis tool under development.
Fixes: 05cd654829dd ("irqchip/ls-extirq: Convert to a platform driver to make it work again")
Signed-off-by: Guangshuo Li <liguangshuo@mail.sdu.edu.cn>
---
drivers/irqchip/irq-ls-extirq.c | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/drivers/irqchip/irq-ls-extirq.c b/drivers/irqchip/irq-ls-extirq.c
index b791cb03a44a..ae8e9c918ac8 100644
--- a/drivers/irqchip/irq-ls-extirq.c
+++ b/drivers/irqchip/irq-ls-extirq.c
@@ -168,6 +168,11 @@ ls_extirq_parse_map(struct ls_extirq_data *priv, struct device_node *node)
return 0;
}
+static void ls_extirq_remove_domain(void *data)
+{
+ irq_domain_remove(data);
+}
+
static int ls_extirq_probe(struct platform_device *pdev)
{
struct irq_domain *domain, *parent_domain;
@@ -209,7 +214,7 @@ static int ls_extirq_probe(struct platform_device *pdev)
if (!domain)
return dev_err_probe(dev, -ENOMEM, "Failed to add IRQ domain\n");
- return 0;
+ return devm_add_action_or_reset(dev, ls_extirq_remove_domain, domain);
}
static const struct of_device_id ls_extirq_dt_ids[] = {
--
2.43.0
next prev parent reply other threads:[~2026-11-28 9:41 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-28 9:41 [PATCH 0/3] irqchip: Remove interrupt domains on driver teardown Guangshuo Li
2026-11-28 9:41 ` Guangshuo Li [this message]
2026-11-28 9:41 ` [PATCH 2/3] irqchip/ti-sci-intr: Remove the interrupt domain on unbind Guangshuo Li
2026-11-28 9:41 ` [PATCH 3/3] irqchip/uniphier-aidet: " Guangshuo Li
2026-11-28 21:36 ` [PATCH 0/3] irqchip: Remove interrupt domains on driver teardown Radu Rendec
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=20261128-f81b700d6c-u38-1@mail.sdu.edu.cn \
--to=liguangshuo@mail.sdu.edu.cn \
--cc=alexander.stein@ew.tq-group.com \
--cc=hayashi.kunihiko@socionext.com \
--cc=ioana.ciornei@nxp.com \
--cc=kristo@kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=lokeshvutla@ti.com \
--cc=maz@kernel.org \
--cc=mhiramat@kernel.org \
--cc=nm@ti.com \
--cc=radu@rendec.net \
--cc=robh@kernel.org \
--cc=ssantosh@kernel.org \
--cc=tglx@kernel.org \
--cc=yamada.masahiro@socionext.com \
/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
all inboxes | Powered by JetHome®