Changeset 620c710 in mainline for uspace/drv/bus/usb/ohci/ohci_endpoint.c
- Timestamp:
- 2011-08-25T14:21:57Z (13 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 961c29e8
- Parents:
- e20eaed
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/drv/bus/usb/ohci/ohci_endpoint.c
re20eaed r620c710 34 34 #include "utils/malloc32.h" 35 35 #include "ohci_endpoint.h" 36 #include "hc.h" 36 37 37 38 /** Callback to set toggle on ED. … … 65 66 * @param[in] hcd_ep endpoint structure 66 67 */ 67 static void ohci_e p_destroy(void *ohci_ep)68 static void ohci_endpoint_fini(endpoint_t *ep) 68 69 { 69 if (ohci_ep) { 70 ohci_endpoint_t *instance = ohci_ep; 70 ohci_endpoint_t *instance = ep->hc_data.data; 71 hc_dequeue_endpoint(instance->hcd->private_data, ep); 72 if (instance) { 71 73 free32(instance->ed); 72 74 free32(instance->td); … … 80 82 * @return pointer to a new hcd endpoint structure, NULL on failure. 81 83 */ 82 int ohci_endpoint_ assign(hcd_t *hcd, endpoint_t *ep)84 int ohci_endpoint_init(hcd_t *hcd, endpoint_t *ep) 83 85 { 84 86 assert(ep); … … 103 105 ed_set_td(ohci_ep->ed, ohci_ep->td); 104 106 endpoint_set_hc_data( 105 ep, ohci_ep, ohci_ep_destroy, ohci_ep_toggle_get, ohci_ep_toggle_set); 106 107 ep, ohci_ep, ohci_endpoint_fini, ohci_ep_toggle_get, ohci_ep_toggle_set); 108 ohci_ep->hcd = hcd; 109 hc_enqueue_endpoint(hcd->private_data, ep); 107 110 return EOK; 108 111 }
Note:
See TracChangeset
for help on using the changeset viewer.