The Input/Output (I/O) subsystem exists on most operating systems for three main reasons:
- to hide device-specific details in device drivers through which the operating system transfers data and control
- to provide a fair and safe access scheme to the devices, since most of them are shared resources
- to provide a consistent, uniform, and flexible interface to all devices, allowing programs to reference devices by name and perform high-level operations without knowing the device configuration.
Usually, the I/O software is structured in layers:
- device-independent system interface
- device drivers
- interrupt handlers
The interrupt handler is mainly responsible for waking up a device driver after an I/O operation completes. The device driver performs device-specific operations, such as setting up registers for DMA and checking device status. The device-independent system interface provides a uniform interface to user-level software and common I/O functions (that is, protection, blocking, buffering) that can be performed across different devices.
For the RCP, there are two modes of I/O operations:
- DMA provides a minimum of 64-bit transfer between the RDRAM and any of the devices
- IO provides a 32-bit transfer between the CPU and any of the devices
The RCP consists of the following major devices and interfaces (see Figure 8.1.1 below):