I/O Software is used for interaction with I/O devices like mouse, keyboard, USB devices, printers, etc. I/O software are organized in following ways:
User Level Libraries– Provides an simple interface to program for input output functions.
Kernel Level Modules– Provides device driver to interact with the device independent I/O modules and device controller.
Hardware-A layer including hardware controller and actual hardware which interact with device drivers.
Goals Of I/O Software
Here we talk about the goals of I/O software
Uniform naming: For example naming of files systems in Operating Systems is done in a way that user does not have to be aware of underlying hardware name.
Synchronous versus Asynchronous: When the CPU is working on some process it goes in the block state when the interrupt occurs. Therefore most of the devices are asynchronous. And if the I/O operation are in blocking state it is much easier to write the I/O operation. It is always the operating system responsibility to create such a interrupt driven user program.
Device Independence: The most important part of I/O software is device independence. It is always most preferable to write program which can open all other I/O devices. For example, it is not necessary to write the input taking program again and again for taking input from various file and devices. As this creates much work to do and also much space to store the different programs.
Buffering: Data that we enter into a system cannot be stored directly in memory. For example the data is converted into smaller groups and then transferred to outer buffer for examination.
Buffer have major impact on I/O software as it is the one which ultimately helps storing the data and copying data. Many device have constraints and just to avoid it some data is always put into the buffer in advance so the buffer rate of getting filled with data and getting empty remains balanced
Error handling: Errors and mostly generated by controller and also they are mostly handled by controller itself. When lower level solves the problem it does not reach the upper level.
Shareable and Non-Shareable Devices : Devices like Hard Disk can be shared among multiple process while devices like Printers cannot be shared. The goal of I/O software is to handle both types of devices.
Attention reader! Don’t stop learning now. Get hold of all the important CS Theory concepts for SDE interviews with the CS Theory Course at a student-friendly price and become industry ready.