Lines Matching refs:ehcip

49 				ehci_state_t		*ehcip,
53 ehci_state_t *ehcip,
57 ehci_state_t *ehcip,
60 ehci_state_t *ehcip,
63 ehci_state_t *ehcip,
66 ehci_state_t *ehcip,
70 ehci_state_t *ehcip,
74 ehci_state_t *ehcip,
78 ehci_state_t *ehcip,
82 ehci_state_t *ehcip,
85 ehci_state_t *ehcip,
89 ehci_state_t *ehcip,
93 ehci_state_t *ehcip,
97 ehci_state_t *ehcip,
100 ehci_state_t *ehcip,
103 ehci_state_t *ehcip,
106 ehci_state_t *ehcip,
111 ehci_state_t *ehcip,
114 ehci_state_t *ehcip,
119 ehci_state_t *ehcip,
125 ehci_state_t *ehcip,
130 ehci_state_t *ehcip,
136 ehci_state_t *ehcip,
141 ehci_state_t *ehcip,
145 ehci_state_t *ehcip,
149 ehci_state_t *ehcip,
152 ehci_state_t *ehcip,
157 ehci_state_t *ehcip,
162 ehci_state_t *ehcip,
166 ehci_state_t *ehcip,
174 ehci_state_t *ehcip);
176 ehci_state_t *ehcip,
185 ehci_state_t *ehcip,
189 ehci_state_t *ehcip,
192 ehci_state_t *ehcip,
195 ehci_state_t *ehcip,
198 ehci_state_t *ehcip,
201 ehci_state_t *ehcip,
204 ehci_state_t *ehcip,
209 ehci_state_t *ehcip,
214 ehci_state_t *ehcip,
219 ehci_state_t *ehcip,
225 ehci_state_t *ehcip,
228 ehci_state_t *ehcip,
232 ehci_state_t *ehcip,
237 ehci_state_t *ehcip,
239 static void ehci_start_timer(ehci_state_t *ehcip,
242 ehci_state_t *ehcip,
246 ehci_state_t *ehcip,
249 ehci_state_t *ehcip,
255 ehci_state_t *ehcip,
260 ehci_state_t *ehcip,
263 ehci_state_t *ehcip,
266 ehci_state_t *ehcip,
269 ehci_state_t *ehcip,
272 ehci_state_t *ehcip,
275 ehci_state_t *ehcip,
278 ehci_state_t *ehcip,
282 ehci_state_t *ehcip,
304 ehci_state_t *ehcip,
311 USB_DPRINTF_L4(PRINT_MASK_ALLOC, ehcip->ehci_log_hdl,
314 ASSERT(mutex_owned(&ehcip->ehci_int_mutex));
334 state = Get_QH(ehcip->ehci_qh_pool_addr[i].qh_state);
341 USB_DPRINTF_L4(PRINT_MASK_ALLOC, ehcip->ehci_log_hdl,
345 USB_DPRINTF_L2(PRINT_MASK_ALLOC, ehcip->ehci_log_hdl,
350 qh = &ehcip->ehci_qh_pool_addr[i];
353 USB_DPRINTF_L4(PRINT_MASK_ALLOC, ehcip->ehci_log_hdl,
364 if ((ehci_initialize_dummy(ehcip,
372 ehci_unpack_endpoint(ehcip, ph, qh);
387 ehci_print_qh(ehcip, qh);
402 ehci_state_t *ehcip,
413 USB_DPRINTF_L4(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
534 ehci_state_t *ehcip,
539 USB_DPRINTF_L4(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
542 ASSERT(mutex_owned(&ehcip->ehci_int_mutex));
547 ehci_insert_async_qh(ehcip, pp);
548 ehcip->ehci_open_async_count++;
551 ehci_insert_intr_qh(ehcip, pp);
552 ehcip->ehci_open_periodic_count++;
556 ehcip->ehci_open_periodic_count++;
570 ehci_state_t *ehcip,
578 USB_DPRINTF_L4(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
581 ASSERT(mutex_owned(&ehcip->ehci_int_mutex));
586 qh_addr = ehci_qh_cpu_to_iommu(ehcip, qh);
589 async_head_qh = ehcip->ehci_head_of_async_sched_list;
600 ehcip->ehci_head_of_async_sched_list = qh;
621 if ((ehcip->ehci_vendor_id == PCI_VENDOR_ULi_M1575) &&
622 (ehcip->ehci_device_id == PCI_DEVICE_ULi_M1575) &&
631 USB_DPRINTF_L2(PRINT_MASK_ATTA, ehcip->ehci_log_hdl,
643 next_qh = ehci_qh_iommu_to_cpu(ehcip,
649 Set_QH(qh->qh_prev, ehci_qh_cpu_to_iommu(ehcip, async_head_qh));
652 Set_QH(next_qh->qh_prev, ehci_qh_cpu_to_iommu(ehcip, qh));
669 ehci_state_t *ehcip,
676 USB_DPRINTF_L4(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
679 ASSERT(mutex_owned(&ehcip->ehci_int_mutex));
691 lattice_qh = &ehcip->ehci_qh_pool_addr[hnode];
695 ehcip, (Get_QH(lattice_qh->qh_link_ptr) & EHCI_QH_LINK_PTR));
698 Set_QH(qh->qh_prev, ehci_qh_cpu_to_iommu(ehcip, lattice_qh));
708 ehci_qh_cpu_to_iommu(ehcip, qh));
718 (ehci_qh_cpu_to_iommu(ehcip, qh) | EHCI_QH_LINK_REF_QH));
736 ehci_state_t *ehcip,
744 USB_DPRINTF_L4(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
748 ehci_print_qh(ehcip, qh);
750 ASSERT(mutex_owned(&ehcip->ehci_int_mutex));
759 &ehcip->ehci_int_mutex);
763 Sync_QH_QTD_Pool(ehcip);
801 ehci_halt_hs_qh(ehcip, pp, qh);
804 ehci_halt_fls_intr_qh(ehcip, qh);
806 ehci_halt_fls_ctrl_and_bulk_qh(ehcip, pp, qh);
815 Sync_QH_QTD_Pool(ehcip);
817 ehci_print_qh(ehcip, qh);
821 USB_DPRINTF_L1(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
825 ehci_print_qh(ehcip, qh);
828 ehcip->ehci_hc_soft_state = EHCI_CTLR_ERROR_STATE;
846 ehci_state_t *ehcip,
852 USB_DPRINTF_L4(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
856 ehci_remove_qh(ehcip, pp, B_FALSE);
857 ehci_toggle_scheduler_on_pipe(ehcip);
863 (void) ehci_wait_for_sof(ehcip);
866 Sync_QH_QTD_Pool(ehcip);
874 ehci_insert_qh(ehcip, ph);
875 ehci_toggle_scheduler_on_pipe(ehcip);
886 ehci_state_t *ehcip,
894 USB_DPRINTF_L4(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
898 ehci_remove_qh(ehcip, pp, B_FALSE);
899 ehci_toggle_scheduler_on_pipe(ehcip);
905 (void) ehci_wait_for_sof(ehcip);
908 Sync_QH_QTD_Pool(ehcip);
922 ehci_clear_tt_buffer(ehcip, ph, qh);
926 ehci_insert_qh(ehcip, ph);
927 ehci_toggle_scheduler_on_pipe(ehcip);
939 ehci_state_t *ehcip,
954 USB_DPRINTF_L4(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
979 mutex_exit(&ehcip->ehci_int_mutex);
1011 USB_DPRINTF_L2(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
1025 USB_DPRINTF_L0(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
1032 mutex_enter(&ehcip->ehci_int_mutex);
1042 ehci_state_t *ehcip,
1049 USB_DPRINTF_L4(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
1059 starting_frame = ehci_get_current_frame_number(ehcip);
1065 Sync_QH_QTD_Pool(ehcip);
1072 (void) ehci_wait_for_sof(ehcip);
1074 Sync_QH_QTD_Pool(ehcip);
1076 frames_past = ehci_get_current_frame_number(ehcip) -
1081 Sync_QH_QTD_Pool(ehcip);
1090 Sync_QH_QTD_Pool(ehcip);
1092 (void) ehci_wait_for_sof(ehcip);
1093 Sync_QH_QTD_Pool(ehcip);
1101 Sync_QH_QTD_Pool(ehcip);
1103 USB_DPRINTF_L4(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
1106 (unsigned long long)(ehci_get_current_frame_number(ehcip) -
1119 ehci_state_t *ehcip,
1125 ASSERT(mutex_owned(&ehcip->ehci_int_mutex));
1127 USB_DPRINTF_L4(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
1135 ehci_remove_async_qh(ehcip, pp, reclaim);
1136 ehcip->ehci_open_async_count--;
1139 ehci_remove_intr_qh(ehcip, pp, reclaim);
1140 ehcip->ehci_open_periodic_count--;
1144 ehcip->ehci_open_periodic_count--;
1158 ehci_state_t *ehcip,
1165 USB_DPRINTF_L4(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
1168 ASSERT(mutex_owned(&ehcip->ehci_int_mutex));
1170 prev_qh = ehci_qh_iommu_to_cpu(ehcip,
1172 next_qh = ehci_qh_iommu_to_cpu(ehcip,
1188 ehcip->ehci_head_of_async_sched_list = NULL;
1189 ASSERT(ehcip->ehci_open_async_count == 1);
1192 if (ehcip->ehci_head_of_async_sched_list == qh) {
1195 ehcip->ehci_head_of_async_sched_list = next_qh;
1208 ehci_insert_qh_on_reclaim_list(ehcip, pp);
1222 ehci_state_t *ehcip,
1229 USB_DPRINTF_L4(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
1232 ASSERT(mutex_owned(&ehcip->ehci_int_mutex));
1234 prev_qh = ehci_qh_iommu_to_cpu(ehcip, Get_QH(qh->qh_prev));
1235 next_qh = ehci_qh_iommu_to_cpu(ehcip,
1259 ehci_insert_qh_on_reclaim_list(ehcip, pp);
1271 ehci_state_t *ehcip,
1278 ASSERT(mutex_owned(&ehcip->ehci_int_mutex));
1285 ehci_get_current_frame_number(ehcip) + MAX_SOF_WAIT_COUNT;
1292 if (ehcip->ehci_reclaim_list) {
1293 next_qh = ehcip->ehci_reclaim_list;
1297 next_qh = ehci_qh_iommu_to_cpu(ehcip,
1302 ehci_qh_cpu_to_iommu(ehcip, qh));
1304 ehcip->ehci_reclaim_list = qh;
1320 ehci_state_t *ehcip,
1325 USB_DPRINTF_L4(PRINT_MASK_ALLOC, ehcip->ehci_log_hdl,
1328 ASSERT(mutex_owned(&ehcip->ehci_int_mutex));
1330 first_dummy_qtd = ehci_qtd_iommu_to_cpu(ehcip,
1336 second_dummy_qtd = ehci_qtd_iommu_to_cpu(ehcip,
1343 ehci_deallocate_qtd(ehcip, second_dummy_qtd);
1346 ehci_deallocate_qtd(ehcip, first_dummy_qtd);
1349 USB_DPRINTF_L4(PRINT_MASK_ALLOC, ehcip->ehci_log_hdl,
1366 ehci_state_t *ehcip,
1371 qh = (uint32_t)ehcip->ehci_qh_pool_cookie.dmac_address +
1372 (uint32_t)((uintptr_t)addr - (uintptr_t)(ehcip->ehci_qh_pool_addr));
1374 ASSERT(qh >= ehcip->ehci_qh_pool_cookie.dmac_address);
1375 ASSERT(qh <= ehcip->ehci_qh_pool_cookie.dmac_address +
1390 ehci_state_t *ehcip,
1401 (addr - ehcip->ehci_qh_pool_cookie.dmac_address) +
1402 (uintptr_t)ehcip->ehci_qh_pool_addr);
1404 ASSERT(qh >= ehcip->ehci_qh_pool_addr);
1405 ASSERT((uintptr_t)qh <= (uintptr_t)ehcip->ehci_qh_pool_addr +
1425 ehci_state_t *ehcip,
1431 first_dummy_qtd = ehci_allocate_qtd_from_pool(ehcip);
1438 second_dummy_qtd = ehci_allocate_qtd_from_pool(ehcip);
1442 ehci_deallocate_qtd(ehcip, first_dummy_qtd);
1448 Set_QH(qh->qh_next_qtd, ehci_qtd_cpu_to_iommu(ehcip,
1452 Set_QH(qh->qh_dummy_qtd, ehci_qtd_cpu_to_iommu(ehcip, first_dummy_qtd));
1456 ehci_qtd_cpu_to_iommu(ehcip, second_dummy_qtd));
1471 ehci_state_t *ehcip,
1499 tw = ehci_allocate_tw_resources(ehcip, pp, ctrl_buf_size,
1513 ehci_state_t *ehcip,
1529 USB_DPRINTF_L4(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
1532 ASSERT(mutex_owned(&ehcip->ehci_int_mutex));
1573 (void) ehci_insert_qtd(ehcip, ctrl, 0, SETUP_SIZE,
1576 USB_DPRINTF_L3(PRINT_MASK_ALLOC, ehcip->ehci_log_hdl,
1609 (void) ehci_insert_qtd(ehcip, ctrl, EHCI_MAX_QTD_BUF_SIZE,
1637 (void) ehci_insert_qtd(ehcip, ctrl, 0, 0,
1641 ehci_start_xfer_timer(ehcip, pp, tw);
1655 ehci_state_t *ehcip,
1666 USB_DPRINTF_L2(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
1681 tw = ehci_allocate_tw_resources(ehcip, pp, bulk_reqp->bulk_len,
1696 ehci_state_t *ehcip,
1708 USB_DPRINTF_L4(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
1712 ASSERT(mutex_owned(&ehcip->ehci_int_mutex));
1724 USB_DPRINTF_L4(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
1774 (void) ehci_insert_qtd(ehcip, ctrl, len, bulk_pkt_size,
1781 ehci_start_xfer_timer(ehcip, pp, tw);
1792 ehci_state_t *ehcip,
1801 USB_DPRINTF_L4(PRINT_MASK_HCDI, ehcip->ehci_log_hdl,
1805 ASSERT(mutex_owned(&ehcip->ehci_int_mutex));
1830 error = ehci_start_pipe_polling(ehcip, ph, flags);
1834 ehcip->ehci_log_hdl,
1843 USB_DPRINTF_L3(PRINT_MASK_INTR, ehcip->ehci_log_hdl,
1862 ehcip->ehci_log_hdl,
1870 ehcip->ehci_log_hdl,
1879 ehcip->ehci_log_hdl,
1899 ehci_state_t *ehcip,
1907 USB_DPRINTF_L4(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
1910 ASSERT(mutex_owned(&ehcip->ehci_int_mutex));
1923 ehci_set_periodic_pipe_polling(ehcip, ph);
1930 error = ehci_start_intr_polling(ehcip, ph, flags);
1933 error = ehci_start_isoc_polling(ehcip, ph, flags);
1942 ehci_state_t *ehcip,
1955 tw = ehci_allocate_intr_resources(ehcip, ph, NULL, flags);
1963 ehcip, pp, tw);
1964 ehci_deallocate_tw(ehcip, pp, tw);
1978 USB_DPRINTF_L3(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
1986 ehci_insert_intr_req(ehcip, pp, tw, flags);
2011 ehci_state_t *ehcip,
2019 USB_DPRINTF_L4(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
2022 ASSERT(mutex_owned(&ehcip->ehci_int_mutex));
2051 interval = ehci_adjust_polling_interval(ehcip, endpoint,
2068 USB_DPRINTF_L3(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
2083 ehci_state_t *ehcip,
2094 USB_DPRINTF_L4(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
2097 ASSERT(mutex_owned(&ehcip->ehci_int_mutex));
2115 USB_DPRINTF_L2(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
2122 if ((tw = ehci_allocate_tw_resources(ehcip, pp, tw_length, flags,
2129 if (ehci_allocate_intr_in_resource(ehcip, pp, tw, flags) !=
2131 ehci_deallocate_tw(ehcip, pp, tw);
2173 ehci_state_t *ehcip,
2180 ASSERT(mutex_owned(&ehcip->ehci_int_mutex));
2187 (void) ehci_insert_qtd(ehcip, ctrl, 0, tw->tw_length, 0, pp, tw);
2190 ehci_start_xfer_timer(ehcip, pp, tw);
2200 ehci_state_t *ehcip,
2207 USB_DPRINTF_L4(PRINT_MASK_HCDI, ehcip->ehci_log_hdl,
2210 ASSERT(mutex_owned(&ehcip->ehci_int_mutex));
2226 USB_DPRINTF_L2(PRINT_MASK_HCDI, ehcip->ehci_log_hdl,
2236 ehci_pipe_cleanup(ehcip, ph);
2251 ehci_state_t *ehcip,
2264 ASSERT(mutex_owned(&ehcip->ehci_int_mutex));
2270 tw->tw_qtd_free_list = ehci_qtd_iommu_to_cpu(ehcip,
2275 curr_dummy_qtd = ehci_qtd_iommu_to_cpu(ehcip,
2277 next_dummy_qtd = ehci_qtd_iommu_to_cpu(ehcip,
2281 Set_QH(qh->qh_dummy_qtd, ehci_qtd_cpu_to_iommu(ehcip, next_dummy_qtd));
2285 ehci_qtd_cpu_to_iommu(ehcip, new_dummy_qtd));
2291 ehci_fill_in_qtd(ehcip, curr_dummy_qtd, qtd_ctrl,
2295 ehci_insert_qtd_on_tw(ehcip, tw, curr_dummy_qtd);
2303 ehci_insert_qtd_into_active_qtd_list(ehcip, curr_dummy_qtd);
2307 ehci_print_qh(ehcip, qh);
2308 ehci_print_qtd(ehcip, curr_dummy_qtd);
2320 ehci_allocate_qtd_from_pool(ehci_state_t *ehcip)
2325 ASSERT(mutex_owned(&ehcip->ehci_int_mutex));
2332 ctrl = Get_QTD(ehcip->ehci_qtd_pool_addr[i].qtd_state);
2339 USB_DPRINTF_L2(PRINT_MASK_ALLOC, ehcip->ehci_log_hdl,
2345 USB_DPRINTF_L4(PRINT_MASK_ALLOC, ehcip->ehci_log_hdl,
2349 qtd = &ehcip->ehci_qtd_pool_addr[i];
2351 USB_DPRINTF_L3(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
2385 ehci_state_t *ehcip,
2400 USB_DPRINTF_L4(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
2464 USB_DPRINTF_L3(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
2492 (ehci_qtd_cpu_to_iommu(ehcip, tw->tw_alt_qtd) &
2527 ehci_state_t *ehcip,
2550 ehci_qtd_cpu_to_iommu(ehcip, qtd));
2566 ehci_state_t *ehcip,
2571 ASSERT(mutex_owned(&ehcip->ehci_int_mutex));
2573 curr_qtd = ehcip->ehci_active_qtd_list;
2577 next_qtd = ehci_qtd_iommu_to_cpu(ehcip,
2582 next_qtd = ehci_qtd_iommu_to_cpu(ehcip,
2587 ehci_qtd_cpu_to_iommu(ehcip, curr_qtd));
2590 ehci_qtd_cpu_to_iommu(ehcip, qtd));
2592 ehcip->ehci_active_qtd_list = qtd;
2608 ehci_state_t *ehcip,
2615 curr_qtd = ehcip->ehci_active_qtd_list;
2618 curr_qtd = ehci_qtd_iommu_to_cpu(ehcip,
2623 prev_qtd = ehci_qtd_iommu_to_cpu(ehcip,
2625 next_qtd = ehci_qtd_iommu_to_cpu(ehcip,
2632 ehcip->ehci_active_qtd_list = next_qtd;
2640 USB_DPRINTF_L3(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
2656 ehci_state_t *ehcip,
2664 ASSERT(mutex_owned(&ehcip->ehci_int_mutex));
2666 USB_DPRINTF_L4(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
2674 ehci_stop_xfer_timer(ehcip, next_tw, EHCI_REMOVE_XFER_ALWAYS);
2681 ehci_remove_qtd_from_active_qtd_list(ehcip, qtd);
2683 next_qtd = ehci_qtd_iommu_to_cpu(ehcip,
2687 ehci_deallocate_qtd(ehcip, qtd);
2712 ehci_state_t *ehcip,
2717 USB_DPRINTF_L4(PRINT_MASK_ALLOC, ehcip->ehci_log_hdl,
2743 ehcip, Get_QTD(qtd->qtd_tw_next_qtd));
2748 ehcip, Get_QTD(qtd->qtd_tw_next_qtd));
2758 ehcip, Get_QTD(old_qtd->qtd_tw_next_qtd));
2769 USB_DPRINTF_L3(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
2784 ehci_state_t *ehcip,
2789 td = (uint32_t)ehcip->ehci_qtd_pool_cookie.dmac_address +
2791 (uintptr_t)(ehcip->ehci_qtd_pool_addr));
2793 ASSERT((ehcip->ehci_qtd_pool_cookie.dmac_address +
2795 (addr - ehcip->ehci_qtd_pool_addr))) ==
2796 (ehcip->ehci_qtd_pool_cookie.dmac_address +
2798 (ehcip->ehci_qtd_pool_addr))));
2800 ASSERT(td >= ehcip->ehci_qtd_pool_cookie.dmac_address);
2801 ASSERT(td <= ehcip->ehci_qtd_pool_cookie.dmac_address +
2818 ehci_state_t *ehcip,
2829 (addr - ehcip->ehci_qtd_pool_cookie.dmac_address) +
2830 (uintptr_t)ehcip->ehci_qtd_pool_addr);
2832 ASSERT(qtd >= ehcip->ehci_qtd_pool_addr);
2833 ASSERT((uintptr_t)qtd <= (uintptr_t)ehcip->ehci_qtd_pool_addr +
2858 ehci_state_t *ehcip,
2873 qtd = ehci_allocate_qtd_from_pool(ehcip);
2876 USB_DPRINTF_L2(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
2883 qtd_addr = ehci_qtd_cpu_to_iommu(ehcip,
2916 ehci_state_t *ehcip,
2924 tw = ehci_create_transfer_wrapper(ehcip, pp, tw_length, usb_flags);
2927 USB_DPRINTF_L2(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
2930 if (ehci_allocate_tds_for_tw(ehcip, pp, tw, qtd_count) ==
2934 ehci_deallocate_tw(ehcip, pp, tw);
2953 ehci_state_t *ehcip,
2959 USB_DPRINTF_L4(PRINT_MASK_ALLOC, ehcip->ehci_log_hdl,
2965 temp_qtd = ehci_qtd_iommu_to_cpu(ehcip,
2967 ehci_deallocate_qtd(ehcip, qtd);
2983 ehci_state_t *ehcip,
2997 USB_DPRINTF_L4(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
3001 ASSERT(mutex_owned(&ehcip->ehci_int_mutex));
3011 USB_DPRINTF_L2(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
3024 bcopy(&ehcip->ehci_dma_attr, &dma_attr, sizeof (ddi_dma_attr_t));
3029 result = ddi_dma_alloc_handle(ehcip->ehci_dip,
3033 USB_DPRINTF_L2(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
3053 USB_DPRINTF_L2(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
3070 ehci_decode_ddi_dma_addr_bind_handle_result(ehcip, result);
3111 ehcip->ehci_periodic_req_count++;
3113 ehcip->ehci_async_req_count++;
3115 ehci_toggle_scheduler(ehcip);
3117 USB_DPRINTF_L4(PRINT_MASK_ALLOC, ehcip->ehci_log_hdl,
3134 ehci_state_t *ehcip,
3138 USB_DPRINTF_L3(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
3141 ASSERT(mutex_owned(&ehcip->ehci_int_mutex));
3160 ehci_start_timer(ehcip, pp);
3173 ehci_state_t *ehcip,
3180 USB_DPRINTF_L3(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
3183 ASSERT(mutex_owned(&ehcip->ehci_int_mutex));
3202 ehci_remove_tw_from_timeout_list(ehcip, tw);
3212 mutex_exit(&ehcip->ehci_int_mutex);
3216 mutex_enter(&ehcip->ehci_int_mutex);
3234 ehci_state_t *ehcip = ehci_obtain_state(
3241 USB_DPRINTF_L4(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
3242 "ehci_xfer_timeout_handler: ehcip = 0x%p, ph = 0x%p",
3243 (void *)ehcip, (void *)ph);
3245 mutex_enter(&ehcip->ehci_int_mutex);
3255 mutex_exit(&ehcip->ehci_int_mutex);
3273 ehci_remove_tw_from_timeout_list(ehcip, tw);
3279 ehcip, qtd);
3282 qtd = ehci_qtd_iommu_to_cpu(ehcip,
3304 ehci_start_timer(ehcip, pp);
3321 ehci_handle_error(ehcip, tw->tw_qtd_head, USB_CR_TIMEOUT);
3325 mutex_exit(&ehcip->ehci_int_mutex);
3336 ehci_state_t *ehcip,
3342 USB_DPRINTF_L3(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
3345 ASSERT(mutex_owned(&ehcip->ehci_int_mutex));
3381 ehci_state_t *ehcip,
3384 USB_DPRINTF_L4(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
3385 "ehci_start_timer: ehcip = 0x%p, pp = 0x%p",
3386 (void *)ehcip, (void *)pp);
3388 ASSERT(mutex_owned(&ehcip->ehci_int_mutex));
3409 ehci_state_t *ehcip,
3415 USB_DPRINTF_L4(PRINT_MASK_ALLOC, ehcip->ehci_log_hdl,
3432 ehci_free_tw_td_resources(ehcip, tw);
3469 ehci_remove_tw_from_timeout_list(ehcip, tw);
3472 ehci_free_tw(ehcip, pp, tw);
3485 ehci_state_t *ehcip,
3492 USB_DPRINTF_L4(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
3495 ASSERT(mutex_owned(&ehcip->ehci_int_mutex));
3503 USB_DPRINTF_L4(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
3506 ehci_free_tw(ehcip, pp, tw);
3523 ehci_state_t *ehcip,
3530 USB_DPRINTF_L4(PRINT_MASK_ALLOC, ehcip->ehci_log_hdl,
3549 ehcip->ehci_periodic_req_count--;
3551 ehcip->ehci_async_req_count--;
3553 ehci_toggle_scheduler(ehcip);
3572 ehci_state_t *ehcip,
3582 USB_DPRINTF_L4(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
3586 ASSERT(mutex_owned(&ehcip->ehci_int_mutex));
3612 USB_DPRINTF_L2(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
3648 ehci_state_t *ehcip,
3656 USB_DPRINTF_L4(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
3659 ASSERT(mutex_owned(&ehcip->ehci_int_mutex));
3662 ehci_isoc_pipe_cleanup(ehcip, ph);
3677 ehci_modify_qh_status_bit(ehcip, pp, SET_HALT);
3683 ehci_wait_for_transfers_completion(ehcip, pp);
3686 ehci_save_data_toggle(ehcip, ph);
3693 ehci_traverse_qtds(ehcip, ph);
3699 ehci_handle_outstanding_requests(ehcip, pp);
3702 ehci_free_dma_resources(ehcip, ph);
3716 ehci_restore_data_toggle(ehcip, ph);
3722 ehci_modify_qh_status_bit(ehcip, pp, CLEAR_HALT);
3739 ehcip, pp, completion_reason);
3752 ehci_state_t *ehcip,
3759 ehcip->ehci_log_hdl,
3762 ASSERT(mutex_owned(&ehcip->ehci_int_mutex));
3764 if ((ehci_state_is_operational(ehcip)) != USB_SUCCESS) {
3786 qtd = ehci_qtd_iommu_to_cpu(ehcip,
3793 USB_DPRINTF_L3(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
3802 (void) cv_reltimedwait(&pp->pp_xfer_cmpl_cv, &ehcip->ehci_int_mutex,
3807 USB_DPRINTF_L2(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
3821 ehci_state_t *ehcip,
3825 ehcip->ehci_log_hdl,
3828 ASSERT(mutex_owned(&ehcip->ehci_int_mutex));
3839 ehcip, pp, USB_CR_NO_RESOURCES);
3844 USB_DPRINTF_L3(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
3853 USB_DPRINTF_L3(PRINT_MASK_LISTS, ehcip->ehci_log_hdl,
3872 ehci_state_t *ehcip,
3882 ehcip->ehci_log_hdl,
3885 ASSERT(mutex_owned(&ehcip->ehci_int_mutex));
3927 ehci_state_t *ehcip,
3935 ehcip->ehci_log_hdl,
3938 ASSERT(mutex_owned(&ehcip->ehci_int_mutex));
3980 ehci_state_t *ehcip,
3990 ehcip->ehci_log_hdl,
3993 ASSERT(mutex_owned(&ehcip->ehci_int_mutex));
4014 ehcip, pp, curr_tw);
4030 ehci_state_t *ehcip,
4039 ehcip->ehci_log_hdl,
4043 ASSERT(mutex_owned(&ehcip->ehci_int_mutex));
4073 ehci_state_t *ehcip,
4081 ehcip->ehci_log_hdl,
4085 ASSERT(mutex_owned(&ehcip->ehci_int_mutex));
4113 ehci_state_t *ehcip = ehci_obtain_state(
4119 USB_DPRINTF_L4(PRINT_MASK_HCDI, ehcip->ehci_log_hdl,
4123 ASSERT(mutex_owned(&ehcip->ehci_int_mutex));
4160 mutex_exit(&ehcip->ehci_int_mutex);
4164 mutex_enter(&ehcip->ehci_int_mutex);