Crate page_table
source ·Expand description
This crate provides generic, unified, architecture-independent, and OS-free page table structures for various hardware architectures.
The core struct is PageTable64<M, PTE, IF>
. OS-functions and
architecture-dependent types are provided by generic parameters:
M
: The architecture-dependent metadata, requires to implement thePagingMetaData
trait.PTE
: The architecture-dependent page table entry, requires to implement theGenericPTE
trait.IF
: OS-functions such as physical memory allocation, requires to implement thePagingIf
trait.
Currently supported architectures and page table structures:
- x86:
x86_64::X64PageTable
- ARM:
aarch64::A64PageTable
- RISC-V:
riscv::Sv39PageTable
,riscv::Sv48PageTable
Re-exports
pub use page_table_entry::GenericPTE;
pub use page_table_entry::MappingFlags;
Modules
- AArch64 specific page table structures.
- RISC-V specific page table structures.
- x86 specific page table structures.
Structs
- A generic page table struct for 64-bit platform.
Enums
- The page sizes supported by the hardware page table.
- The error type for page table operation failures.
Traits
- The low-level OS-dependent helpers that must be provided for
PageTable64
. - The architecture-dependent metadata that must be provided for
PageTable64
.
Type Aliases
- The specialized
Result
type for page table operations.