From: Dmitry Torokhov <dmitry.torokhov@gmail.com>
To: Myeonghun Pak <mhun512@gmail.com>
Cc: Support Opensource <support.opensource@diasemi.com>,
linux-input@vger.kernel.org, linux-kernel@vger.kernel.org,
Ijae Kim <ae878000@gmail.com>
Subject: Re: [PATCH] Input: da9055_onkey - free the requested IRQ on removal
Date: Sat, 17 Oct 2026 23:13:10 -0700 [thread overview]
Message-ID: <atRjQCqkFbt6I3LQ@google.com> (raw)
In-Reply-To: <179229215687.3924264.8583597004889642167.da9055-onkey@gmail.com>
Hi Myeonghun,
On Sat, Oct 17, 2026 at 10:56:50PM -0400, Myeonghun Pak wrote:
> platform_get_irq_byname() returns the Linux IRQ number already
> translated by the MFD core. The probe path requests this IRQ directly,
> but remove passes it through regmap_irq_get_virq() again as a chip-local
> index.
>
> This can access beyond the chip IRQ table or yield a different IRQ, so
> the requested ONKEY interrupt is not released. An interrupt after the
> work cancellation can then access the unregistered input device or queue
> work referencing the freed onkey state.
>
> Remove the second translation so free_irq() stops the same producer that
> probe installed before the delayed work and input device are torn down.
I think it is better to convert the driver to devm as in the patch I
just sent out, it will take care of this issue as well as make the code
simpler.
Thanks.
--
Dmitry
prev parent reply other threads:[~2026-10-18 6:13 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-18 2:56 [PATCH] Input: da9055_onkey - free the requested IRQ on removal Myeonghun Pak
2026-10-18 6:13 ` Dmitry Torokhov [this message]
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=atRjQCqkFbt6I3LQ@google.com \
--to=dmitry.torokhov@gmail.com \
--cc=ae878000@gmail.com \
--cc=linux-input@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mhun512@gmail.com \
--cc=support.opensource@diasemi.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