summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorliuhy-2020 <[email protected]>2022-06-17 16:26:13 +0800
committersakumisu <[email protected]>2022-06-17 16:28:18 +0800
commit22ad2d471cf281eb89c373c7862f542d3695a99b (patch)
treeb67356422180828e2c5c5dc29f7963a442286197
parent12f74971ebaeeb463fad905227156d669a7e083b (diff)
handle USB_DESCRIPTOR_TYPE_OTHER_SPEED
[usbd_get_descriptor]: handle USB_DESCRIPTOR_TYPE_OTHER_SPEED.
-rw-r--r--core/usbd_core.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/core/usbd_core.c b/core/usbd_core.c
index 10dbe57b..5dc56614 100644
--- a/core/usbd_core.c
+++ b/core/usbd_core.c
@@ -311,7 +311,7 @@ static bool usbd_get_descriptor(uint16_t type_index, uint8_t **data, uint32_t *l
*data = p;
/* get length from structure */
- if (type == USB_DESCRIPTOR_TYPE_CONFIGURATION) {
+ if ((type == USB_DESCRIPTOR_TYPE_CONFIGURATION)||((type == USB_DESCRIPTOR_TYPE_OTHER_SPEED))){
/* configuration descriptor is an
* exception, length is at offset
* 2 and 3