Re: [PATCH v2 6/7] rust: drm: return impl PinInit from DriverFile::open()
From: Gary Guo
Date: Wed Nov 11 2026 - 04:56:35 EST
On Sat Nov 7, 2026 at 2:03 AM GMT, Danilo Krummrich wrote:
> Change DriverFile::open() to return impl PinInit<Self, Error> instead of
> Result<Pin<KBox<Self>>>, consistent with how bus device private data
> works.
>
> Drivers no longer need to allocate a Pin<KBox<_>> themselves; they just
> return an initializer and the subsystem takes care of the allocation.
>
> Reviewed-by: Alice Ryhl <aliceryhl@xxxxxxxxxx>
> Signed-off-by: Danilo Krummrich <dakr@xxxxxxxxxx>
Reviewed-by: Gary Guo <gary@xxxxxxxxxxx>
> ---
> drivers/gpu/drm/nova/file.rs | 5 ++---
> drivers/gpu/drm/tyr/file.rs | 4 ++--
> rust/kernel/drm/file.rs | 5 +++--
> rust/kernel/drm/gem/shmem.rs | 4 ++--
> 4 files changed, 9 insertions(+), 9 deletions(-)