Changeset 2759c52 in mainline
- Timestamp:
- 2011-04-13T11:14:28Z (14 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 5a2c42b
- Parents:
- 6bb0f43
- Location:
- uspace/drv/ohci
- Files:
-
- 2 added
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/drv/ohci/Makefile
r6bb0f43 r2759c52 35 35 batch.c \ 36 36 hc.c \ 37 hcd_endpoint.c \ 37 38 iface.c \ 38 39 main.c \ -
uspace/drv/ohci/hc.c
r6bb0f43 r2759c52 43 43 44 44 #include "hc.h" 45 #include "hcd_endpoint.h" 45 46 46 47 static int interrupt_emulator(hc_t *instance); … … 149 150 } 150 151 152 hcd_endpoint_t *hcd_ep = hcd_endpoint_assign(ep); 153 if (hcd_ep == NULL) { 154 free(ep); 155 return ENOMEM; 156 } 157 // TODO: enqueue hcd_ep here! 158 151 159 ret = usb_endpoint_manager_register_ep(&instance->ep_manager, ep, size); 152 160 if (ret != EOK) { … … 159 167 usb_endpoint_t endpoint, usb_direction_t direction) 160 168 { 169 endpoint_t *ep = usb_endpoint_manager_get_ep(&instance->ep_manager, 170 address, endpoint, direction, NULL); 171 if (ep == NULL) { 172 usb_log_error("Endpoint unregister failed.\n"); 173 return ENOENT; 174 } 175 176 hcd_endpoint_t *hcd_ep = hcd_endpoint_get(ep); 177 if (hcd_ep) { 178 // TODO: dequeue hcd_ep here! 179 hcd_endpoint_clear(ep); 180 } else { 181 usb_log_warning("Endpoint without hcd equivalent structure.\n"); 182 } 161 183 return usb_endpoint_manager_unregister_ep(&instance->ep_manager, 162 184 address, endpoint, direction);
Note:
See TracChangeset
for help on using the changeset viewer.