]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
HID: hid-ntrig: fix unable to handle page fault in ntrig_report_version()
authorMinjong Kim <minbell.kim@samsung.com>
Wed, 13 Aug 2025 10:30:22 +0000 (19:30 +0900)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 4 Sep 2025 12:05:56 +0000 (14:05 +0200)
commit22ddb5eca4af5e69dffe2b54551d2487424448f1
tree5f0382aa16432c5bee2061705012e0d887a5ac95
parent6bb9d3da2cade1c2fc726ee8a404d4364f225744
HID: hid-ntrig: fix unable to handle page fault in ntrig_report_version()

commit 185c926283da67a72df20a63a5046b3b4631b7d9 upstream.

in ntrig_report_version(), hdev parameter passed from hid_probe().
sending descriptor to /dev/uhid can make hdev->dev.parent->parent to null
if hdev->dev.parent->parent is null, usb_dev has
invalid address(0xffffffffffffff58) that hid_to_usb_dev(hdev) returned
when usb_rcvctrlpipe() use usb_dev,it trigger
page fault error for address(0xffffffffffffff58)

add null check logic to ntrig_report_version()
before calling hid_to_usb_dev()

Signed-off-by: Minjong Kim <minbell.kim@samsung.com>
Link: https://patch.msgid.link/20250813-hid-ntrig-page-fault-fix-v2-1-f98581f35106@samsung.com
Signed-off-by: Benjamin Tissoires <bentiss@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/hid/hid-ntrig.c