aboutsummaryrefslogtreecommitdiff
path: root/embassy-stm32/src/usb
diff options
context:
space:
mode:
authorelagil <[email protected]>2025-03-16 16:34:09 +0100
committerelagil <[email protected]>2025-03-16 16:34:09 +0100
commitcecbe082ff5505b69cd4cc7138a4275d7af4aa8a (patch)
treede80577b46363a4ab14a382f5981019c553c2387 /embassy-stm32/src/usb
parent0ff618472397ef6d506afe879900a27014218f81 (diff)
fix: only ISO EP is always double buffered
Diffstat (limited to 'embassy-stm32/src/usb')
-rw-r--r--embassy-stm32/src/usb/usb.rs5
1 files changed, 3 insertions, 2 deletions
diff --git a/embassy-stm32/src/usb/usb.rs b/embassy-stm32/src/usb/usb.rs
index c00c88215..8dabfc78f 100644
--- a/embassy-stm32/src/usb/usb.rs
+++ b/embassy-stm32/src/usb/usb.rs
@@ -363,10 +363,11 @@ impl<'d, T: Instance> Driver<'d, T> {
363 return false; // reserved for control pipe 363 return false; // reserved for control pipe
364 } 364 }
365 let used = ep.used_out || ep.used_in; 365 let used = ep.used_out || ep.used_in;
366 if used && (ep.ep_type == EndpointType::Isochronous || ep.ep_type == EndpointType::Bulk) { 366 if used && (ep.ep_type == EndpointType::Isochronous) {
367 // Isochronous and bulk endpoints are double-buffered. 367 // Isochronous endpoints are always double-buffered.
368 // Their corresponding endpoint/channel registers are forced to be unidirectional. 368 // Their corresponding endpoint/channel registers are forced to be unidirectional.
369 // Do not reuse this index. 369 // Do not reuse this index.
370 // FIXME: Bulk endpoints can be double buffered, but are not in the current implementation.
370 return false; 371 return false;
371 } 372 }
372 373