Lines Matching defs:pUrb

78     PVUSBURB    pUrb;
112 pUrb = vusbRhNewUrb(pRh, pDev->u8Address, cbTotal, 1);
113 if (!pUrb)
117 pUrb->enmType = VUSBXFERTYPE_ISOC;
118 pUrb->EndPt = uEndPt;
119 pUrb->enmDir = VUSBDIRECTION_IN;
120 pUrb->fShortNotOk = false;
121 pUrb->enmStatus = VUSBSTATUS_OK;
122 pUrb->Hci.EdAddr = 0;
123 pUrb->Hci.fUnlinked = false;
128 RTStrAPrintf(&pUrb->pszDesc, "URB %p prab<%04d", pUrb, s_iSerial); // prab = Periodic Read-Ahead Buffer
132 pUrb->cIsocPkts = 8;
137 pUrb->aIsocPkts[i].enmStatus = VUSBSTATUS_NOT_ACCESSED;
138 pUrb->aIsocPkts[i].off = off;
141 pUrb->aIsocPkts[i].cb = uPktSize;
146 pUrb->aIsocPkts[i].cb = 0;
149 return pUrb;
176 PVUSBURB pUrb;
218 pUrb = vusbDevNewIsocUrb(pThis->pDev, pDesc->bEndpointAddress & 0xF, interval, max_pkt_size * mult);
219 if (!pUrb) {
226 Assert(pUrb->enmState == VUSBURBSTATE_ALLOCATED);
229 pUrb->Hci.pNext = (PVUSBURB)pvUser;
231 pUrb->enmState = VUSBURBSTATE_IN_FLIGHT;
232 rc = vusbUrbQueueAsyncRh(pUrb);
238 pUrb->VUsb.pfnFree(pUrb);
280 void vusbUrbCompletionReadAhead(PVUSBURB pUrb)
282 Assert(pUrb);
283 Assert(pUrb->Hci.pNext);
284 PVUSBREADAHEADINT pThis = (PVUSBREADAHEADINT)pUrb->Hci.pNext;
289 pUrb->Hci.pNext = NULL; // @todo: use a more suitable field
294 pThis->pBuffUrbTail = pThis->pBuffUrbHead = pUrb;
301 pThis->pBuffUrbTail = pThis->pBuffUrbTail->Hci.pNext = pUrb;
313 * @param pUrb The URB submitted by HC
318 int vusbUrbSubmitBufferedRead(PVUSBURB pUrb, VUSBREADAHEAD hReadAhead)
322 Assert(pUrb && pThis);
339 Assert(pUrb->enmType == pBufferedUrb->enmType);
340 Assert(pUrb->EndPt == pBufferedUrb->EndPt);
341 Assert(pUrb->enmDir == pBufferedUrb->enmDir);
343 pUrb->enmState = VUSBURBSTATE_REAPED;
344 pUrb->enmStatus = pBufferedUrb->enmStatus;
347 for (unsigned i = 0; i < pUrb->cIsocPkts; ++i)
353 pUrb->aIsocPkts[i].cb = len;
354 pUrb->aIsocPkts[i].off = off;
355 pUrb->aIsocPkts[i].enmStatus = pBufferedUrb->aIsocPkts[i].enmStatus;
357 Assert(pUrb->VUsb.cbDataAllocated >= cbTotal);
358 memcpy(&pUrb->abData[off], &pBufferedUrb->abData[off], len);
361 vusbUrbCompletionRh(pUrb);
363 // Assert(pUrb->enmState == VUSBURBSTATE_FREE);
375 pUrb->enmState = VUSBURBSTATE_REAPED;
376 pUrb->enmStatus = VUSBSTATUS_DATA_UNDERRUN;
377 for (unsigned i = 0; i < pUrb->cIsocPkts; ++i)
379 pUrb->aIsocPkts[i].cb = 0;
380 pUrb->aIsocPkts[i].enmStatus = VUSBSTATUS_NOT_ACCESSED;
382 vusbUrbCompletionRh(pUrb);
384 // Assert(pUrb->enmState == VUSBURBSTATE_FREE);