Changeset 2a5b62b in mainline
- Timestamp:
- 2011-10-15T00:09:46Z (13 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 8a121b1
- Parents:
- 1526c174
- Location:
- uspace/drv/bus/usb/usbhid
- Files:
-
- 8 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/drv/bus/usb/usbhid/generic/hiddev.c
r1526c174 r2a5b62b 197 197 const int ret = ddf_fun_unbind(fun); 198 198 if (ret != EOK) { 199 usb_log_error(" ailed to unbind generic hid fun.\n");199 usb_log_error("Failed to unbind generic hid fun.\n"); 200 200 return; 201 201 } 202 usb_log_debug2("%s unbound.\n", fun->name); 202 203 ddf_fun_destroy(fun); 203 204 } -
uspace/drv/bus/usb/usbhid/kbd/kbddev.c
r1526c174 r2a5b62b 502 502 503 503 if (kbd_dev == NULL) { 504 usb_log_ fatal("No memory!\n");504 usb_log_error("No memory!\n"); 505 505 return NULL; 506 506 } … … 624 624 625 625 if (kbd_dev->keys == NULL) { 626 usb_log_ fatal("No memory!\n");626 usb_log_error("No memory!\n"); 627 627 free(kbd_dev); 628 628 return ENOMEM; … … 633 633 634 634 if (kbd_dev->keys_old == NULL) { 635 usb_log_ fatal("No memory!\n");635 usb_log_error("No memory!\n"); 636 636 free(kbd_dev->keys); 637 637 free(kbd_dev); … … 797 797 usb_log_warning("Failed to unbind kbd function.\n"); 798 798 } else { 799 usb_log_debug2("%s unbound.\n", kbd_dev->fun->name); 799 800 kbd_dev->fun->driver_data = NULL; 800 801 ddf_fun_destroy(kbd_dev->fun); … … 811 812 812 813 if (data != NULL) { 813 usb_kbd_t *kbd_dev = (usb_kbd_t *)data;814 usb_kbd_t *kbd_dev = data; 814 815 if (usb_kbd_is_initialized(kbd_dev)) { 815 816 usb_kbd_mark_unusable(kbd_dev); 816 } else { 817 /* wait for autorepeat */ 818 async_usleep(CHECK_DELAY); 817 819 usb_kbd_destroy(kbd_dev); 818 820 } -
uspace/drv/bus/usb/usbhid/kbd/kbdrepeat.c
r1526c174 r2a5b62b 46 46 47 47 48 /** Delay between auto-repeat state checks when no key is being repeated. */49 static unsigned int CHECK_DELAY = 10000;50 48 51 49 /*----------------------------------------------------------------------------*/ … … 79 77 // check if the kbd structure is usable 80 78 if (!usb_kbd_is_initialized(kbd)) { 81 if (usb_kbd_is_ready_to_destroy(kbd)) { 82 usb_kbd_destroy(kbd); 83 } 79 usb_log_warning("kbd not ready, exiting autorepeat.\n"); 84 80 return; 85 81 } -
uspace/drv/bus/usb/usbhid/kbd/kbdrepeat.h
r1526c174 r2a5b62b 37 37 #define USB_HID_KBDREPEAT_H_ 38 38 39 /** Delay between auto-repeat state checks when no key is being repeated. */ 40 #define CHECK_DELAY 10000 41 39 42 struct usb_kbd_t; 40 43 -
uspace/drv/bus/usb/usbhid/main.c
r1526c174 r2a5b62b 206 206 assert(!hid_dev->running); 207 207 usb_hid_destroy(hid_dev); 208 usb_log_debug2("%s destruction complete.\n", dev->ddf_dev->name); 208 209 return EOK; 209 210 } -
uspace/drv/bus/usb/usbhid/multimedia/multimedia.c
r1526c174 r2a5b62b 249 249 usb_log_error("Failed to unbind multim function.\n"); 250 250 } else { 251 usb_log_debug2("%s unbound.\n", multim_dev->fun->name); 251 252 ddf_fun_destroy(multim_dev->fun); 252 253 } -
uspace/drv/bus/usb/usbhid/usbhid.c
r1526c174 r2a5b62b 418 418 419 419 if (hid_dev == NULL) { 420 usb_log_ fatal("No memory!\n");420 usb_log_error("No memory!\n"); 421 421 return NULL; 422 422 } … … 425 425 usb_hid_report_t))); 426 426 if (hid_dev->report == NULL) { 427 usb_log_ fatal("No memory!\n");427 usb_log_error("No memory!\n"); 428 428 free(hid_dev); 429 429 return NULL; … … 631 631 632 632 hid_dev->running = false; 633 // usb_hid_destroy(hid_dev);634 633 } 635 634 -
uspace/drv/bus/usb/usbhid/usbhid.h
r1526c174 r2a5b62b 129 129 130 130 int report_nr; 131 bool running;131 volatile bool running; 132 132 }; 133 133
Note:
See TracChangeset
for help on using the changeset viewer.