search for: drmioctldescriptor

Displaying 3 results from an estimated 3 matches for "drmioctldescriptor".

2024 Jun 18
1
[PATCH v2 1/8] rust: drm: ioctl: Add DRM ioctl abstraction
...;T>(BASE, nr) +} + +/// Construct a DRM ioctl number with a read-write argument. +#[inline(always)] +pub const fn IOWR<T>(nr: u32) -> u32 { + ioctl::_IOWR::<T>(BASE, nr) +} + +/// Descriptor type for DRM ioctls. Use the `declare_drm_ioctls!{}` macro to construct them. +pub type DrmIoctlDescriptor = bindings::drm_ioctl_desc; + +/// This is for ioctl which are used for rendering, and require that the file descriptor is either +/// for a render node, or if it?s a legacy/primary node, then it must be authenticated. +pub const AUTH: u32 = bindings::drm_ioctl_flags_DRM_AUTH; + +/// This must be s...
2024 Jun 18
1
[PATCH v2 3/8] rust: drm: add driver abstractions
...t;` or `drm::gem::shmem::Object<T>`. + type Object: AllocImpl; + + /// Driver metadata + const INFO: DriverInfo; + + /// Feature flags + const FEATURES: u32; + + /// IOCTL list. See `kernel::drm::ioctl::declare_drm_ioctls!{}`. + const IOCTLS: &'static [drm::ioctl::DrmIoctlDescriptor]; +} diff --git a/rust/kernel/drm/mod.rs b/rust/kernel/drm/mod.rs index 9ec6d7cbcaf3..d987c56b3cec 100644 --- a/rust/kernel/drm/mod.rs +++ b/rust/kernel/drm/mod.rs @@ -2,4 +2,5 @@ //! DRM subsystem abstractions. +pub mod drv; pub mod ioctl; -- 2.45.1
2024 Sep 02
2
[PATCH v2 3/8] rust: drm: add driver abstractions
...sepcified in drm_driver->features. In general these feature flag are midlayer design and that tends to be bad, rust is just the messenger here. Cheers, Sima > + > + /// IOCTL list. See `kernel::drm::ioctl::declare_drm_ioctls!{}`. > + const IOCTLS: &'static [drm::ioctl::DrmIoctlDescriptor]; > +} > diff --git a/rust/kernel/drm/mod.rs b/rust/kernel/drm/mod.rs > index 9ec6d7cbcaf3..d987c56b3cec 100644 > --- a/rust/kernel/drm/mod.rs > +++ b/rust/kernel/drm/mod.rs > @@ -2,4 +2,5 @@ > > //! DRM subsystem abstractions. > > +pub mod drv; > pub mod ioct...