Kernel mode and User mode
kernel mode
- When CPU in kernel mode, the code being executed can access any memory address and any hardware resources.
- Hence kernel mode is very privileged and powerful mode.
- If a program crashed in kernel mode, the entire system will be halted.
user mode
- When CPU is in user mode, the program's don't have direct access to memory and hardware resources.
- If a program crashed in user mode, that the particular program will be halted.
- That means the system will be in a safe state even if a program in user mode crushes
- Hence, most programs in an OS run as user mode.
System call
When a program in user mode access RAM and a hardware resources, it must ask the kernel to provide access to that resources. This is done via some thing called a System call.
What about Kernel mode or User mode? What is System call?
Reviewed by Pappy
on
July 29, 2019
Rating:
No comments: