pub struct Getter<Opcode, Output> { /* private fields */ }
Expand description
Implements the traditional “getter” pattern for ioctl
s.
Some ioctl
s just read data into the userspace. As this is a popular
pattern this structure implements it.
Implementations§
Trait Implementations§
source§impl<Opcode: CompileTimeOpcode, Output> Debug for Getter<Opcode, Output>
impl<Opcode: CompileTimeOpcode, Output> Debug for Getter<Opcode, Output>
source§impl<Opcode: CompileTimeOpcode, Output> Ioctl for Getter<Opcode, Output>
impl<Opcode: CompileTimeOpcode, Output> Ioctl for Getter<Opcode, Output>
source§const IS_MUTATING: bool = true
const IS_MUTATING: bool = true
Does the
ioctl
mutate any data in the userspace? Read moresource§fn as_ptr(&mut self) -> *mut c_void
fn as_ptr(&mut self) -> *mut c_void
Get a pointer to the data to be passed to the
ioctl
command. Read moresource§unsafe fn output_from_ptr(
_: IoctlOutput,
ptr: *mut c_void
) -> Result<Self::Output>
unsafe fn output_from_ptr( _: IoctlOutput, ptr: *mut c_void ) -> Result<Self::Output>
Cast the output data to the correct type. Read more