Re: [PATCH v2 6/8] rust: drm: file: Add File abstraction

2025-04-18 Thread Lyude Paul
On Fri, 2025-04-11 at 01:55 +0200, Danilo Krummrich wrote: > + > +/// The open callback of a `struct drm_file`. > +pub(crate) extern "C" fn open_callback( > +raw_dev: *mut bindings::drm_device, > +raw_file: *mut bindings::drm_file, > +) -> core::ffi::c_int { > +/

Re: [PATCH v2 6/8] rust: drm: file: Add File abstraction

2025-04-14 Thread Alyssa Rosenzweig
> +// SAFETY: A callback from `struct drm_driver::open` guarantees that > +// - `raw_dev` is valid pointer to a `sturct drm_device` struct > +// - the corresponding `sturct drm_device` has been registered. struct > +// SAFETY: `raw_file` valid pointer to a `stru

[PATCH v2 6/8] rust: drm: file: Add File abstraction

2025-04-10 Thread Danilo Krummrich
From: Asahi Lina A DRM File is the DRM counterpart to a kernel file structure, representing an open DRM file descriptor. Add a Rust abstraction to allow drivers to implement their own File types that implement the DriverFile trait. Reviewed-by: Maxime Ripard Signed-off-by: Asahi Lina [ Rework

[PATCH v2 6/8] rust: drm: file: Add File abstraction

2024-06-18 Thread Danilo Krummrich
From: Asahi Lina A DRM File is the DRM counterpart to a kernel file structure, representing an open DRM file descriptor. Add a Rust abstraction to allow drivers to implement their own File types that implement the DriverFile trait. Signed-off-by: Asahi Lina Signed-off-by: Danilo Krummrich ---