summaryrefslogtreecommitdiff
path: root/drivers/hid/hid-ntrig.c
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>2025-09-15 08:18:40 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2025-09-15 08:18:40 +0200
commita4d43c1f17b9f143af5868285c513c866e9cf67b (patch)
tree36117fb220ae2ff5cf1c11fc6ffa705acdc34833 /drivers/hid/hid-ntrig.c
parent82432bbfb9e83b7e81d04660fe129b99a29b2ac2 (diff)
parentf83ec76bf285bea5727f478a68b894f5543ca76e (diff)
Merge 6.17-rc6 into usb-next
We need the USB fixes in here as well. Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/hid/hid-ntrig.c')
-rw-r--r--drivers/hid/hid-ntrig.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/hid/hid-ntrig.c b/drivers/hid/hid-ntrig.c
index 2738ce947434..0f76e241e0af 100644
--- a/drivers/hid/hid-ntrig.c
+++ b/drivers/hid/hid-ntrig.c
@@ -144,6 +144,9 @@ static void ntrig_report_version(struct hid_device *hdev)
struct usb_device *usb_dev = hid_to_usb_dev(hdev);
unsigned char *data = kmalloc(8, GFP_KERNEL);
+ if (!hid_is_usb(hdev))
+ return;
+
if (!data)
goto err_free;