Changeset da17cf0 in mainline
- Timestamp:
- 2011-02-07T11:39:52Z (14 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 9a818a9
- Parents:
- 4192d3d6
- Location:
- uspace/drv/uhci-hcd
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/drv/uhci-hcd/tracker.c
r4192d3d6 rda17cf0 288 288 free(instance); 289 289 } 290 /* DEPRECATED FUNCTIONS NEEDED BY THE OLD API */ 291 void tracker_control_setup_old(tracker_t *instance) 292 { 293 assert(instance); 294 assert(instance->buffer_offset == 0); 295 instance->packet_size = SETUP_PACKET_DATA_SIZE; 296 memcpy(instance->packet, instance->buffer, SETUP_PACKET_DATA_SIZE); 297 transfer_descriptor_init(instance->td, DEFAULT_ERROR_COUNT, 298 SETUP_PACKET_DATA_SIZE, false, instance->target, USB_PID_SETUP, 299 instance->packet); 300 instance->buffer_offset += SETUP_PACKET_DATA_SIZE; 301 instance->next_step = tracker_call_out_and_dispose; 302 //TODO: add to scheduler 303 } 304 305 void tracker_control_write_data_old(tracker_t *instance) 306 { 307 assert(instance); 308 assert(instance->max_packet_size == instance->buffer_size); 309 memcpy(instance->packet, instance->buffer, instance->max_packet_size); 310 instance->packet_size = instance->max_packet_size; 311 transfer_descriptor_init(instance->td, DEFAULT_ERROR_COUNT, 312 instance->packet_size, false, instance->target, USB_PID_OUT, 313 instance->packet); 314 instance->next_step = tracker_call_out_and_dispose; 315 } 316 317 void tracker_control_read_data_old(tracker_t *instance) 318 { 319 assert(instance); 320 assert(instance->max_packet_size == instance->buffer_size); 321 instance->packet_size = instance->max_packet_size; 322 transfer_descriptor_init(instance->td, DEFAULT_ERROR_COUNT, 323 instance->packet_size, false, instance->target, USB_PID_IN, 324 instance->packet); 325 instance->next_step = tracker_call_in_and_dispose; 326 } 327 328 void tracker_control_write_status_old(tracker_t *instance) 329 { 330 assert(instance); 331 assert(instance->max_packet_size == 0); 332 assert(instance->buffer_size == 0); 333 assert(instance->packet == NULL); 334 335 instance->packet_size = instance->max_packet_size; 336 transfer_descriptor_init(instance->td, DEFAULT_ERROR_COUNT, 337 instance->packet_size, false, instance->target, USB_PID_IN, 338 instance->packet); 339 instance->next_step = tracker_call_in_and_dispose; 340 } 341 342 void tracker_control_read_status_old(tracker_t *instance) 343 { 344 assert(instance); 345 assert(instance->max_packet_size == 0); 346 assert(instance->buffer_size == 0); 347 assert(instance->packet == NULL); 348 349 instance->packet_size = instance->max_packet_size; 350 transfer_descriptor_init(instance->td, DEFAULT_ERROR_COUNT, 351 instance->packet_size, false, instance->target, USB_PID_OUT, 352 instance->packet); 353 instance->next_step = tracker_call_out_and_dispose; 354 } 290 355 /** 291 356 * @} -
uspace/drv/uhci-hcd/tracker.h
r4192d3d6 rda17cf0 91 91 void tracker_call_out_and_dispose(tracker_t *instance); 92 92 93 /* DEPRECATED FUNCTIONS NEEDED BY THE OLD API */ 94 void tracker_control_setup_old(tracker_t *instance); 95 96 void tracker_control_write_data_old(tracker_t *instance); 97 98 void tracker_control_read_data_old(tracker_t *instance); 99 100 void tracker_control_write_status_old(tracker_t *instance); 101 102 void tracker_control_read_status_old(tracker_t *instance); 93 103 #endif 94 104 /**
Note:
See TracChangeset
for help on using the changeset viewer.