linux-yocto/rust
Danilo Krummrich 72097f917f rust: drm: don't pass the address of drm::Device to drm_dev_put()
[ Upstream commit 360077278ba62e81310080f075a1a3028e778ef9 ]

In drm_dev_put() call in AlwaysRefCounted::dec_ref() we rely on struct
drm_device to be the first field in drm::Device, whereas everywhere
else we correctly obtain the address of the actual struct drm_device.

Analogous to the from_drm_device() helper, provide the
into_drm_device() helper in order to address this.

Fixes: 1e4b8896c0 ("rust: drm: add device abstraction")
Reviewed-by: Alice Ryhl <aliceryhl@google.com>
Link: https://lore.kernel.org/r/20250731154919.4132-5-dakr@kernel.org
Signed-off-by: Danilo Krummrich <dakr@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2025-08-28 16:34:43 +02:00
..
bindings rust: completion: implement initial abstraction 2025-06-13 23:46:56 +02:00
helpers Driver core fixes for 6.16-rc3 2025-06-18 14:31:16 -07:00
kernel rust: drm: don't pass the address of drm::Device to drm_dev_put() 2025-08-28 16:34:43 +02:00
macros rust: use #[used(compiler)] to fix build and modpost with Rust >= 1.89.0 2025-07-14 23:30:44 +02:00
pin-init pin-init changes for v6.16 2025-05-18 20:42:49 +02:00
uapi drm for 6.16-rc1 2025-05-28 09:46:39 -07:00
.gitignore
.kunitconfig rust: add kunitconfig 2025-03-19 23:22:21 +01: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
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
Makefile rust: workaround rustdoc target modifiers bug 2025-08-20 18:41:35 +02:00