Thursday, March 28, 2013

Device Management


Device Management

·         Several peripheral devices like mouse, hard disk, printer, plotter etc. are connected to the computer. The peripheral devices have varying characteristics like character or block device, sequential or random access device, and dedicated or shared device.
·         OS manages and controls the devices attached to the computer. OS provides appropriate functionality to the application programs for controlling different aspects of the devices. Figure shows the device manager and system properties in Windows XP Professional.
·         OS handles the devices by combining both hardware and software techniques. The I/O hardware includes the ports, buses, and device controllers for the devices. The OS communicates with the I/O hardware via the device driver software. The device driver software comes along with each device.
·         A device communicates with the computer hardware via a port (for example, a serial port or a parallel port). Bus is a common set of wires used by one or more devices. The computer uses different kinds of buses like PCI bus for connecting processor or memory to the fast devices, expansion bus to connect to slow I/O devices and SCSI bus to connect disks. A device controller operates a port, bus, and a device. Device controller is just like a bridge between the device and the operating system. The device controller receives the data from a connected device, stores it temporarily, and then communicates the data to the device’s device driver. Device driver is the software with which the device controller communicates with the operating system 

·         Operating system enables handling of the different I/O devices in a uniform way. The complexity of handling the different devices is abstracted and hidden in the device drivers of the devices. The device drivers hide the differences among the different device controllers and present a uniform interface to the operating system.
·         In addition to managing the peripheral devices, OS also provides various services related to I/O like I/O scheduling, buffering, spooling, and error handling.
·         Scheduling of I/O requests involves ordering the requests to improve performance of the system and provide fair access to all processes. For this, a queue of request is maintained for each device. The I/O scheduler re-arranges the queue to improve the efficiency of the overall system.

·         Buffer is a memory area that stores the data, while it is being transferred between two devices or between a device and an application. The speed at which the I/O device can transfer data is different from the speed at which the data is processed.Buffering handles the speed mismatch by storing the data in a buffer till the complete data has arrived and then writing it in a single write operation.
·         Spool (Simultaneous Peripheral Operation On-Line) is a buffer in memory area or disk.Spooling stores the jobs in a spool where the device can access it when it is ready. Spooling is commonly used for printers. Users may give several print commands, and continue working with other operations. The printer can print only one job at a time. The rest of the jobs are stored in the spool in a queue, and the printer accesses the spool when it is ready to print the next job.

No comments:

Post a Comment