Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/drv/usbhid/kbd/kbddev.c

    r3a6e423 r1b7dc5e9  
    313313        usb_hid_report_field_t *field = usb_hid_report_get_sibling(
    314314            hid_dev->report, NULL, kbd_dev->led_path,
    315             USB_HID_PATH_COMPARE_END | USB_HID_PATH_COMPARE_USAGE_PAGE_ONLY,
     315            USB_HID_PATH_COMPARE_USAGE_PAGE_ONLY | USB_HID_PATH_COMPARE_END,
    316316            USB_HID_REPORT_TYPE_OUTPUT);
    317317       
    318         while (field != NULL) {         
    319                
     318        while (field != NULL) {
     319
    320320                if ((field->usage == USB_HID_LED_NUM_LOCK)
    321321                    && (kbd_dev->mods & KM_NUM_LOCK)){
     
    334334               
    335335                field = usb_hid_report_get_sibling(hid_dev->report, field,
    336                     kbd_dev->led_path, 
    337                 USB_HID_PATH_COMPARE_END | USB_HID_PATH_COMPARE_USAGE_PAGE_ONLY,
    338                         USB_HID_REPORT_TYPE_OUTPUT);
     336                    kbd_dev->led_path, USB_HID_PATH_COMPARE_USAGE_PAGE_ONLY
     337                    | USB_HID_PATH_COMPARE_END, USB_HID_REPORT_TYPE_OUTPUT);
    339338        }
    340339       
     
    866865        usb_hid_report_path_set_report_id(path, 0);
    867866       
    868         kbd_dev->key_count = usb_hid_report_size(
    869             hid_dev->report, 0, USB_HID_REPORT_TYPE_INPUT);
     867        kbd_dev->key_count = usb_hid_report_input_length(
     868            hid_dev->report, path,
     869            USB_HID_PATH_COMPARE_END | USB_HID_PATH_COMPARE_USAGE_PAGE_ONLY);
    870870        usb_hid_report_path_free(path);
    871871       
     
    908908            kbd_dev->led_path, USB_HIDUT_PAGE_LED, 0);
    909909       
    910         kbd_dev->led_output_size = usb_hid_report_size(hid_dev->report,
    911             0, USB_HID_REPORT_TYPE_OUTPUT);
     910        kbd_dev->led_output_size = usb_hid_report_output_size(hid_dev->report,
     911            kbd_dev->led_path,
     912            USB_HID_PATH_COMPARE_END | USB_HID_PATH_COMPARE_USAGE_PAGE_ONLY);
    912913       
    913914        usb_log_debug("Output report size (in items): %zu\n",
Note: See TracChangeset for help on using the changeset viewer.