]> git.ipfire.org Git - thirdparty/linux.git/commit
HID: Add HID_CLAIMED_INPUT guards in raw_event callbacks missing them
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 19 Feb 2026 14:33:54 +0000 (15:33 +0100)
committerBenjamin Tissoires <bentiss@kernel.org>
Thu, 19 Feb 2026 17:58:39 +0000 (18:58 +0100)
commitecfa6f34492c493a9a1dc2900f3edeb01c79946b
tree6da7a0e5eae8bbfb52786cea99174f7e0986a0de
parent2bad24c17742fc88973d6aea526ce1353f5334a3
HID: Add HID_CLAIMED_INPUT guards in raw_event callbacks missing them

In commit 2ff5baa9b527 ("HID: appleir: Fix potential NULL dereference at
raw event handle"), we handle the fact that raw event callbacks
can happen even for a HID device that has not been "claimed" causing a
crash if a broken device were attempted to be connected to the system.

Fix up the remaining in-tree HID drivers that forgot to add this same
check to resolve the same issue.

Cc: Jiri Kosina <jikos@kernel.org>
Cc: Benjamin Tissoires <bentiss@kernel.org>
Cc: Bastien Nocera <hadess@hadess.net>
Cc: linux-input@vger.kernel.org
Cc: stable <stable@kernel.org>
Assisted-by: gkh_clanker_2000
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Benjamin Tissoires <bentiss@kernel.org>
drivers/hid/hid-cmedia.c
drivers/hid/hid-creative-sb0540.c
drivers/hid/hid-zydacron.c