Computer System Structure
by Goh Jia Wei

1. CPU Protection
1.1. Timer interrupts computer after specified period to ensure operating system maintains control over CPU
1.2. When timer interrupts, control transfers to the operating system.
1.3. Load-timer is a privileged instruction
2. Storage Hierarchy
2.1. Caching is copying information into faster storage system; main memory can be viewed as a last cache for secondary storage.
2.2. The storage systems organized in hierarchy is speed , cost and volatility
3. IO priotection
3.1. User program must executes a system call to request that the operating system to perform I/O.
3.2. User program could never gain control of the computer in monitor mode
4. Interrupt Handling
4.1. Interrupt service routine
4.1.1. Part of the operating system which takes action in response to the condition that caused the interrupt
4.1.2. When the CPU is interrupted, it stops what it is doing and immediately transfers execution to a fixed location
4.1.3. Interrupt vector provide the address of the interrupt service routine for the interrupting device.
5. Computer-System Operation
5.1. Each device controller is in charge of a specific type of device.
5.2. Each device controller has a local buffer.
5.3. Device controller informs CPU that it has finished its operation by causing an interrupt.
6. Use of A System Call to Perform I/O
7. Memory protection
7.1. Base register
7.2. holds the smallest legal physical memory address.
7.3. Limit register
7.4. contains the size of the range
8. Modes of Operation
8.1. User Mode
8.1.1. 1. user program executes in user mode
8.1.2. 2. certain areas of memory are protected from user access
8.1.3. 3. certain instructions may not be executed
8.2. Kernel Mode
8.2.1. 1. monitor executes in kernel mode
8.2.2. 2. privileged instructions may be executed
8.2.3. 3. protected areas of memory may be accessed