summaryrefslogtreecommitdiff
path: root/rust/kernel/xarray.rs
AgeCommit message (Collapse)Author
2025-05-01rust: xarray: Add an abstraction for XArrayTamir Duberstein
`XArray` is an efficient sparse array of pointers. Add a Rust abstraction for this type. This implementation bounds the element type on `ForeignOwnable` and requires explicit locking for all operations. Future work may leverage RCU to enable lockless operation. Inspired-by: MaĆ­ra Canal <mcanal@igalia.com> Inspired-by: Asahi Lina <lina@asahilina.net> Reviewed-by: Andreas Hindborg <a.hindborg@kernel.org> Reviewed-by: Alice Ryhl <aliceryhl@google.com> Signed-off-by: Tamir Duberstein <tamird@gmail.com> Link: https://lore.kernel.org/r/20250423-rust-xarray-bindings-v19-2-83cdcf11c114@gmail.com Signed-off-by: Andreas Hindborg <a.hindborg@kernel.org>