Re: [PATCH] HID: hid-oxp: fix UAF on pending work in remove()

"Shengzhuo Wei" <[email protected]> Tue, 4 Aug 2026 07:54:57 +0800
Newsgroups org.kernel.vger.linux-input,org.kernel.vger.linux-kernel,org.kernel.vger.stable
Message-ID <anEqUZyJGBrQ6HIW@pve>
On 2026-08-03 16:33, Dmitry Torokhov wrote:
=20
> What stops these jobs from re-arming? Should it use
> disable_delayed_work_sync() instead?

Agreed =E2=80=94 cancel_delayed_work_sync() only drains the running instanc=
e; it
doesn't stop the works from being re-queued from the raw_event / sysfs /
LED-brightness paths before the device is fully torn down, so the UAF
window isn't closed. I'll switch all three calls to
disable_delayed_work_sync() in v2.

Do you have any other comments you'd like addressed in v2?

Thanks,
Shengzhuo