Linux Kernel introduction:
A) LINUX architecture:
I. user space: application, C library
Ii. kernel space: Code related to the system call interface, kernel, and architecture
Iii. Reason for layering: the operating system itself is fully protected. There are many restrictions in user space.
Iv. Transfer: Transfers from user space to kernel space through system calls and hardware interruptions.
B) CPU working mode: ARM is used as an example. There are seven working modes: user mode, fast interruption, external interruption, management mode, data access suspension, system mode, and undefined command exception.
C) Linux kernel architecture:
I. System Call interface: the user layer enters the kernel Channel
Ii. Process Management: Process Scheduling and inter-process communication
Iii. Memory Management: memory allocation, recovery, address conversion,
Iv. ARCH: CPU-related code, which is used to conveniently change the code during system transplantation,
V. Device Driver:
Vi. Network Protocol Stack: supports multiple network protocols
Vii. Virtual File System VFS: hides details of various file systems and provides unified interfaces for file operations.