RTEMS
5.0.0
|
Files | |
file | ioman.c |
RTEMS Register IO Name. | |
file | io.c |
Initialization of Device Drivers. | |
file | ioclose.c |
Closing for The IO Manager. | |
file | iocontrol.c |
Control for The IO Manager. | |
file | ioinitialize.c |
IO Driver Initialization. | |
file | ioopen.c |
Opening for The IO Manager. | |
file | ioread.c |
Reading for The IO Manager. | |
file | ioregisterdriver.c |
Classic Input/Output Manager implementation. | |
file | iounregisterdriver.c |
Unregister a Driver from the Device Driver Table. | |
file | iowrite.c |
Writing for The IO Manager. | |
Data Structures | |
struct | rtems_driver_address_table |
Typedefs | |
typedef uint32_t | rtems_device_major_number |
typedef uint32_t | rtems_device_minor_number |
typedef rtems_status_code | rtems_device_driver |
typedef rtems_device_driver(* | rtems_device_driver_entry) (rtems_device_major_number, rtems_device_minor_number, void *) |
Functions | |
rtems_status_code | rtems_io_initialize (rtems_device_major_number major, rtems_device_minor_number minor, void *argument) |
IO driver initialization. More... | |
rtems_status_code | rtems_io_open (rtems_device_major_number major, rtems_device_minor_number minor, void *argument) |
Opening for the IO manager. More... | |
rtems_status_code | rtems_io_close (rtems_device_major_number major, rtems_device_minor_number minor, void *argument) |
Closing for the IO manager. More... | |
rtems_status_code | rtems_io_read (rtems_device_major_number major, rtems_device_minor_number minor, void *argument) |
Reading for the IO manager. More... | |
rtems_status_code | rtems_io_write (rtems_device_major_number major, rtems_device_minor_number minor, void *argument) |
Writing for the IO manager. More... | |
rtems_status_code | rtems_io_control (rtems_device_major_number major, rtems_device_minor_number minor, void *argument) |
Control for the IO manager. More... | |
Device Driver Maintainance | |
rtems_status_code | rtems_io_driver_io_error (rtems_device_major_number major, rtems_device_minor_number minor, void *arg) |
Returns RTEMS_IO_ERROR . More... | |
rtems_status_code | rtems_io_register_driver (rtems_device_major_number major, const rtems_driver_address_table *driver_table, rtems_device_major_number *registered_major) |
Registers and initializes the device with the device driver table driver_table and major number major. More... | |
rtems_status_code | rtems_io_unregister_driver (rtems_device_major_number major) |
Unregister a driver from the device driver table. More... | |
rtems_status_code | rtems_io_register_name (const char *device_name, rtems_device_major_number major, rtems_device_minor_number minor) |
Registers the name device_name in the file system for the device with number tuple major and minor. More... | |
rtems_status_code rtems_io_close | ( | rtems_device_major_number | major, |
rtems_device_minor_number | minor, | ||
void * | argument | ||
) |
rtems_status_code rtems_io_control | ( | rtems_device_major_number | major, |
rtems_device_minor_number | minor, | ||
void * | argument | ||
) |
rtems_status_code rtems_io_driver_io_error | ( | rtems_device_major_number | major, |
rtems_device_minor_number | minor, | ||
void * | arg | ||
) |
Returns RTEMS_IO_ERROR
.
RTEMS_IO_ERROR | Only this one. |
rtems_status_code rtems_io_initialize | ( | rtems_device_major_number | major, |
rtems_device_minor_number | minor, | ||
void * | argument | ||
) |
rtems_status_code rtems_io_open | ( | rtems_device_major_number | major, |
rtems_device_minor_number | minor, | ||
void * | argument | ||
) |
Opening for the IO manager.
Opens a device driver with the number major.
[in] | major | is the device driver number. |
[in] | minor | is the device number. |
[in] | argument | is the pointer to the argument(s). |
rtems_status_code rtems_io_read | ( | rtems_device_major_number | major, |
rtems_device_minor_number | minor, | ||
void * | argument | ||
) |
rtems_status_code rtems_io_register_driver | ( | rtems_device_major_number | major, |
const rtems_driver_address_table * | driver_table, | ||
rtems_device_major_number * | registered_major | ||
) |
Registers and initializes the device with the device driver table driver_table and major number major.
If the major number equals zero a major number will be obtained. The major number of the registered driver will be returned in registered_major.
After a successful registration rtems_io_initialize() will be called to initialize the device.
RTEMS_SUCCESSFUL | Device successfully registered and initialized. |
RTEMS_INVALID_ADDRESS | Pointer to driver table or to registered major number are invalid. Device driver table is empty. |
RTEMS_INVALID_NUMBER | Invalid major number. |
RTEMS_TOO_MANY | No major number available. |
RTEMS_RESOURCE_IN_USE | Major number in use. |
RTEMS_CALLED_FROM_ISR | Called from interrupt context. |
* | Status code depends on rtems_io_initialize(). |
rtems_status_code rtems_io_register_name | ( | const char * | device_name, |
rtems_device_major_number | major, | ||
rtems_device_minor_number | minor | ||
) |
Registers the name device_name in the file system for the device with number tuple major and minor.
This assumes that all registered devices are character devices.
RTEMS_SUCCESSFUL | Name successfully registered. |
RTEMS_TOO_MANY | Name already in use or other errors. |
rtems_status_code rtems_io_unregister_driver | ( | rtems_device_major_number | major | ) |
Unregister a driver from the device driver table.
[in] | major | is the device major number. |
RTEMS_SUCCESSFUL | Device driver successfully unregistered. |
RTEMS_UNSATISFIED | Invalid major number. |
RTEMS_CALLED_FROM_ISR | Called from interrupt context. |
rtems_status_code rtems_io_write | ( | rtems_device_major_number | major, |
rtems_device_minor_number | minor, | ||
void * | argument | ||
) |