linux-arch.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [RFC v3 00/12] LKMM generic atomics in Rust
@ 2025-04-21 16:42 Boqun Feng
  2025-04-21 16:42 ` [RFC v3 01/12] rust: Introduce atomic API helpers Boqun Feng
                   ` (11 more replies)
  0 siblings, 12 replies; 13+ messages in thread
From: Boqun Feng @ 2025-04-21 16:42 UTC (permalink / raw)
  To: rust-for-linux, rcu, linux-kernel, linux-arch, llvm, lkmm
  Cc: Miguel Ojeda, Alex Gaynor, Boqun Feng, Gary Guo,
	Björn Roy Baron, Benno Lossin, Andreas Hindborg, Alice Ryhl,
	Alan Stern, Andrea Parri, Will Deacon, Peter Zijlstra,
	Nicholas Piggin, David Howells, Jade Alglave, Luc Maranget,
	Paul E. McKenney, Akira Yokosawa, Daniel Lustig, Joel Fernandes,
	Nathan Chancellor, Nick Desaulniers, kent.overstreet,
	Greg Kroah-Hartman, elver, Mark Rutland, Thomas Gleixner,
	Ingo Molnar, Borislav Petkov, Dave Hansen, x86, H. Peter Anvin,
	Catalin Marinas, torvalds, linux-arm-kernel, linux-fsdevel,
	Trevor Gross, dakr, Frederic Weisbecker, Neeraj Upadhyay,
	Josh Triplett, Uladzislau Rezki, Steven Rostedt,
	Mathieu Desnoyers, Lai Jiangshan, Zqiang, Paul Walmsley,
	Palmer Dabbelt, Albert Ou, linux-riscv

Hi,

v3 for LKMM atomics in Rust, you can find the previous versions:

v2: https://lore.kernel.org/rust-for-linux/20241101060237.1185533-1-boqun.feng@gmail.com/
v1: https://lore.kernel.org/rust-for-linux/20240612223025.1158537-1-boqun.feng@gmail.com/
wip: https://lore.kernel.org/rust-for-linux/20240322233838.868874-1-boqun.feng@gmail.com/

Changes since v2:

*	Drop the temporary RCU binding since they are already in
	mainline.

*	Fix a few "Ipml" typos in previous versions per feedback from
	Alice Ryhl.

*	Documentation improvement per feedback from Alice Ryhl.

I'm hoping to at least get the first 8 patches (atomic operations on
normal integer) in a good shape so that we can have them in v6.16.
Thanks!

Regards,
Boqun

Boqun Feng (12):
  rust: Introduce atomic API helpers
  rust: sync: Add basic atomic operation mapping framework
  rust: sync: atomic: Add ordering annotation types
  rust: sync: atomic: Add generic atomics
  rust: sync: atomic: Add atomic {cmp,}xchg operations
  rust: sync: atomic: Add the framework of arithmetic operations
  rust: sync: atomic: Add Atomic<u{32,64}>
  rust: sync: atomic: Add Atomic<{usize,isize}>
  rust: sync: atomic: Add Atomic<*mut T>
  rust: sync: atomic: Add arithmetic ops for Atomic<*mut T>
  rust: sync: Add memory barriers
  rust: sync: rcu: Add RCU protected pointer

 MAINTAINERS                               |    4 +-
 rust/helpers/atomic.c                     | 1038 +++++++++++++++++++++
 rust/helpers/barrier.c                    |   18 +
 rust/helpers/helpers.c                    |    2 +
 rust/kernel/sync.rs                       |    2 +
 rust/kernel/sync/atomic.rs                |  228 +++++
 rust/kernel/sync/atomic/generic.rs        |  488 ++++++++++
 rust/kernel/sync/atomic/ops.rs            |  199 ++++
 rust/kernel/sync/atomic/ordering.rs       |   94 ++
 rust/kernel/sync/barrier.rs               |   67 ++
 rust/kernel/sync/rcu.rs                   |  275 +++++-
 scripts/atomic/gen-atomics.sh             |    1 +
 scripts/atomic/gen-rust-atomic-helpers.sh |   65 ++
 13 files changed, 2479 insertions(+), 2 deletions(-)
 create mode 100644 rust/helpers/atomic.c
 create mode 100644 rust/helpers/barrier.c
 create mode 100644 rust/kernel/sync/atomic.rs
 create mode 100644 rust/kernel/sync/atomic/generic.rs
 create mode 100644 rust/kernel/sync/atomic/ops.rs
 create mode 100644 rust/kernel/sync/atomic/ordering.rs
 create mode 100644 rust/kernel/sync/barrier.rs
 create mode 100755 scripts/atomic/gen-rust-atomic-helpers.sh

-- 
2.47.1


^ permalink raw reply	[flat|nested] 13+ messages in thread

end of thread, other threads:[~2025-04-21 16:42 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-04-21 16:42 [RFC v3 00/12] LKMM generic atomics in Rust Boqun Feng
2025-04-21 16:42 ` [RFC v3 01/12] rust: Introduce atomic API helpers Boqun Feng
2025-04-21 16:42 ` [RFC v3 02/12] rust: sync: Add basic atomic operation mapping framework Boqun Feng
2025-04-21 16:42 ` [RFC v3 03/12] rust: sync: atomic: Add ordering annotation types Boqun Feng
2025-04-21 16:42 ` [RFC v3 04/12] rust: sync: atomic: Add generic atomics Boqun Feng
2025-04-21 16:42 ` [RFC v3 05/12] rust: sync: atomic: Add atomic {cmp,}xchg operations Boqun Feng
2025-04-21 16:42 ` [RFC v3 06/12] rust: sync: atomic: Add the framework of arithmetic operations Boqun Feng
2025-04-21 16:42 ` [RFC v3 07/12] rust: sync: atomic: Add Atomic<u{32,64}> Boqun Feng
2025-04-21 16:42 ` [RFC v3 08/12] rust: sync: atomic: Add Atomic<{usize,isize}> Boqun Feng
2025-04-21 16:42 ` [RFC v3 09/12] rust: sync: atomic: Add Atomic<*mut T> Boqun Feng
2025-04-21 16:42 ` [RFC v3 10/12] rust: sync: atomic: Add arithmetic ops for " Boqun Feng
2025-04-21 16:42 ` [RFC v3 11/12] rust: sync: Add memory barriers Boqun Feng
2025-04-21 16:42 ` [RFC v3 12/12] rust: sync: rcu: Add RCU protected pointer Boqun Feng

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).