Lines Matching refs:pSetup

297 static bool vusbDevStdReqSetConfig(PVUSBDEV pDev, int EndPt, PVUSBSETUP pSetup, uint8_t *pbBuf, uint32_t *pcbBuf)
299 unsigned iCfg = pSetup->wValue & 0xff;
301 if ((pSetup->bmRequestType & VUSB_RECIP_MASK) != VUSB_TO_DEVICE)
349 static bool vusbDevStdReqGetConfig(PVUSBDEV pDev, int EndPt, PVUSBSETUP pSetup, uint8_t *pbBuf, uint32_t *pcbBuf)
351 if ((pSetup->bmRequestType & VUSB_RECIP_MASK) != VUSB_TO_DEVICE)
391 static bool vusbDevStdReqGetInterface(PVUSBDEV pDev, int EndPt, PVUSBSETUP pSetup, uint8_t *pbBuf, uint32_t *pcbBuf)
393 if ((pSetup->bmRequestType & VUSB_RECIP_MASK) != VUSB_TO_INTERFACE)
420 && pSetup->wIndex == pIfDesc->Core.bInterfaceNumber)
429 Log(("vusb: error: %s: GET_INTERFACE - unknown iface %u !!!\n", pDev->pUsbIns->pszName, pSetup->wIndex));
437 static bool vusbDevStdReqSetInterface(PVUSBDEV pDev, int EndPt, PVUSBSETUP pSetup, uint8_t *pbBuf, uint32_t *pcbBuf)
439 if ((pSetup->bmRequestType & VUSB_RECIP_MASK) != VUSB_TO_INTERFACE)
459 uint8_t iIf = pSetup->wIndex;
466 uint8_t iAlt = pSetup->wValue;
499 static bool vusbDevStdReqSetAddress(PVUSBDEV pDev, int EndPt, PVUSBSETUP pSetup, uint8_t *pbBuf, uint32_t *pcbBuf)
501 if ((pSetup->bmRequestType & VUSB_RECIP_MASK) != VUSB_TO_DEVICE)
519 pDev->u8NewAddress = pSetup->wValue;
530 static bool vusbDevStdReqClearFeature(PVUSBDEV pDev, int EndPt, PVUSBSETUP pSetup, uint8_t *pbBuf, uint32_t *pcbBuf)
532 switch (pSetup->bmRequestType & VUSB_RECIP_MASK)
535 Log(("vusb: ClearFeature: dev(%u): selector=%u\n", pSetup->wIndex, pSetup->wValue));
538 Log(("vusb: ClearFeature: iface(%u): selector=%u\n", pSetup->wIndex, pSetup->wValue));
541 Log(("vusb: ClearFeature: ep(%u): selector=%u\n", pSetup->wIndex, pSetup->wValue));
543 && pSetup->wValue == 0 /* ENDPOINT_HALT */
547 2, pDev->pUsbIns, pSetup->wIndex);
564 static bool vusbDevStdReqSetFeature(PVUSBDEV pDev, int EndPt, PVUSBSETUP pSetup, uint8_t *pbBuf, uint32_t *pcbBuf)
566 switch (pSetup->bmRequestType & VUSB_RECIP_MASK)
570 pSetup->wIndex, pSetup->wValue));
574 pSetup->wIndex, pSetup->wValue));
578 pSetup->wIndex, pSetup->wValue));
588 static bool vusbDevStdReqGetStatus(PVUSBDEV pDev, int EndPt, PVUSBSETUP pSetup, uint8_t *pbBuf, uint32_t *pcbBuf)
597 switch (pSetup->bmRequestType & VUSB_RECIP_MASK)
820 static bool vusbDevStdReqGetDescriptor(PVUSBDEV pDev, int EndPt, PVUSBSETUP pSetup, uint8_t *pbBuf, uint32_t *pcbBuf)
822 if ((pSetup->bmRequestType & VUSB_RECIP_MASK) == VUSB_TO_DEVICE)
824 switch (pSetup->wValue >> 8)
833 unsigned int iIndex = (pSetup->wValue & 0xff);
847 if (pSetup->wIndex == 0)
855 pSetup->wIndex, pSetup->wValue & 0xff);
871 pDev->pUsbIns->pszName, pSetup->wValue >> 8, pSetup->wValue & 0xff, pSetup->wIndex, pSetup->wLength));
884 * @param pSetup Pointer to the setup request structure.
888 bool vusbDevStandardRequest(PVUSBDEV pDev, int EndPoint, PVUSBSETUP pSetup, void *pvBuf, uint32_t *pcbBuf)
920 if ( pSetup->bRequest >= VUSB_REQ_MAX
921 || !s_apfnStdReq[pSetup->bRequest])
924 pSetup->bRequest, pSetup->wValue, pSetup->wIndex, pSetup->wLength));
928 return s_apfnStdReq[pSetup->bRequest](pDev, EndPoint, pSetup, (uint8_t *)pvBuf, pcbBuf);