Re: [PATCH] mfd: hi655x-pmic: fix IRQ action memory leak on removal
From: Guangshuo Li
Date: Tue Oct 27 2026 - 12:39:20 EST
Hi Krzysztof,
On Tue, 27 Oct 2026 at 23:27, Krzysztof Kozlowski <krzk@xxxxxxxxxx> wrote:
>
> On 27/10/2026 03:46, Guangshuo Li wrote:
> > hi655x_pmic_remove() currently removes the regmap IRQ chip before
> > removing the MFD child devices. regmap_del_irq_chip() disposes the
> > child IRQ mappings and removes their IRQ descriptors.
> >
> > The hi65xx-powerkey child registers interrupt handlers using
> > devm_request_any_context_irq(). During child device removal, the
> > device-managed cleanup calls free_irq(), but the corresponding IRQ
> > descriptors are no longer available. As a result, the allocated
> > struct irqaction objects referenced by irq_desc->action are not
> > freed, causing a memory leak.
> >
> > Remove the MFD child devices first, allowing their device-managed
> > IRQ handlers to be released while the IRQ mappings are still valid.
> > Then remove the regmap IRQ chip and its IRQ domain.
> >
> > This issue was found by our static analysis tool under development.
>
> More of postings by bot ignoring any feedback.
>
> Best regards,
> Krzysztof
Thank you for your feedback, and I apologize if our recent submissions
gave the impression that we were ignoring your previous comments.
We did take your earlier suggestions into account and subsequently
submitted a patch series accordingly.
For the more recent patches, however, since they address issues in
different drivers, we thought it would be more appropriate to submit
them separately rather than group them into a single series.
We certainly did not intend to disregard your feedback. We appreciate
your time and guidance, and we will be more careful with our future
submissions.
Thank you for your understanding.
Best regards,
Guangshuo Li