mirror-linux/rust
Alice Ryhl 64fb810bce rust: types: rename Opaque::raw_get to cast_into
In the previous patch we added Opaque::cast_from() that performs the
opposite operation to Opaque::raw_get(). For consistency with this
naming, rename raw_get() to cast_from().

There are a few other options such as calling cast_from() something
closer to raw_get() rather than renaming this method. However, I could
not find a great naming scheme that works with raw_get(). The previous
version of this patch used from_raw(), but functions of that name
typically have a different signature, so that's not a great option.

Suggested-by: Danilo Krummrich <dakr@kernel.org>
Signed-off-by: Alice Ryhl <aliceryhl@google.com>
Acked-by: Benno Lossin <lossin@kernel.org>
Acked-by: Andreas Hindborg <a.hindborg@kernel.org>
Acked-by: Boqun Feng <boqun.feng@gmail.com>
Reviewed-by: Danilo Krummrich <dakr@kernel.org>
Acked-by: Danilo Krummrich <dakr@kernel.org>
Link: https://lore.kernel.org/r/20250624-opaque-from-raw-v2-2-e4da40bdc59c@google.com
[ Removed `HrTimer::raw_get` change. - Miguel ]
Signed-off-by: Miguel Ojeda <ojeda@kernel.org>
2025-07-15 22:26:11 +02:00
..
bindings rust: enable `clippy::ref_as_ptr` lint 2025-06-22 23:09:32 +02:00
helpers rust: helpers: sort includes alphabetically 2025-07-14 23:53:35 +02:00
kernel rust: types: rename Opaque::raw_get to cast_into 2025-07-15 22:26:11 +02:00
macros rust: macros: remove `module!`'s deprecated `author` key 2025-06-24 01:01:13 +02:00
pin-init pin-init changes for v6.17 2025-07-13 23:05:14 +02:00
uapi rust: enable `clippy::ref_as_ptr` lint 2025-06-22 23:09:32 +02:00
.gitignore rust: support running Rust documentation tests as KUnit ones 2023-07-19 09:32:53 -06:00
.kunitconfig rust: add kunitconfig 2025-03-19 23:22:21 +01:00
Makefile Rust changes for v6.16 2025-06-04 21:18:37 -07:00
bindgen_parameters rust: map `__kernel_size_t` and friends also to usize/isize 2024-11-10 23:58:00 +01:00
build_error.rs rust: add `build_error` crate 2022-12-04 01:59:16 +01:00
compiler_builtins.rs ARM: 9441/1: rust: Enable Rust support for ARMv7 2025-03-26 13:31:16 +00:00
exports.c rust: exports: improve grammar in commentary 2024-10-21 17:35:33 +02:00
ffi.rs rust: use absolute paths in macros referencing core and kernel 2025-05-23 00:12:14 +02:00