Expand description
Mellanox (mlx5) domain strategy for [IbvDomainImpl].
Host and non-mlx5dv device memory use the default host/dmabuf registration. On an mlx5dv-capable device, CUDA device memory is bound to an indirect mlx5dv memory key so a whole allocator segment is addressable through a single key.
The segment scanning + binding bookkeeping lives here in Rust. Resource
creation goes through [MlxDomainOps] so the (intricate) scan/bind logic
can be unit-tested against a mock; the production implementation
([ProdMlxDomainOps]) delegates to the real functions and the
rdmaxcel_sys::rdmaxcel_bind_mr_list shim. Teardown is the Drop of the
owning RAII wrappers ([IbvMr], [Mlx5dvMkey]), correct by construction.
Structs§
- MlxDomain
- Mellanox [
IbvDomainImpl]. - Scanned
Segment - A CUDA memory segment reported by a registered scanner.
Functions§
- register_
cuda_ segment_ scanner - Register the process-wide CUDA segment scanner, replacing any previously registered one.
Type Aliases§
- Cuda
Segment Scanner - Enumerates the currently-live CUDA segments. An
Arc(notBox) so [scan_cuda_segments] can clone it out and drop the registry lock before invoking it — see that function.