File tree Expand file tree Collapse file tree 3 files changed +8
-8
lines changed Expand file tree Collapse file tree 3 files changed +8
-8
lines changed Original file line number Diff line number Diff line change @@ -8,7 +8,7 @@ mod mutex;
8
8
pub use mutex:: * ;
9
9
mod critical_section;
10
10
pub use self :: critical_section:: * ;
11
- #[ cfg( feature = "atomic-device" ) ]
11
+ #[ cfg( any ( feature = "atomic-device" , target_has_atomic = "8" ) ) ]
12
12
mod atomic;
13
- #[ cfg( feature = "atomic-device" ) ]
13
+ #[ cfg( any ( feature = "atomic-device" , target_has_atomic = "8" ) ) ]
14
14
pub use atomic:: * ;
Original file line number Diff line number Diff line change @@ -11,11 +11,11 @@ pub use refcell::*;
11
11
mod mutex;
12
12
#[ cfg( feature = "std" ) ]
13
13
pub use mutex:: * ;
14
- #[ cfg( feature = "atomic-device" ) ]
14
+ #[ cfg( any ( feature = "atomic-device" , target_has_atomic = "8" ) ) ]
15
15
mod atomic;
16
16
mod critical_section;
17
17
mod shared;
18
- #[ cfg( feature = "atomic-device" ) ]
18
+ #[ cfg( any ( feature = "atomic-device" , target_has_atomic = "8" ) ) ]
19
19
pub use atomic:: * ;
20
20
21
21
pub use self :: critical_section:: * ;
Original file line number Diff line number Diff line change 3
3
#[ allow( unused_imports) ]
4
4
use core:: cell:: UnsafeCell ;
5
5
6
- #[ cfg( feature = "atomic-device" ) ]
6
+ #[ cfg( any ( feature = "atomic-device" , target_has_atomic = "8" ) ) ]
7
7
/// Cell type used by [`spi::AtomicDevice`](crate::spi::AtomicDevice) and [`i2c::AtomicDevice`](crate::i2c::AtomicDevice).
8
8
///
9
9
/// To use `AtomicDevice`, you must wrap the bus with this struct, and then
@@ -12,12 +12,12 @@ pub struct AtomicCell<BUS> {
12
12
pub ( crate ) bus : UnsafeCell < BUS > ,
13
13
pub ( crate ) busy : portable_atomic:: AtomicBool ,
14
14
}
15
- #[ cfg( feature = "atomic-device" ) ]
15
+ #[ cfg( any ( feature = "atomic-device" , target_has_atomic = "8" ) ) ]
16
16
unsafe impl < BUS : Send > Send for AtomicCell < BUS > { }
17
- #[ cfg( feature = "atomic-device" ) ]
17
+ #[ cfg( any ( feature = "atomic-device" , target_has_atomic = "8" ) ) ]
18
18
unsafe impl < BUS : Send > Sync for AtomicCell < BUS > { }
19
19
20
- #[ cfg( feature = "atomic-device" ) ]
20
+ #[ cfg( any ( feature = "atomic-device" , target_has_atomic = "8" ) ) ]
21
21
impl < BUS > AtomicCell < BUS > {
22
22
/// Create a new `AtomicCell`
23
23
pub fn new ( bus : BUS ) -> Self {
You can’t perform that action at this time.
0 commit comments