Changeset a4e26882 in mainline for uspace/drv/bus/usb/xhci/bus.c


Ignore:
Timestamp:
2017-10-22T16:37:44Z (7 years ago)
Author:
Petr Manek <petr.manek@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
4594baa
Parents:
2c091a6
Message:

Very rudimentary support for device disconnection.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/drv/bus/usb/xhci/bus.c

    r2c091a6 ra4e26882  
    118118        xhci_device_t *xhci_dev = xhci_device_get(dev);
    119119
    120         // TODO: Release remaining EPs
     120        /* Release remaining endpoints. */
     121        for (size_t i = 0; i < ARRAY_SIZE(xhci_dev->endpoints); ++i) {
     122                if (!xhci_dev->endpoints[i])
     123                        continue;
     124
     125                // FIXME: ignoring return code
     126                bus_release_endpoint(&bus->base, &xhci_dev->endpoints[i]->base);
     127        }
    121128
    122129        hashed_device_t *hashed_dev;
     
    270277        xhci_bus_t *bus = bus_to_xhci_bus(bus_base);
    271278        assert(bus);
    272        
     279
    273280        xhci_endpoint_t *ep;
    274281        int res = xhci_endpoint_find_by_target(bus, target, &ep);
Note: See TracChangeset for help on using the changeset viewer.