Fork us on GitHub Follow us on Facebook Follow us on Twitter

Changeset a6610d4 in mainline


Ignore:
Timestamp:
2011-04-12T18:57:45Z (11 years ago)
Author:
Lubos Slovak <lubos.slovak@…>
Branches:
lfn, master, serial
Children:
e3b5129
Parents:
8f8f34ad
Message:

Keyboard callback made static, removed unused report ID

File:
1 edited

Legend:

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

    r8f8f34ad ra6610d4  
    176176
    177177/*----------------------------------------------------------------------------*/
     178
     179static void usb_kbd_process_keycodes(const uint8_t *key_codes, size_t count,
     180    uint8_t report_id, void *arg);
     181
     182static const usb_hid_report_in_callbacks_t usb_kbd_parser_callbacks = {
     183        .keyboard = usb_kbd_process_keycodes
     184};
     185
     186/*----------------------------------------------------------------------------*/
    178187/* Keyboard layouts                                                           */
    179188/*----------------------------------------------------------------------------*/
     
    630639{
    631640        assert(hid_dev->parser != NULL);
    632        
    633         usb_hid_report_in_callbacks_t *callbacks =
    634             (usb_hid_report_in_callbacks_t *)malloc(
    635                 sizeof(usb_hid_report_in_callbacks_t));
    636        
    637         callbacks->keyboard = usb_kbd_process_keycodes;
    638641
    639642        usb_log_debug("Calling usb_hid_parse_report() with "
     
    644647        usb_hid_report_path_t *path = usb_hid_report_path();
    645648        usb_hid_report_path_append_item(path, USB_HIDUT_PAGE_KEYBOARD, 0);
    646         usb_hid_report_path_set_report_id(path, 0);
     649        //usb_hid_report_path_set_report_id(path, 0);
    647650       
    648651        int rc = usb_hid_parse_report(hid_dev->parser, buffer,
    649652            actual_size, path,
    650653            USB_HID_PATH_COMPARE_END | USB_HID_PATH_COMPARE_USAGE_PAGE_ONLY,
    651             callbacks, hid_dev);
     654            &usb_kbd_parser_callbacks, hid_dev);
    652655
    653656        usb_hid_report_path_free(path);
Note: See TracChangeset for help on using the changeset viewer.