summaryrefslogtreecommitdiff
path: root/src/device/usbd_control.c
diff options
context:
space:
mode:
authorHa Thach <[email protected]>2023-01-07 23:46:46 +0700
committerGitHub <[email protected]>2023-01-07 23:46:46 +0700
commit949950e592d9a23a4b449784b0f8e7e274129318 (patch)
tree9a9df1391a8227395d13a90458d6b56aa93a85ac /src/device/usbd_control.c
parent2683deb0dd2e049de6c9b15f49d28a2fef4380f6 (diff)
parent83cc71feaf442842e498343b5a3128f4735216bb (diff)
Merge branch 'master' into ch32v307
Diffstat (limited to 'src/device/usbd_control.c')
-rw-r--r--src/device/usbd_control.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/device/usbd_control.c b/src/device/usbd_control.c
index 4f4108090..0995ef669 100644
--- a/src/device/usbd_control.c
+++ b/src/device/usbd_control.c
@@ -28,9 +28,9 @@
#if CFG_TUD_ENABLED
+#include "dcd.h"
#include "tusb.h"
#include "device/usbd_pvt.h"
-#include "dcd.h"
#if CFG_TUSB_DEBUG >= 2
extern void usbd_driver_print_control_complete_name(usbd_control_xfer_cb_t callback);
@@ -189,7 +189,7 @@ bool usbd_control_xfer_cb (uint8_t rhport, uint8_t ep_addr, xfer_result_t result
TU_LOG_MEM(2, _usbd_ctrl_buf, xferred_bytes, 2);
}
- _ctrl_xfer.total_xferred += xferred_bytes;
+ _ctrl_xfer.total_xferred += (uint16_t) xferred_bytes;
_ctrl_xfer.buffer += xferred_bytes;
// Data Stage is complete when all request's length are transferred or