From: Boqun Feng Date: Wed, 22 Oct 2025 03:53:22 +0000 (-0400) Subject: rust: sync: atomic: Make Atomic*Ops pub(crate) X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=14e9a18b07ec463a85094cc8942788336164319f;p=thirdparty%2Fkernel%2Flinux.git rust: sync: atomic: Make Atomic*Ops pub(crate) In order to write code over a generate Atomic 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 Acked-by: Greg Kroah-Hartman Signed-off-by: Boqun Feng Link: https://patch.msgid.link/20251022035324.70785-2-boqun.feng@gmail.com --- diff --git a/rust/kernel/sync/atomic.rs b/rust/kernel/sync/atomic.rs index 016a6bcaf0807..0bc6e7b04d673 100644 --- a/rust/kernel/sync/atomic.rs +++ b/rust/kernel/sync/atomic.rs @@ -22,9 +22,10 @@ mod predefine; pub use internal::AtomicImpl; pub use ordering::{Acquire, Full, Relaxed, Release}; +pub(crate) use internal::{AtomicArithmeticOps, AtomicBasicOps, AtomicExchangeOps}; use crate::build_error; -use internal::{AtomicArithmeticOps, AtomicBasicOps, AtomicExchangeOps, AtomicRepr}; +use internal::AtomicRepr; use ordering::OrderingType; /// A memory location which can be safely modified from multiple execution contexts.