Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion bbqueue/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,11 @@ version = "1.0"
default-features = false
optional = true

[dependencies.portable-atomic]
version = "1.0"
default-features = false
optional = true

[dev-dependencies.tokio]
version = "1.0"
features = ["macros", "rt", "time"]
Expand All @@ -45,7 +50,7 @@ default = [
]
critical-section = [
"dep:critical-section",
"maitake-sync?/critical-section",
"dep:portable-atomic",
]
disable-cache-padding = [
"maitake-sync?/no-cache-pad",
Expand Down
2 changes: 1 addition & 1 deletion bbqueue/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -127,9 +127,9 @@ pub mod prod_cons;
/// Queue storage
///
mod queue;
pub use queue::BBQueue;
#[cfg(feature = "alloc")]
pub use queue::ArcBBQueue;
pub use queue::BBQueue;

/// Generic traits
///
Expand Down
7 changes: 3 additions & 4 deletions bbqueue/src/traits/coordination/cs.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,9 @@
use const_init::ConstInit;

use super::{Coord, ReadGrantError, WriteGrantError};
use core::{
cmp::min,
sync::atomic::{AtomicBool, AtomicUsize, Ordering},
};
use core::cmp::min;
use core::sync::atomic::Ordering;
use portable_atomic::{AtomicBool, AtomicUsize};

/// Coordination that uses a critical section to perform coordination operations
///
Expand Down