Changeset 21be46a in mainline for uspace/lib/usbhost/include/usb/host/hcd.h
- Timestamp:
- 2012-12-20T11:46:26Z (13 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 8f68913f
- Parents:
- 9c7ed9c
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/usbhost/include/usb/host/hcd.h
r9c7ed9c r21be46a 70 70 }; 71 71 72 73 /** Initialize hcd_t structure. 74 * Initializes device and endpoint managers. Sets data and hook pointer to NULL. 75 * @param hcd hcd_t structure to initialize, non-null. 76 * @param bandwidth Available bandwidth, passed to endpoint manager. 77 * @param bw_count Bandwidth compute function, passed to endpoint manager. 78 */ 79 static inline void hcd_init(hcd_t *hcd, usb_speed_t max_speed, size_t bandwidth, 80 bw_count_func_t bw_count) 81 { 82 assert(hcd); 83 usb_device_manager_init(&hcd->dev_manager, max_speed); 84 usb_endpoint_manager_init(&hcd->ep_manager, bandwidth, bw_count); 85 list_initialize(&hcd->devices); 86 87 hcd->private_data = NULL; 88 hcd->schedule = NULL; 89 hcd->ep_add_hook = NULL; 90 hcd->ep_remove_hook = NULL; 91 } 72 void hcd_init(hcd_t *hcd, usb_speed_t max_speed, size_t bandwidth, 73 bw_count_func_t bw_count); 92 74 93 75 static inline void hcd_set_implementation(hcd_t *hcd, void *data,
Note:
See TracChangeset
for help on using the changeset viewer.