#[repr(C)]pub struct Object<T: DriverObject + Send + Sync> { /* private fields */ }
Expand description
A base GEM object.
Invariants
self.obj
is a valid instance of astruct drm_gem_object
.self.dev
is always a valid pointer to astruct drm_device
.
Implementations§
Trait Implementations§
Source§impl<T: DriverObject> AllocImpl for Object<T>
impl<T: DriverObject> AllocImpl for Object<T>
Source§impl<T: DriverObject> Deref for Object<T>
impl<T: DriverObject> Deref for Object<T>
Source§impl<T: DriverObject> IntoGEMObject for Object<T>
impl<T: DriverObject> IntoGEMObject for Object<T>
Auto Trait Implementations§
impl<T> !Freeze for Object<T>
impl<T> !RefUnwindSafe for Object<T>
impl<T> !Send for Object<T>
impl<T> !Sync for Object<T>
impl<T> !UnwindSafe for Object<T>
Blanket Implementations§
Source§impl<T> AlwaysRefCounted for Twhere
T: IntoGEMObject,
impl<T> AlwaysRefCounted for Twhere
T: IntoGEMObject,
Source§impl<T> BaseObject for Twhere
T: IntoGEMObject,
impl<T> BaseObject for Twhere
T: IntoGEMObject,
Source§fn create_handle(
&self,
file: &File<<<Self as IntoGEMObject>::Driver as Driver>::File>,
) -> Result<u32>
fn create_handle( &self, file: &File<<<Self as IntoGEMObject>::Driver as Driver>::File>, ) -> Result<u32>
Creates a new handle for the object associated with a given
File
(or returns an existing one).Source§fn lookup_handle(
file: &File<<<Self as IntoGEMObject>::Driver as Driver>::File>,
handle: u32,
) -> Result<ARef<Self>>
fn lookup_handle( file: &File<<<Self as IntoGEMObject>::Driver as Driver>::File>, handle: u32, ) -> Result<ARef<Self>>
Looks up an object by its handle for a given
File
.Source§fn create_mmap_offset(&self) -> Result<u64>
fn create_mmap_offset(&self) -> Result<u64>
Creates an mmap offset to map the object from userspace.
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more