Changeset 8790650 in mainline
- Timestamp:
- 2011-04-09T20:44:50Z (13 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 501e5df
- Parents:
- ff0e354
- Location:
- uspace/drv/ohci
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/drv/ohci/batch.c
rff0e354 r8790650 227 227 ed_init(data->ed, instance->ep); 228 228 ed_add_tds(data->ed, &data->tds[0], &data->tds[data->td_count - 1]); 229 usb_log_debug("Created ED: %x:%x:%x:%x.\n", data->ed->status, 230 data->ed->td_tail, data->ed->td_head, data->ed->next); 229 usb_log_debug("Created ED(%p): %x:%x:%x:%x.\n", data->ed, 230 data->ed->status, data->ed->td_tail, data->ed->td_head, 231 data->ed->next); 231 232 int toggle = 0; 232 233 /* setup stage */ -
uspace/drv/ohci/hc.c
rff0e354 r8790650 108 108 ret, str_error(ret)); 109 109 110 111 110 hc_gain_control(instance); 111 ret = hc_init_memory(instance); 112 CHECK_RET_RETURN(ret, "Failed to create OHCI memory structures:%s.\n", 113 ret, str_error(ret)); 114 hc_init_hw(instance); 112 115 113 116 rh_init(&instance->rh, dev, instance->registers); 114 115 hc_init_memory(instance);116 hc_init_hw(instance);117 117 118 118 if (!interrupts) { … … 122 122 } 123 123 124 /* TODO: implement */125 124 return EOK; 126 125 } … … 141 140 switch (batch->transfer_type) { 142 141 case USB_TRANSFER_CONTROL: 142 instance->registers->control &= ~C_CLE; 143 143 instance->registers->command_status |= CS_CLF; 144 usb_log_debug2("Set control transfer filled: %x.\n", 145 instance->registers->command_status); 146 instance->registers->control |= C_CLE; 144 147 break; 145 148 case USB_TRANSFER_BULK: 146 149 instance->registers->command_status |= CS_BLF; 150 usb_log_debug2("Set bulk transfer filled: %x.\n", 151 instance->registers->command_status); 147 152 break; 148 153 default: … … 161 166 162 167 usb_log_info("OHCI interrupt: %x.\n", status); 168 163 169 164 170 LIST_INITIALIZE(done); … … 328 334 { 329 335 assert(instance); 330 /* init queues */336 /* Init queues */ 331 337 hc_init_transfer_lists(instance); 332 338 333 /* init HCCA */339 /*Init HCCA */ 334 340 instance->hcca = malloc32(sizeof(hcca_t)); 335 341 if (instance->hcca == NULL) … … 337 343 bzero(instance->hcca, sizeof(hcca_t)); 338 344 instance->registers->hcca = addr_to_phys(instance->hcca); 339 340 /* use queues */ 345 usb_log_debug2("OHCI HCCA initialized at %p(%p).\n", 346 instance->hcca, instance->registers->hcca); 347 348 /* Use queues */ 341 349 instance->registers->bulk_head = instance->transfers_bulk.list_head_pa; 350 usb_log_debug2("Bulk HEAD set to: %p(%p).\n", 351 instance->transfers_bulk.list_head, 352 instance->transfers_bulk.list_head_pa); 353 342 354 instance->registers->control_head = 343 355 instance->transfers_control.list_head_pa; 356 usb_log_debug2("Control HEAD set to: %p(%p).\n", 357 instance->transfers_control.list_head, 358 instance->transfers_control.list_head_pa); 344 359 345 360 unsigned i = 0; … … 348 363 instance->transfers_interrupt.list_head_pa; 349 364 } 365 usb_log_debug2("Interrupt HEADs set to: %p(%p).\n", 366 instance->transfers_interrupt.list_head, 367 instance->transfers_interrupt.list_head_pa); 350 368 351 369 return EOK; -
uspace/drv/ohci/hw_struct/endpoint_descriptor.c
rff0e354 r8790650 42 42 bzero(instance, sizeof(ed_t)); 43 43 if (ep == NULL) { 44 instance->status |= ED_STATUS_K_FLAG;44 instance->status = ED_STATUS_K_FLAG; 45 45 return; 46 46 } -
uspace/drv/ohci/transfer_list.c
rff0e354 r8790650 122 122 usb_transfer_batch_t *first = list_get_instance( 123 123 instance->batch_list.next, usb_transfer_batch_t, link); 124 usb_log_debug("Batch(%p) added to queue %s, first is %p.\n", 125 batch, instance->name, first); 124 usb_log_debug("Batch(%p) added to list %s, first is %p(%p).\n", 125 batch, instance->name, first, batch_ed(first)); 126 if (last_ed == instance->list_head) { 127 usb_log_debug2("%s head ED: %x:%x:%x:%x.\n", instance->name, 128 last_ed->status, last_ed->td_tail, last_ed->td_head, 129 last_ed->next); 130 } 126 131 fibril_mutex_unlock(&instance->guard); 127 132 }
Note:
See TracChangeset
for help on using the changeset viewer.