Changes in uspace/drv/usbhid/usbhid.c [bd2394b:252cf2a] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/drv/usbhid/usbhid.c
rbd2394b r252cf2a 63 63 static const int USB_HID_MAX_SUBDRIVERS = 10; 64 64 65 static fibril_local bool report_received; 66 65 67 /*----------------------------------------------------------------------------*/ 66 68 … … 197 199 mapping->report_id); 198 200 } 199 201 202 uint8_t report_id = (mapping->report_id >= 0) ? mapping->report_id : 0; 200 203 assert(hid_dev->report != NULL); 201 204 202 205 usb_log_debug("Compare flags: %d\n", mapping->compare); 203 size_t size = usb_hid_report_size(hid_dev->report, mapping->report_id,206 size_t size = usb_hid_report_size(hid_dev->report, report_id, 204 207 USB_HID_REPORT_TYPE_INPUT); 205 208 usb_log_debug("Size of the input report: %zuB\n", size); 206 209 207 210 usb_hid_report_path_free(usage_path); 208 211 … … 412 415 } 413 416 414 // TODO: remove the mouse hack 415 if (hid_dev->poll_pipe_index == USB_HID_MOUSE_POLL_EP_NO || 416 fallback) { 417 if (fallback) { 417 418 // fall back to boot protocol 418 419 switch (hid_dev->poll_pipe_index) { … … 509 510 free(input_old); 510 511 } 512 usb_hid_new_report(); 511 513 } 512 514 } … … 589 591 /*----------------------------------------------------------------------------*/ 590 592 593 void usb_hid_new_report(void) 594 { 595 report_received = false; 596 } 597 598 /*----------------------------------------------------------------------------*/ 599 600 void usb_hid_report_received(void) 601 { 602 report_received = true; 603 } 604 605 /*----------------------------------------------------------------------------*/ 606 607 bool usb_hid_report_ready(void) 608 { 609 return !report_received; 610 } 611 612 /*----------------------------------------------------------------------------*/ 613 591 614 void usb_hid_free(usb_hid_dev_t **hid_dev) 592 615 {
Note:
See TracChangeset
for help on using the changeset viewer.