Changeset 682c9354 in mainline for uspace/drv/bus/usb/xhci/endpoint.h
- Timestamp:
- 2018-01-20T15:32:12Z (7 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- abb5d08
- Parents:
- 129b821f
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/drv/bus/usb/xhci/endpoint.h
r129b821f r682c9354 45 45 #include <ddf/driver.h> 46 46 47 #include "device.h" 47 48 #include "isoch.h" 48 49 #include "transfers.h" … … 105 106 (usb_str_transfer_type((ep).base.transfer_type)) 106 107 107 typedef struct xhci_device {108 device_t base; /**< Inheritance. Keep this first. */109 110 /** Slot ID assigned to the device by xHC. */111 uint32_t slot_id;112 113 /** Corresponding port on RH */114 uint8_t rh_port;115 116 /** USB Tier of the device */117 uint8_t tier;118 119 /** Route string */120 uint32_t route_str;121 122 /** Place to store the allocated context */123 dma_buffer_t dev_ctx;124 125 /** Hub specific information. Valid only if the device is_hub. */126 bool is_hub;127 uint8_t num_ports;128 uint8_t tt_think_time;129 } xhci_device_t;130 131 #define XHCI_DEV_FMT "(%s, slot %d)"132 #define XHCI_DEV_ARGS(dev) ddf_fun_get_name((dev).base.fun), (dev).slot_id133 134 108 int xhci_endpoint_type(xhci_endpoint_t *ep); 135 109 136 int xhci_endpoint_init(xhci_endpoint_t *, device_t *, const usb_endpoint_descriptors_t *); 137 void xhci_endpoint_fini(xhci_endpoint_t *); 110 endpoint_t *xhci_endpoint_create(device_t *, const usb_endpoint_descriptors_t *); 111 int xhci_endpoint_register(endpoint_t *); 112 void xhci_endpoint_unregister(endpoint_t *); 113 void xhci_endpoint_destroy(endpoint_t *); 138 114 139 115 void xhci_endpoint_free_transfer_ds(xhci_endpoint_t *xhci_ep); … … 144 120 void xhci_setup_endpoint_context(xhci_endpoint_t *, xhci_ep_ctx_t *); 145 121 int xhci_endpoint_clear_halt(xhci_endpoint_t *, unsigned); 146 147 static inline xhci_device_t * xhci_device_get(device_t *dev)148 {149 assert(dev);150 return (xhci_device_t *) dev;151 }152 122 153 123 static inline xhci_endpoint_t * xhci_endpoint_get(endpoint_t *ep)
Note:
See TracChangeset
for help on using the changeset viewer.