1. Protection
1.1. I/O protection
1.1.1. privileged instructions.
1.1.1.1. user can't issue I/O instruction directly
1.1.1.2. User must executes a system, call to request the OS to perform I/O
1.1.2. Must ensure the user couldn't gain control of the computer in monitor mode
1.1.2.1. e.g, a user program, as part of its execution, stores a new address in the interrupt vector
1.2. Memory protection
1.2.1. must provide memory protection at least for the interrupt vector and the interrupt service routines.
1.2.2. Two register are used
1.2.2.1. Base register
1.2.2.1.1. holds the smallest legal physical memory address
1.2.2.2. limit register
1.2.2.2.1. contains the size of the range
1.2.3. memory outside the defined range is protected
1.3. Hardware Address Protection
1.3.1. when in kernel mode, the OS has unrestricted access to both monitor and user's memory
1.3.1.1. OS is allowed to load users' programs into users' memory
1.3.1.1.1. to access and modify parameters of system calls.
1.3.2. The load instructions for the base and limit registers are privilege instruction.
1.4. CPU protection
1.4.1. Timer
1.4.1.1. Interrupts computer after specified period to ensure OS maintains control over CPU
1.4.1.1.1. Every time the clock ticks, the counter is decremented
1.4.1.1.2. when time reaches the value 0, an interrupt occurs.
1.4.2. timer interrupts, control transfer to the OS
1.4.3. Load- timer is a privileged instruction.
2. Storage structure
2.1. Storage hierarchy
2.1.1. storage system organised in hierarchy
2.1.1.1. speed
2.1.1.2. cost
2.1.1.3. volatility
2.1.2. Caching
2.1.2.1. Copy infor into faster storage system
2.1.2.1.1. main memory can be viewed as a last cache for 2ndary storage
2.2. Secondary storage
2.2.1. Capable to hold large quantities of data permanently.
2.2.2. extension of main memory that provides nonvolatile storage capacity/
2.3. Main Memory
2.3.1. A volatile storage device
2.3.1.1. lose its contents when power is turned off
2.3.2. only large storage media that the CPU can access directly
2.4. Storage device hierarchy
2.4.1. 1. register
2.4.2. 2. Cache
2.4.3. 3. main memory
2.4.4. 4. electronic disk
2.4.5. 5. magnetic disk
2.4.6. 6. optical disk
2.4.7. 7. magnetic tapes
3. Operation
3.1. A general-purpose computer consists >=1 CPU
3.1.1. can execute concurrently
3.2. A general-purpose computer consists a number of device controllers.
3.2.1. in charge of a specific type of device.
3.2.2. has a local buffer
3.2.3. informs CPU that it has finished its operation by causing an interrupt
3.2.3.1. Interrupt indicates the occurrence