Changeset 4069f5c in mainline for uspace/drv/bus/usb/vhc/connhost.c


Ignore:
Timestamp:
2011-07-17T09:52:42Z (13 years ago)
Author:
Petr Koupy <petr.koupy@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
64639256, ca1f1ec
Parents:
27eddb52 (diff), 4118f5f (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

Merge mainline changes.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/drv/bus/usb/vhc/connhost.c

    r27eddb52 r4069f5c  
    141141    size_t max_packet_size, unsigned int interval)
    142142{
    143         VHC_DATA(vhc, fun);
    144 
    145         endpoint_t *ep = malloc(sizeof(endpoint_t));
     143        /* TODO: Use usb_endpoint_manager_add_ep */
     144        VHC_DATA(vhc, fun);
     145
     146        endpoint_t *ep = endpoint_get(
     147            address, endpoint, direction, transfer_type, USB_SPEED_FULL, 1);
    146148        if (ep == NULL) {
    147149                return ENOMEM;
    148150        }
    149151
    150         int rc = endpoint_init(ep, address, endpoint, direction, transfer_type,
    151             USB_SPEED_FULL, 1);
    152         if (rc != EOK) {
    153                 free(ep);
    154                 return rc;
    155         }
    156 
    157         rc = usb_endpoint_manager_register_ep(&vhc->ep_manager, ep, 1);
     152        int rc = usb_endpoint_manager_register_ep(&vhc->ep_manager, ep, 1);
    158153        if (rc != EOK) {
    159154                endpoint_destroy(ep);
Note: See TracChangeset for help on using the changeset viewer.