Topic 13 – Input/output Contents Flashcards
describe the
status register within an I/O device
within an I/O device:
this is used to indicate for example whether more data is waiting to be collected or whether the I/O device is busy and cannot yet accept more data
this is also known as an
interrupt handler
what is an
interrupt service routine (ISR)
also known as
what is an
interrupt service routine (ISR)
also known as
this is also known as an
interrupt handler
describe the
data register within an I/O device
within an I/O device this holds the data that is to be transferred
This is a method for the control of I/O data transfers.
It involves the processor frequently polling an I/O device to check whether an event has occurred
An event can be detected by looking at the I/O devices status register which could change from busy to ready for example
describe
polled I/O
name an advantage and disadvantage of
caching
these include:
- advantage
- speed increase - since the data held in cache is instantly accessible
- disadvnatge
- Multitasking/usability vs performance - this requires its own space in main memory. There is a trade of then between processes and cache in general cache size will be reduced as more processes are loaded into memory and page faults increase
decribe how a newly connected USB device will initiate communication with the OS
the process for this is:
- The OS provides a generic USB driver to initiate the communication with the device over the bus via the bus controller
- The device can then identify itself to the OS telling it its class such as: storage, human interface device (HID) (mouse keyboard)
- Configuration will take place such as negotiating data rates
- if necessary a more specific device driver can now be found and installed for the usb device
- Data transfer continues using the bus
describe the
major number
that the OS allocates to an I/O device in order to uniquely identify it
this is a number given to a type of device such as a disk drive
any devices that share this number will be of the same type and will be sharing a device driver
describe the
direct memory access controller (DMAC)
this is an I/O device that is dedicated to transferring data between main memory and I/O devices.
It will contain its own I/O registers that the OS can use in order to give this device tasks
describe
buffering
this is a technique employed by OSs in order to reduce context switches and interrupts
with this system a processes I/O system call could potentially be satisfied instantly since the data it requires is already held in a buffer
what is being described below:
- application program interface (API) - a software interface that user applications use in order to use the service of another piece of software
- I/O system services - this is a variety of routines within this module that can carry out tasks for the layer above
- system call - this is made when the layer above must switch the processor to kernel mode in order to carry out a task on hardware
- device independent functions - these are a set of generic instructions that any driver below can understand and be plugged into
- device driver - this will translate the instruction from the layer above and format it into a specific instruction for the hardware being accessed
excluding the user applications and hardware describe each of the interfaces and layers of the I/O module

what is a
benefit of a bus interface
the benefit of this is that each device that can be connected to a system does not require its own hardware interface instead it can connect to standardized interface that is available on the system
what is a
pseudo file
within linux
this is a file that is accessible to the user but does not actually exist in storage
it is created on the fly and simply reads data from system components such as ram or internal tables of the OS
this is a number given to any new I/O devices that might share the same major number
example
a disk drive that is partitioned where each partition is treated as a separate drive
partition 1: 3.0
partition 2: 3.1
describe the
minor number
that the OS allocates to an I/O device in order to uniquely identify it
within an I/O device:
this is used to indicate for example whether more data is waiting to be collected or whether the I/O device is busy and cannot yet accept more data
describe the
status register within an I/O device
what will periphials that make use of a
bus interface
likely have built into them
periphials that make use of this will likely have their own processor and memory in order to to make negotiations with the OS and to work efficiently with the buses data transfer protocol
describe
block devices
this includes I/O devices such as disk drives where data is sent in large fixed sized blocks at a time (typically 512 bytes)
describe a
device driver
these are software written by hardware developers and can be installed within the operating system kernel. Their purpose is to control the specific hardware upon which they were written for
name two ways in which caching can be implemented
this can be implemented by:
- Buffer to cache transfer
- read-ahead caching
this method involves the OS making assumptions about what a process will do.
If a process for example was reading a block of data from disk then the OS would go ahead and assume that it will want the block after it
the OS will then transfer this assumed block to cache before the process asks for it
when/if the process does ask for this assumed block of data it can be offered instantly to the process
describe
read-ahead caching
these include:
- similarities
- they are both a dedicated space in main memory used to improve I/O operations
- differences
- a buffer will hold the only copy of that data
- a cache will hold a copy of data while the original will be held somewhere else (typically in a place that is slower to access such as seconadry storage)
name the similarities and differences between
caching and buffering
what is
busy waiting
this is a phenomenon in the OS where a process will be using a resource and will keep control of the processor until its operation on the resource is complete.
if another process wants to use the same resource it will keep hold of the processor and run a loop that keeps polling a device until it itself can satisfy its task on the resource.
while it is in this state the process is making no progress and processor time is being wasted by the process doing nothing and keeping control of the processor

describe two scenerios where
Direct memory access I/O
is particularly useful
this method of I/O data transfer is particularly usefull for:
- block devices
- slow I/O transfers
these are essential to the OS so that it can achieve device inpependence
without these it would be virtually impossible for an OS to be able to communicate with variants of hardware
why are device drivers essential for an OS



