Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- From 66e8da50a8e779a1d3a29bc1ef985246ef6b7599 Mon Sep 17 00:00:00 2001
- From: Fedora Kernel Team <kernel-team@fedoraproject.org>
- Date: Wed, 20 Jun 2018 13:22:00 -0500
- Subject: [PATCH 1/3] input: hid: Add HID_QUIRK_INIT_USB_INPUT_REPORTS
- ---
- drivers/hid/usbhid/hid-core.c | 3 +++
- include/linux/hid.h | 1 +
- 2 files changed, 4 insertions(+)
- diff --git a/drivers/hid/usbhid/hid-core.c b/drivers/hid/usbhid/hid-core.c
- index 77c50cd..87c5a9d 100644
- --- a/drivers/hid/usbhid/hid-core.c
- +++ b/drivers/hid/usbhid/hid-core.c
- @@ -1141,6 +1141,9 @@ static int usbhid_start(struct hid_device *hid)
- usbhid->urbctrl->transfer_dma = usbhid->ctrlbuf_dma;
- usbhid->urbctrl->transfer_flags |= URB_NO_TRANSFER_DMA_MAP;
- + if (hid->quirks & HID_QUIRK_INIT_USB_INPUT_REPORTS)
- + usbhid_init_reports(hid);
- +
- set_bit(HID_STARTED, &usbhid->iofl);
- if (hid->quirks & HID_QUIRK_ALWAYS_POLL) {
- diff --git a/include/linux/hid.h b/include/linux/hid.h
- index 29b981b..21cad07 100644
- --- a/include/linux/hid.h
- +++ b/include/linux/hid.h
- @@ -340,6 +340,7 @@ struct hid_item {
- #define HID_QUIRK_NO_EMPTY_INPUT 0x00000100
- /* 0x00000200 reserved for backward compatibility, was NO_INIT_INPUT_REPORTS */
- #define HID_QUIRK_ALWAYS_POLL 0x00000400
- +#define HID_QUIRK_INIT_USB_INPUT_REPORTS 0x00000800
- #define HID_QUIRK_SKIP_OUTPUT_REPORTS 0x00010000
- #define HID_QUIRK_SKIP_OUTPUT_REPORT_ID 0x00020000
- #define HID_QUIRK_NO_OUTPUT_REPORTS_ON_INTR_EP 0x00040000
- --
- 2.17.1
Add Comment
Please, Sign In to add comment