diff options
| author | Dario Nieuwenhuis <[email protected]> | 2023-06-19 09:55:07 +0000 |
|---|---|---|
| committer | GitHub <[email protected]> | 2023-06-19 09:55:07 +0000 |
| commit | 3c70f799a28f5f28d84fa8ee8b4b232f5e9aad82 (patch) | |
| tree | a6e3428b3d9d16a202028e4e33104bd3f9d58f81 | |
| parent | faf7aeba27cf4f78109cabb95d0b4f1cca078e9d (diff) | |
| parent | bbc81146ecb3832e9ec1531ef6d48fec6c7c0d8c (diff) | |
Merge pull request #1572 from whitequark/bdma-blocking_wait-stop
BDMA: request stop after busy loop in blocking_wait()
| -rw-r--r-- | embassy-stm32/src/dma/bdma.rs | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/embassy-stm32/src/dma/bdma.rs b/embassy-stm32/src/dma/bdma.rs index 5fcb30f65..a307c803c 100644 --- a/embassy-stm32/src/dma/bdma.rs +++ b/embassy-stm32/src/dma/bdma.rs | |||
| @@ -323,6 +323,7 @@ impl<'a, C: Channel> Transfer<'a, C> { | |||
| 323 | 323 | ||
| 324 | pub fn blocking_wait(mut self) { | 324 | pub fn blocking_wait(mut self) { |
| 325 | while self.is_running() {} | 325 | while self.is_running() {} |
| 326 | self.request_stop(); | ||
| 326 | 327 | ||
| 327 | // "Subsequent reads and writes cannot be moved ahead of preceding reads." | 328 | // "Subsequent reads and writes cannot be moved ahead of preceding reads." |
| 328 | fence(Ordering::SeqCst); | 329 | fence(Ordering::SeqCst); |
