Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/app/mkbd/main.c

    re540424a rb7fd2a0  
    4444#include <devman.h>
    4545#include <loc.h>
    46 #include <usb/dev/hub.h>
    4746#include <usbhid_iface.h>
    4847#include <usb/dev/pipes.h>
     
    6160static async_sess_t *dev_sess = NULL;
    6261
    63 static int initialize_report_parser(async_sess_t *dev_sess,
     62static errno_t initialize_report_parser(async_sess_t *dev_sess,
    6463    usb_hid_report_t **report)
    6564{
     
    6867                return ENOMEM;
    6968       
    70         int rc = usb_hid_report_init(*report);
     69        errno_t rc = usb_hid_report_init(*report);
    7170        if (rc != EOK) {
    7271                usb_hid_report_deinit(*report);
     
    132131       
    133132        uint8_t report_id;
    134         int rc = usb_hid_parse_report(report, buffer, size, &report_id);
     133        errno_t rc = usb_hid_parse_report(report, buffer, size, &report_id);
    135134        if (rc != EOK)
    136135                return;
     
    166165}
    167166
    168 static int wait_for_quit_fibril(void *arg)
     167static errno_t wait_for_quit_fibril(void *arg)
    169168{
    170169        console_ctrl_t *con = console_init(stdin, stdout);
     
    219218        devman_handle_t dev_handle = 0;
    220219       
    221         int rc = usb_resolve_device_handle(devpath, NULL, NULL, &dev_handle);
     220        errno_t rc = usb_resolve_device_handle(devpath, &dev_handle);
    222221        if (rc != EOK) {
    223222                printf("Device not found or not of USB kind: %s.\n",
     
    238237        rc = devman_fun_get_path(dev_handle, path, MAX_PATH_LENGTH);
    239238        if (rc != EOK) {
     239                printf(NAME ": failed to get path (handle %"
     240                       PRIun "): %s.\n", dev_handle, str_error(errno));
    240241                return ENOMEM;
    241242        }
     
    263264        uint8_t *event = (uint8_t *)malloc(size);
    264265        if (event == NULL) {
     266                printf("Out of memory.\n");
    265267                // TODO: hangup phone?
    266268                return ENOMEM;
Note: See TracChangeset for help on using the changeset viewer.