Lecture Notes for Operating Systems
Devices, 13 October 1999
These are provisional lecture notes, expect changes.
- objectives
- virtual machine - api
- performance - multiplexing, buffering, scheduling
- block-oriented devices
- large chunks of data moved between system and device
- operations - open, close, read, write, ioctl, scatter-gather i-o
- partitioning
- ram disks and other main store drivers
- ram disk - a section of main storage treated like a disk
- /dev/mem - access to physical main storage
- /dev/kmem - access to kernel space
- /dev/null - the null device
- implementation - straightforward
- open - where to create; what size; what name
- close - when to delete
- read, write - block or character oriented
- ioctl - set new sizes, gather statistics
- scatter-gather i-o - probably not relevent due to i-o speed
- disks
- hardware - disks, cylinders, sectors
- controllers - handles much of the ugliness
- driver software
- disk arm scheduling
- arm movement expensive; reasonable response time; no starvation
- first come first served
- shortest next
- elevator algorithm
- caching - pre-fetch
- multiple devices off the driver
- error detection and correction - parameters; data errors, transient
or permanent, hardware errors
This page last modified on 19 October 1999.