Changeset 2b61945 in mainline for uspace/drv/bus/usb/xhci/bus.h


Ignore:
Timestamp:
2017-10-22T03:47:41Z (7 years ago)
Author:
Ondřej Hlavatý <aearsis@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
2e5aea1
Parents:
766043c
Message:

xhci: use device_t for bookkeeping

This started as a little refactoring to move active transfer batch to endpoint. Finding the EP in handler needs devices indexed by slot id. Then I found out we do not use the device_t extendable mechanism. Then there were a lot of errors found while doing all this…

File:
1 edited

Legend:

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

    r766043c r2b61945  
    4343
    4444typedef struct xhci_hc xhci_hc_t;
     45typedef struct xhci_device xhci_device_t;
    4546
    4647/** Endpoint management structure */
     
    4849        bus_t base;             /**< Inheritance. Keep this first. */
    4950
    50         /** TODO: some mechanism to keep endpoints alive :)
    51          * We may inspire in the usb2_bus, but keep in mind xHCI have much
    52          * larger address space, thus simple array of lists for all available
    53          * addresses can be just too big.
    54          */
     51        xhci_device_t **devices_by_slot;        /**< Devices by Slot ID */
    5552
    56         hash_table_t devices;
     53        /** TODO: Do we really need this? */
     54        hash_table_t devices;           /**< Devices by address */
    5755} xhci_bus_t;
    5856
    59 int xhci_bus_init(xhci_bus_t *);
     57int xhci_bus_init(xhci_bus_t *, xhci_hc_t *);
    6058void xhci_bus_fini(xhci_bus_t *);
    6159
Note: See TracChangeset for help on using the changeset viewer.