Changeset 56db65d in mainline for uspace/lib/usbhost/src/hcd.c


Ignore:
Timestamp:
2017-10-24T11:06:32Z (6 years ago)
Author:
Ondřej Hlavatý <aearsis@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
0206d35
Parents:
894f58c
Message:

usbhost: provide usb_endpoint_desc_t to bus when registering endpoint

This finishes the path of arbitrary information fetched from device all the way down to registering the endpoint in the bus.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/usbhost/src/hcd.c

    r894f58c r56db65d  
    8787        assert(device->address == target.address);
    8888
     89        if (!hcd->ops.schedule) {
     90                usb_log_error("HCD does not implement scheduler.\n");
     91                return ENOTSUP;
     92        }
     93
    8994        endpoint_t *ep = bus_find_endpoint(hcd->bus, device, target, direction);
    9095        if (ep == NULL) {
     
    9398                return ENOENT;
    9499        }
     100
     101        // TODO cut here aka provide helper to call with instance of endpoint_t in hand
    95102
    96103        usb_log_debug2("%s %d:%d %zu(%zu).\n",
     
    104111                    ep->target.address, ep->target.endpoint, name, bw, ep->bandwidth);
    105112                return ENOSPC;
    106         }
    107         if (!hcd->ops.schedule) {
    108                 usb_log_error("HCD does not implement scheduler.\n");
    109                 return ENOTSUP;
    110113        }
    111114
Note: See TracChangeset for help on using the changeset viewer.