Lines Matching defs:pUrb

32     PURB pUrb;
557 PURB pUrb = NULL;
563 pUrb = VBoxUsbToolUrbAllocZ(URB_FUNCTION_SELECT_CONFIGURATION, sizeof (struct _URB_SELECT_CONFIGURATION));
564 if(!pUrb)
572 pUrb->UrbSelectConfiguration.ConfigurationDescriptor = NULL;
574 Status = VBoxUsbToolUrbPost(pDevExt->pLowerDO, pUrb, RT_INDEFINITE_WAIT);
575 if(NT_SUCCESS(Status) && USBD_SUCCESS(pUrb->UrbHeader.Status))
577 pDevExt->Rt.hConfiguration = pUrb->UrbSelectConfiguration.ConfigurationHandle;
582 AssertMsgFailed((__FUNCTION__": VBoxUsbToolUrbPost failed Status (0x%x), usb Status (0x%x)\n", Status, pUrb->UrbHeader.Status));
585 VBoxUsbToolUrbFree(pUrb);
618 pUrb = USBD_CreateConfigurationRequestEx(pCfgDr, pIfLe);
619 if (pUrb)
621 Status = VBoxUsbToolUrbPost(pDevExt->pLowerDO, pUrb, RT_INDEFINITE_WAIT);
622 if (NT_SUCCESS(Status) && USBD_SUCCESS(pUrb->UrbHeader.Status))
626 pDevExt->Rt.hConfiguration = pUrb->UrbSelectConfiguration.ConfigurationHandle;
682 AssertMsgFailed((__FUNCTION__": VBoxUsbToolUrbPost failed Status (0x%x), usb Status (0x%x)\n", Status, pUrb->UrbHeader.Status));
684 ExFreePool(pUrb);
770 PURB pUrb = VBoxUsbToolUrbAllocZ(0, uUrbSize);
771 if (!pUrb)
814 UsbBuildSelectInterfaceRequest(pUrb, uUrbSize, pDevExt->Rt.hConfiguration, InterfaceNumber, AlternateSetting);
815 pUrb->UrbSelectInterface.Interface.Length = GET_USBD_INTERFACE_SIZE(pIfDr->bNumEndpoints);
817 Status = VBoxUsbToolUrbPost(pDevExt->pLowerDO, pUrb, RT_INDEFINITE_WAIT);
818 if (NT_SUCCESS(Status) && USBD_SUCCESS(pUrb->UrbHeader.Status))
820 USBD_INTERFACE_INFORMATION *pIfInfo = &pUrb->UrbSelectInterface.Interface;
832 AssertMsgFailed((__FUNCTION__": VBoxUsbToolUrbPost failed Status (0x%x) usb Status (0x%x)\n", Status, pUrb->UrbHeader.Status));
843 VBoxUsbToolUrbFree(pUrb);
1031 PURB pUrb = pContext->pUrb;
1036 if (!pUrb || !pMdlBuf || !pUrbInfo | !pDevExt)
1048 switch(pUrb->UrbHeader.Status)
1061 AssertMsgFailed((__FUNCTION__": sw error, urb Status (0x%x)\n", pUrb->UrbHeader.Status));
1072 pUrbInfo->len = pUrb->UrbControlTransfer.TransferBufferLength;
1079 pUrbInfo->len += sizeof (pUrb->UrbControlTransfer.SetupPacket);
1083 pUrbInfo->len = pUrb->UrbIsochronousTransfer.TransferBufferLength;
1089 && pUrbInfo->len > pUrb->UrbBulkOrInterruptTransfer.TransferBufferLength
1098 pUrbInfo->len = pUrb->UrbBulkOrInterruptTransfer.TransferBufferLength;
1108 Log((__FUNCTION__": URB failed Status (0x%x) urb Status (0x%x)\n", Status, pUrb->UrbHeader.Status));
1114 LogRel(("Ctrl/Msg length=%d\n", pUrb->UrbControlTransfer.TransferBufferLength));
1117 LogRel(("ISOC length=%d\n", pUrb->UrbIsochronousTransfer.TransferBufferLength));
1121 LogRel(("BULK/INTR length=%d\n", pUrb->UrbBulkOrInterruptTransfer.TransferBufferLength));
1125 switch(pUrb->UrbHeader.Status)
1151 AssertMsgFailed((__FUNCTION__": err Status (0x%x) (0x%x)\n", Status, pUrb->UrbHeader.Status));
1160 Assert(pUrbInfo->numIsoPkts == pUrb->UrbIsochronousTransfer.NumberOfPackets);
1163 Assert(pUrbInfo->aIsoPkts[i].off == pUrb->UrbIsochronousTransfer.IsoPacket[i].Offset);
1164 pUrbInfo->aIsoPkts[i].cb = (uint16_t)pUrb->UrbIsochronousTransfer.IsoPacket[i].Length;
1165 switch (pUrb->UrbIsochronousTransfer.IsoPacket[i].Status)
1219 PURB pUrb = (PURB)(pContext + 1);
1269 pUrb->UrbHeader.Function = URB_FUNCTION_CONTROL_TRANSFER;
1270 pUrb->UrbHeader.Length = sizeof (struct _URB_CONTROL_TRANSFER);
1271 pUrb->UrbControlTransfer.PipeHandle = hPipe;
1272 pUrb->UrbControlTransfer.TransferBufferLength = (ULONG)pUrbInfo->len;
1273 pUrb->UrbControlTransfer.TransferFlags = ((pUrbInfo->dir == USBSUP_DIRECTION_IN) ? USBD_TRANSFER_DIRECTION_IN : USBD_TRANSFER_DIRECTION_OUT);
1274 pUrb->UrbControlTransfer.UrbLink = 0;
1277 pUrb->UrbControlTransfer.TransferFlags |= USBD_DEFAULT_PIPE_TRANSFER;
1283 * data length is therefore pUrb->len - 8
1285 PVBOXUSB_SETUP pSetup = (PVBOXUSB_SETUP)pUrb->UrbControlTransfer.SetupPacket;
1286 memcpy(pUrb->UrbControlTransfer.SetupPacket, pBuffer, min(sizeof (pUrb->UrbControlTransfer.SetupPacket), pUrbInfo->len));
1288 if (pUrb->UrbControlTransfer.TransferBufferLength <= sizeof (pUrb->UrbControlTransfer.SetupPacket))
1289 pUrb->UrbControlTransfer.TransferBufferLength = 0;
1291 pUrb->UrbControlTransfer.TransferBufferLength -= sizeof (pUrb->UrbControlTransfer.SetupPacket);
1293 pUrb->UrbControlTransfer.TransferBuffer = (uint8_t *)pBuffer + sizeof(pUrb->UrbControlTransfer.SetupPacket);
1294 pUrb->UrbControlTransfer.TransferBufferMDL = 0;
1295 pUrb->UrbControlTransfer.TransferFlags |= USBD_SHORT_TRANSFER_OK;
1299 pUrb->UrbControlTransfer.TransferBuffer = 0;
1300 pUrb->UrbControlTransfer.TransferBufferMDL = pMdlBuf;
1317 pUrb->UrbHeader.Function = URB_FUNCTION_ISOCH_TRANSFER;
1318 pUrb->UrbHeader.Length = (USHORT)cbUrb;
1319 pUrb->UrbIsochronousTransfer.PipeHandle = hPipe;
1320 pUrb->UrbIsochronousTransfer.TransferBufferLength = (ULONG)pUrbInfo->len;
1321 pUrb->UrbIsochronousTransfer.TransferBufferMDL = 0;
1322 pUrb->UrbIsochronousTransfer.TransferBuffer = pBuffer;
1323 pUrb->UrbIsochronousTransfer.TransferFlags = ((pUrbInfo->dir == USBSUP_DIRECTION_IN) ? USBD_TRANSFER_DIRECTION_IN : USBD_TRANSFER_DIRECTION_OUT);
1324 pUrb->UrbIsochronousTransfer.TransferFlags |= USBD_SHORT_TRANSFER_OK; // May be implied already
1325 pUrb->UrbIsochronousTransfer.NumberOfPackets = pUrbInfo->numIsoPkts;
1326 pUrb->UrbIsochronousTransfer.ErrorCount = 0;
1327 pUrb->UrbIsochronousTransfer.UrbLink = 0;
1329 Assert(pUrbInfo->numIsoPkts == pUrb->UrbIsochronousTransfer.NumberOfPackets);
1332 pUrb->UrbIsochronousTransfer.IsoPacket[i].Offset = pUrbInfo->aIsoPkts[i].off;
1333 pUrb->UrbIsochronousTransfer.IsoPacket[i].Length = pUrbInfo->aIsoPkts[i].cb;
1347 pUrb->UrbIsochronousTransfer.StartFrame = iFrame;
1357 pUrb->UrbHeader.Function = URB_FUNCTION_BULK_OR_INTERRUPT_TRANSFER;
1358 pUrb->UrbHeader.Length = sizeof (struct _URB_BULK_OR_INTERRUPT_TRANSFER);
1359 pUrb->UrbBulkOrInterruptTransfer.PipeHandle = hPipe;
1360 pUrb->UrbBulkOrInterruptTransfer.TransferBufferLength = (ULONG)pUrbInfo->len;
1361 pUrb->UrbBulkOrInterruptTransfer.TransferBufferMDL = 0;
1362 pUrb->UrbBulkOrInterruptTransfer.TransferBuffer = pBuffer;
1363 pUrb->UrbBulkOrInterruptTransfer.TransferFlags = ((pUrbInfo->dir == USBSUP_DIRECTION_IN) ? USBD_TRANSFER_DIRECTION_IN : USBD_TRANSFER_DIRECTION_OUT);
1365 if (pUrb->UrbBulkOrInterruptTransfer.TransferFlags & USBD_TRANSFER_DIRECTION_IN)
1366 pUrb->UrbBulkOrInterruptTransfer.TransferFlags |= (USBD_SHORT_TRANSFER_OK);
1368 pUrb->UrbBulkOrInterruptTransfer.UrbLink = 0;
1386 pContext->pUrb = pUrb;
1394 pSl->Parameters.Others.Argument1 = pUrb;