Skip to content

Commit 14e9a18

Browse files
committed
rust: sync: atomic: Make Atomic*Ops pub(crate)
In order to write code over a generate Atomic<T> we need to make Atomic*Ops public so that functions like `.load()` and `.store()` are available. Make these pub(crate) at the beginning so the usage in kernel crate is supported. Tested-by: David Gow <davidgow@google.com> Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: Boqun Feng <boqun.feng@gmail.com> Link: https://patch.msgid.link/20251022035324.70785-2-boqun.feng@gmail.com
1 parent b94d45b commit 14e9a18

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

rust/kernel/sync/atomic.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,10 @@ mod predefine;
2222

2323
pub use internal::AtomicImpl;
2424
pub use ordering::{Acquire, Full, Relaxed, Release};
25+
pub(crate) use internal::{AtomicArithmeticOps, AtomicBasicOps, AtomicExchangeOps};
2526

2627
use crate::build_error;
27-
use internal::{AtomicArithmeticOps, AtomicBasicOps, AtomicExchangeOps, AtomicRepr};
28+
use internal::AtomicRepr;
2829
use ordering::OrderingType;
2930

3031
/// A memory location which can be safely modified from multiple execution contexts.

0 commit comments

Comments
 (0)