Linux – Does the Linux kernel have its own page table

linuxlinux-kernelvirtual-memory

Different processes have different different page tables for their address spaces.

Does the Linux kernel have its own page table? If not, how are the virtual addresses of kernel translated to physical memory addresses?

In the sense that the address space of each process is divided into user space and kernel space, does the page table of each process contain the "page table" of the kernel?

Thanks.

Related Do page fault, page replacement, and paging happen to the kernel or just to processes, and to the kernel space or the user space?

Best Answer

You are correct. The VM of a process consists of the user address space and kernel address space. The kernel address space is the same across all processes but protected from access. If you've heard the 2/2 or 3/1 memory split (from x32), it was the user/kernel amount of memory in GBs. So for a 4GB address space you could (e.g.) have 3G for processes and 1G for the kernel.

I would recommend reading the "Understanding the Linux Kernel" book which will answer this and many other of your questions.