diff options
| author | 2026-02-06 15:00:17 +0900 | |
|---|---|---|
| committer | 2026-03-17 20:02:09 +0100 | |
| commit | 1d1c5c73d7e8f166b6b55ae06a3c509561b854cd (patch) | |
| tree | 4244141fad33544e6b01a5630a03cd6a18a1e2b2 /include/linux/soc/apple/git:/git.zx2c4.com/ssh:/git@git.zx2c4.com | |
| parent | rust: io: mem: use non-relaxed I/O ops in examples (diff) | |
rust: io: provide Mmio relaxed ops through a wrapper type
Relaxed I/O accessors for `Mmio` are currently implemented as an extra
set of methods that mirror the ones defined in `Io`, but with the
`_relaxed` suffix.
This makes these methods impossible to use with generic code, which is a
highly plausible proposition now that we have the `Io` trait.
Address this by adding a new `RelaxedMmio` wrapper type for `Mmio` that
provides its own `IoCapable` implementations relying on the relaxed C
accessors. This makes it possible to use relaxed operations on a `Mmio`
simply by wrapping it, and to use `RelaxedMmio` in code generic against
`Io`.
Acked-by: Alice Ryhl <aliceryhl@google.com>
Signed-off-by: Alexandre Courbot <acourbot@nvidia.com>
Reviewed-by: Daniel Almeida <daniel.almeida@collabora.com>
Reviewed-by: Gary Guo <gary@garyguo.net>
Link: https://patch.msgid.link/20260206-io-v2-3-71dea20a06e6@nvidia.com
[ Use kernel import style in examples. - Danilo ]
Signed-off-by: Danilo Krummrich <dakr@kernel.org>
Diffstat (limited to 'include/linux/soc/apple/git:/git.zx2c4.com/ssh:/git@git.zx2c4.com')
0 files changed, 0 insertions, 0 deletions
