Expand description
Unsafe ioctl API.
Unix systems expose a number of ioctl’s. ioctls have been adopted as a
general purpose system call for making calls into the kernel. In addition
to the wide variety of system calls that are included by default in the
kernel, many drivers expose their own ioctl’s for controlling their
behavior, some of which are proprietary. Therefore it is impossible to make
a safe interface for every ioctl call, as they all have wildly varying
semantics.
This module provides an unsafe interface to write your own ioctl API. To
start, create a type that implements Ioctl. Then, pass it to ioctl
to make the ioctl call.
Structs
- Provides a bad opcode at compile time.
- Implements the traditional “getter” pattern for
ioctls. - Implements an
ioctlwith no real arguments. - Provides a
Nonecode at compile time. - The opcode used by an
Ioctl. - Provides a read code at compile time.
- Provides a read/write code at compile time.
- Implements the pattern for
ioctls where a pointer argument is given to theioctl. - Provides a write code at compile time.
Enums
- The direction that an
ioctlis going.
Traits
- Trait for something that provides an
ioctlopcode at compile time. - A trait defining the properties of an
ioctlcommand.
Functions
- Perform an
ioctlcall.
Type Definitions
- The type used by the
ioctlto signify the output. - The type used by the
ioctlto signify the command.