diff options
Diffstat (limited to 'drivers/hid')
-rw-r--r-- | drivers/hid/usbhid/hid-core.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/drivers/hid/usbhid/hid-core.c b/drivers/hid/usbhid/hid-core.c index 8e0c4bf94ebc..366fd09d257d 100644 --- a/drivers/hid/usbhid/hid-core.c +++ b/drivers/hid/usbhid/hid-core.c | |||
@@ -1243,6 +1243,18 @@ static int usbhid_power(struct hid_device *hid, int lvl) | |||
1243 | return r; | 1243 | return r; |
1244 | } | 1244 | } |
1245 | 1245 | ||
1246 | static void usbhid_request(struct hid_device *hid, struct hid_report *rep, int reqtype) | ||
1247 | { | ||
1248 | switch (reqtype) { | ||
1249 | case HID_REQ_GET_REPORT: | ||
1250 | usbhid_submit_report(hid, rep, USB_DIR_IN); | ||
1251 | break; | ||
1252 | case HID_REQ_SET_REPORT: | ||
1253 | usbhid_submit_report(hid, rep, USB_DIR_OUT); | ||
1254 | break; | ||
1255 | } | ||
1256 | } | ||
1257 | |||
1246 | static struct hid_ll_driver usb_hid_driver = { | 1258 | static struct hid_ll_driver usb_hid_driver = { |
1247 | .parse = usbhid_parse, | 1259 | .parse = usbhid_parse, |
1248 | .start = usbhid_start, | 1260 | .start = usbhid_start, |
@@ -1251,6 +1263,7 @@ static struct hid_ll_driver usb_hid_driver = { | |||
1251 | .close = usbhid_close, | 1263 | .close = usbhid_close, |
1252 | .power = usbhid_power, | 1264 | .power = usbhid_power, |
1253 | .hidinput_input_event = usb_hidinput_input_event, | 1265 | .hidinput_input_event = usb_hidinput_input_event, |
1266 | .request = usbhid_request, | ||
1254 | }; | 1267 | }; |
1255 | 1268 | ||
1256 | static int usbhid_probe(struct usb_interface *intf, const struct usb_device_id *id) | 1269 | static int usbhid_probe(struct usb_interface *intf, const struct usb_device_id *id) |