0% found this document useful (0 votes)
10 views

Lecture Notes 1

Uploaded by

Daniel Melkamu
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
10 views

Lecture Notes 1

Uploaded by

Daniel Melkamu
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 2

Lecture Notes: Device Management

Device Management:

 Importance: Enables efficient and reliable interaction with hardware devices.


 Key concepts: Device drivers, interrupts, DMA, scheduling, allocation, virtualization.

A. Device Drivers:

 Software that translates software requests into device-specific commands.


 Examples:
o Keyboard driver translates keystrokes into scan codes for the operating system.
o Printer driver manages communication and data transfer with a specific printer
model. (Printer driver for handling printing tasks.)
o Network driver for managing network communication.
o Disk driver for reading and writing data to disks.

B. Interrupts:

 Signals sent by devices to the processor requesting attention.


 Example:
o Disk finishes a read operation and interrupts the CPU to transfer data.
o Keyboard sends an interrupt when a key is pressed.

C. Direct Memory Access (DMA):

 Technique allowing devices to transfer data directly to/from memory without CPU
intervention.
 Benefits:
o Improves system performance by freeing CPU for other tasks.
o Reduces CPU overhead associated with data transfer.
 Example: Graphics cards use DMA to transfer image data to memory for display.
o A network card uses DMA to transfer received data packets directly to memory.

Characteristics of Parallel and Serial Communication:

 Data transmission methods used to connect devices and transfer data.

A. Parallel Communication:

 Transmits multiple bits simultaneously across separate wires.


 Faster for short distances but complex and expensive.
 Susceptible to noise and interference over long distances.
 Limited cable length due to signal degradation.
o Example: Early printers connected via parallel ports.
B. Serial Communication:

 Transmits one bit at a time over a single wire (often with additional control signals).
 Slower than parallel but simpler and more reliable for longer distances.
 Example: Modern computer peripherals (USB, HDMI) and network connections
(Ethernet).

Recovery from Failure:

 Operating systems implement mechanisms to handle device failures and data loss.
 Techniques:
o Error detection and correction (EDC): Detects and corrects errors during data
transfer. (e.g., checksums)
o Mirroring and RAID (Redundant Array of Independent Disks): Duplicates
data across multiple disks for redundancy.
o Journaling: Records file system changes for rollback in case of crashes.
o Backups: Regularly storing data on separate media for disaster recovery.

Buffering Strategies:

 Concept: Temporary storage area used to hold data during transfer between devices with
different speeds (e.g., CPU and disk).
 Benefits:
o Improves performance by hiding device access latencies.
o Reduces CPU overhead by allowing data transfer in larger chunks.
 Types of buffering:
o Single buffering: Data is transferred from one source to a buffer and then to the
destination.
o Double buffering: Two buffers are used. While one buffer is being filled, the
other is being emptied.
o Circular buffering: Overwrites oldest data when buffer is full, useful for
continuous data streams.
 Example: A keyboard buffer stores keystrokes until enough data is accumulated to send
to the application.

Conclusion:

 Effective device management is essential for efficient and reliable operation of computer
systems.
 Understanding key concepts like device drivers, interrupts, DMA, scheduling, allocation,
buffering, and recovery techniques is crucial.
 Choosing the appropriate methods depends on specific device characteristics and system
requirements.

You might also like