Lines Matching defs:pDr
539 PUSB_CONFIGURATION_DESCRIPTOR pDr = (PUSB_CONFIGURATION_DESCRIPTOR)(pRq + 1);
561 if (pDr->wTotalLength != cbRq - sizeof (USB_DESCRIPTOR_REQUEST))
567 *ppDr = pDr;
575 static void usbLibDevCfgDrFree(PUSB_CONFIGURATION_DESCRIPTOR pDr)
577 Assert(pDr);
578 PUSB_DESCRIPTOR_REQUEST pRq = ((PUSB_DESCRIPTOR_REQUEST)pDr)-1;
588 PUSB_STRING_DESCRIPTOR pDr = (PUSB_STRING_DESCRIPTOR)(szBuf + sizeof (*pRq));
589 RT_BZERO(pDr, sizeof(USB_STRING_DESCRIPTOR));
607 if (pDr->bDescriptorType != USB_STRING_DESCRIPTOR_TYPE)
611 if ( (cbReturned < sizeof (*pDr) + 2)
612 || (!!(pDr->bLength % 2))
613 || (pDr->bLength != cbReturned - sizeof(*pRq)))
616 cbReturned, sizeof(*pRq), pDr->bDescriptorType, pDr->bLength, iPort, iDr, idLang));
621 (PVBOXUSB_STRING_DR_ENTRY)RTMemAllocZ(sizeof(VBOXUSB_STRING_DR_ENTRY) + pDr->bLength + 2);
629 memcpy(&pEntry->StrDr, pDr, pDr->bLength);
636 static void usbLibDevStrDrEntryFree(PVBOXUSB_STRING_DR_ENTRY pDr)
638 RTMemFree(pDr);
641 static void usbLibDevStrDrEntryFreeList(PVBOXUSB_STRING_DR_ENTRY pDr)
643 while (pDr)
645 PVBOXUSB_STRING_DR_ENTRY pNext = pDr->pNext;
646 usbLibDevStrDrEntryFree(pDr);
647 pDr = pNext;