mirror of
https://github.com/apache/nuttx.git
synced 2026-09-24 00:42:03 +08:00
Merged in spiriou/nuttx/stm32_usbdev_hid (pull request #611)
arch/arm/src/stm32/usb: skip recipient check for descriptor related requests Approved-by: Gregory Nutt <gnutt@nuttx.org>
This commit is contained in:
committed by
Gregory Nutt
parent
e6e7dae05b
commit
1f52c13814
@@ -2028,18 +2028,11 @@ static void stm32_ep0setup(struct stm32_usbdev_s *priv)
|
||||
|
||||
{
|
||||
usbtrace(TRACE_INTDECODE(STM32_TRACEINTID_GETSETDESC), priv->ctrl.type);
|
||||
if ((priv->ctrl.type & USB_REQ_RECIPIENT_MASK) == USB_REQ_RECIPIENT_DEVICE)
|
||||
{
|
||||
/* The request seems valid... let the class implementation handle it */
|
||||
|
||||
stm32_dispatchrequest(priv);
|
||||
handled = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
usbtrace(TRACE_DEVERROR(STM32_TRACEERR_BADGETSETDESC), 0);
|
||||
priv->ep0state = EP0STATE_STALLED;
|
||||
}
|
||||
/* The request seems valid... let the class implementation handle it */
|
||||
|
||||
stm32_dispatchrequest(priv);
|
||||
handled = true;
|
||||
}
|
||||
break;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user