Operating System Concepts: Hardware Interaction and Scheduling
Operating System Fundamentals
The Operating System (OS) serves several critical roles:
- It acts as a resource manager, controlling access to the hardware.
- It provides an abstraction layer, allowing user processes to call functions that access hardware via system calls.
User Mode vs. Supervisor Mode (Kernel Mode)
The CPU enforces separation between user processes and the OS kernel:
- User Mode: Prohibits privileged instructions.
- Kernel Mode (Supervisor Mode): Allows access to all hardware and privileged operations.
Program Status Word (PSW)
The PSW is a special register holding vital information, such as:
- Access privilege mode.
- Runtime execution conditions (e.g., condition codes).
- Program Counter (PC) and Stack Pointer (SP).
Simplified Interrupt Handling Flow
- A
English with a size of 1.45 MB