#[repr(u8)]pub enum EntryLevel {
Pml4 = 3,
Pdpt = 2,
Pd = 1,
Pt = 0,
}Expand description
The depth of an x64 page table
Variants§
Implementations§
Source§impl EntryLevel
impl EntryLevel
Sourcepub fn mapping_size(self) -> u64
pub fn mapping_size(self) -> u64
The amount of memory that can be mapped by an entry in a page table. If the entry is a leaf, this value represents the size of the entry, otherwise it represents the maximum amount of physical memory space that can be mapped if all mappings below this entry are used
Sourcepub fn leaf(self, va: u64) -> PageTableEntryType
pub fn leaf(self, va: u64) -> PageTableEntryType
Returns a leaf entry for a virtual address in this level
Sourcepub fn directory_pa(self, va: u64) -> u64
pub fn directory_pa(self, va: u64) -> u64
Returns the physical address of the directory entry for a va at this level Assumes that the directory is part of an identity mapping
Trait Implementations§
Source§impl Clone for EntryLevel
impl Clone for EntryLevel
Source§fn clone(&self) -> EntryLevel
fn clone(&self) -> EntryLevel
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for EntryLevel
impl Debug for EntryLevel
Source§impl Ord for EntryLevel
impl Ord for EntryLevel
Source§fn cmp(&self, other: &EntryLevel) -> Ordering
fn cmp(&self, other: &EntryLevel) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialEq for EntryLevel
impl PartialEq for EntryLevel
Source§impl PartialOrd for EntryLevel
impl PartialOrd for EntryLevel
impl Copy for EntryLevel
impl Eq for EntryLevel
impl StructuralPartialEq for EntryLevel
Auto Trait Implementations§
impl Freeze for EntryLevel
impl RefUnwindSafe for EntryLevel
impl Send for EntryLevel
impl Sync for EntryLevel
impl Unpin for EntryLevel
impl UnwindSafe for EntryLevel
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more