aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThales Fragoso <[email protected]>2021-05-23 17:22:07 -0300
committerThales Fragoso <[email protected]>2021-05-23 17:22:07 -0300
commit9c5d4d9f8abe498b903c74293116d0ecce245b8a (patch)
treedb73071b954a0ea245e35c1c2d31ce00db13a957
parent66f232574addfa12438fe3303e599039f56a4437 (diff)
STM32 Clock: Use atomic-polyfill
-rw-r--r--embassy-stm32/Cargo.toml1
-rw-r--r--embassy-stm32/src/clock.rs3
2 files changed, 3 insertions, 1 deletions
diff --git a/embassy-stm32/Cargo.toml b/embassy-stm32/Cargo.toml
index ae92e0002..43d5250e5 100644
--- a/embassy-stm32/Cargo.toml
+++ b/embassy-stm32/Cargo.toml
@@ -21,6 +21,7 @@ sdio-host = { version = "0.5.0", optional = true }
21embedded-sdmmc = { git = "https://github.com/thalesfragoso/embedded-sdmmc-rs", branch = "async", optional = true } 21embedded-sdmmc = { git = "https://github.com/thalesfragoso/embedded-sdmmc-rs", branch = "async", optional = true }
22critical-section = "0.2.1" 22critical-section = "0.2.1"
23bare-metal = "1.0.0" 23bare-metal = "1.0.0"
24atomic-polyfill = "0.1.2"
24 25
25[build-dependencies] 26[build-dependencies]
26regex = "1.4.6" 27regex = "1.4.6"
diff --git a/embassy-stm32/src/clock.rs b/embassy-stm32/src/clock.rs
index b4f735efa..709a2d36c 100644
--- a/embassy-stm32/src/clock.rs
+++ b/embassy-stm32/src/clock.rs
@@ -2,8 +2,9 @@
2 2
3use core::cell::Cell; 3use core::cell::Cell;
4use core::convert::TryInto; 4use core::convert::TryInto;
5use core::sync::atomic::{compiler_fence, AtomicU32, Ordering}; 5use core::sync::atomic::{compiler_fence, Ordering};
6 6
7use atomic_polyfill::AtomicU32;
7use embassy::interrupt::InterruptExt; 8use embassy::interrupt::InterruptExt;
8use embassy::time::{Clock as EmbassyClock, TICKS_PER_SECOND}; 9use embassy::time::{Clock as EmbassyClock, TICKS_PER_SECOND};
9 10