next up previous contents index
Next: 4.1 Describing the Page Up: understand-html Previous: 3.3 Pages   Contents   Index


4. Page Table Management

Linux is unusual with how it layers the machine independent/dependent layer[#!cranor99!#] as while many other operating systems such objects like the pmap object in BSD Linux instead always maintains the concept of a three-level page table in the architecture independent code even if the underlying architecture does not support it. While this is relatively easy to understand, it also means that the distinction between different types of pages is very blurry and page types are identified by their flags or what lists they exist on rather than the objects they belong to.

Architectures that manage their MMU differently are expected to emulate the three-level page tables. For example, on the x86 without Physical Address Extensions (PAE) mode enabled, only two page table levels are available. The Page Middle Directory (PMD) is defined to be of size 1 and folds back directly onto the Page Global Directory (PGD) which is optimized out at compile time. Unfortunately, for architectures that do not manage their cache or TLB automatically, hooks for machine dependent have to be explicitly left in the code for when the TLB and CPU caches need to be altered and flushed even if they are null operations on some architectures like the x86. Fortunately, the functions and how they have to be used is very well documented in the cachetlb.txt file in the kernel documentation tree[#!miller00!#].



Subsections
next up previous contents index
Next: 4.1 Describing the Page Up: understand-html Previous: 3.3 Pages   Contents   Index
Mel 2003-01-14