summaryrefslogtreecommitdiff
path: root/src/device/usbd.c
diff options
context:
space:
mode:
authorhathach <[email protected]>2020-09-09 16:25:31 +0700
committerhathach <[email protected]>2020-09-09 16:25:31 +0700
commit33f0a18523accfcdebf186f33271dd92f8681b56 (patch)
treedf9990e0211e59da9109f171a7da2abb26e02f7e /src/device/usbd.c
parent8b9893cadab88fa4abd17d5b9856e0d08ef03796 (diff)
update cdc edpt read
Diffstat (limited to 'src/device/usbd.c')
-rw-r--r--src/device/usbd.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/device/usbd.c b/src/device/usbd.c
index 25d3748e1..5a7d72124 100644
--- a/src/device/usbd.c
+++ b/src/device/usbd.c
@@ -1162,7 +1162,9 @@ bool usbd_edpt_xfer(uint8_t rhport, uint8_t ep_addr, uint8_t * buffer, uint16_t
return true;
}else
{
+ // DCD error, mark endpoint as ready to allow next transfer
_usbd_dev.ep_status[epnum][dir].busy = false;
+ _usbd_dev.ep_status[epnum][dir].claimed = 0;
TU_LOG2("failed\r\n");
TU_BREAKPOINT();
return false;