Struct pagemap::PageMapEntry [−][src]
pub struct PageMapEntry { /* fields omitted */ }
An entry read from /proc/<PID>/pagemap
for a process, and optionally from /proc/kpagecount
and /proc/kpageflags
too.
Documentation and details about the various bits of the API can be found in Linux, at
doc/Documentation/vm/pagemap.txt
.
Implementations
impl PageMapEntry
[src]
impl PageMapEntry
[src]Constants are defined in Linux, at fs/proc/task_mmu.c
.
pub const PM_PFRAME_BITS: u64
[src]
pub const PM_PFRAME_MASK: u64
[src]
pub const PM_SOFT_DIRTY: u64
[src]
pub const PM_MMAP_EXCLUSIVE: u64
[src]
pub const PM_FILE: u64
[src]
pub const PM_SWAP: u64
[src]
pub const PM_PRESENT: u64
[src]
pub fn raw_pagemap(&self) -> u64
[src]
pub fn raw_pagemap(&self) -> u64
[src]The raw u64
value as read from procfs(5)
.
pub fn present(&self) -> bool
[src]
pub fn present(&self) -> bool
[src]Returns true
if the Self::PM_PRESENT
bit is set; false
otherwise.
pub fn swapped(&self) -> bool
[src]
pub fn swapped(&self) -> bool
[src]Returns true
if the Self::PM_SWAP
bit is set; false
otherwise.
pub fn file_mapped(&self) -> bool
[src]
pub fn file_mapped(&self) -> bool
[src]Returns true
if the Self::PM_FILE
bit is set; false
otherwise.
pub fn shared_anonymous(&self) -> bool
[src]
pub fn shared_anonymous(&self) -> bool
[src]Returns true
if the Self::PM_FILE
bit is clear; false
otherwise.
pub fn exclusively_mapped(&self) -> bool
[src]
pub fn exclusively_mapped(&self) -> bool
[src]Returns true
if the Self::PM_MMAP_EXCLUSIVE
bit is set; false
otherwise.
pub fn soft_dirty(&self) -> bool
[src]
pub fn soft_dirty(&self) -> bool
[src]Returns true
if the Self::PM_SOFT_DIRTY
bit is set; false
otherwise.
pub fn pfn(&self) -> Result<u64>
[src]
pub fn pfn(&self) -> Result<u64>
[src]Returns the page frame number (decoding bits 0-54) if the Self::PM_PRESENT
bit is set;
otherwise returns an error.
pub fn swap_type(&self) -> Result<u8>
[src]
pub fn swap_type(&self) -> Result<u8>
[src]Returns the swap type (decoding bits 0-4) if the Self::PM_SWAP
bit is set; otherwise
returns an error.
pub fn swap_offset(&self) -> Result<u64>
[src]
pub fn swap_offset(&self) -> Result<u64>
[src]Returns the swap offset (decoding bits 5-55) if the Self::PM_SWAP
bit is set; otherwise
returns an error.
pub fn kpagecount(&self) -> Option<u64>
[src]
pub fn kpagecount(&self) -> Option<u64>
[src]The raw u64
value as read from procfs(5)
, or None
if /proc/kpagecount
could not
be accessed.
pub fn kpageflags(&self) -> Option<KPageFlags>
[src]
pub fn kpageflags(&self) -> Option<KPageFlags>
[src]The KPageFlags
parsed from /proc/kpageflags
for the page frame in this
PageMapEntry
.
pub fn raw_kpageflags(&self) -> Option<u64>
[src]
pub fn raw_kpageflags(&self) -> Option<u64>
[src]The raw u64
value as read from procfs(5)
, or None
if /proc/kpageflags
could not
be accessed.
pub fn locked(&self) -> Option<bool>
[src]
pub fn locked(&self) -> Option<bool>
[src]Returns Some(true)
if the corresponding bit is set; Some(false)
otherwise.
It returns None
if /proc/kpageflags
could not be read for the page at hand.
pub fn error(&self) -> Option<bool>
[src]
pub fn error(&self) -> Option<bool>
[src]Returns Some(true)
if the corresponding bit is set; Some(false)
otherwise.
It returns None
if /proc/kpageflags
could not be read for the page at hand.
pub fn referenced(&self) -> Option<bool>
[src]
pub fn referenced(&self) -> Option<bool>
[src]Returns Some(true)
if the corresponding bit is set; Some(false)
otherwise.
It returns None
if /proc/kpageflags
could not be read for the page at hand.
pub fn uptodate(&self) -> Option<bool>
[src]
pub fn uptodate(&self) -> Option<bool>
[src]Returns Some(true)
if the corresponding bit is set; Some(false)
otherwise.
It returns None
if /proc/kpageflags
could not be read for the page at hand.
pub fn dirty(&self) -> Option<bool>
[src]
pub fn dirty(&self) -> Option<bool>
[src]Returns Some(true)
if the corresponding bit is set; Some(false)
otherwise.
It returns None
if /proc/kpageflags
could not be read for the page at hand.
pub fn lru(&self) -> Option<bool>
[src]
pub fn lru(&self) -> Option<bool>
[src]Returns Some(true)
if the corresponding bit is set; Some(false)
otherwise.
It returns None
if /proc/kpageflags
could not be read for the page at hand.
pub fn active(&self) -> Option<bool>
[src]
pub fn active(&self) -> Option<bool>
[src]Returns Some(true)
if the corresponding bit is set; Some(false)
otherwise.
It returns None
if /proc/kpageflags
could not be read for the page at hand.
pub fn slab(&self) -> Option<bool>
[src]
pub fn slab(&self) -> Option<bool>
[src]Returns Some(true)
if the corresponding bit is set; Some(false)
otherwise.
It returns None
if /proc/kpageflags
could not be read for the page at hand.
pub fn writeback(&self) -> Option<bool>
[src]
pub fn writeback(&self) -> Option<bool>
[src]Returns Some(true)
if the corresponding bit is set; Some(false)
otherwise.
It returns None
if /proc/kpageflags
could not be read for the page at hand.
pub fn reclaim(&self) -> Option<bool>
[src]
pub fn reclaim(&self) -> Option<bool>
[src]Returns Some(true)
if the corresponding bit is set; Some(false)
otherwise.
It returns None
if /proc/kpageflags
could not be read for the page at hand.
pub fn buddy(&self) -> Option<bool>
[src]
pub fn buddy(&self) -> Option<bool>
[src]Returns Some(true)
if the corresponding bit is set; Some(false)
otherwise.
It returns None
if /proc/kpageflags
could not be read for the page at hand.
pub fn mmap(&self) -> Option<bool>
[src]
pub fn mmap(&self) -> Option<bool>
[src]Returns Some(true)
if the corresponding bit is set; Some(false)
otherwise.
It returns None
if /proc/kpageflags
could not be read for the page at hand.
pub fn anon(&self) -> Option<bool>
[src]
pub fn anon(&self) -> Option<bool>
[src]Returns Some(true)
if the corresponding bit is set; Some(false)
otherwise.
It returns None
if /proc/kpageflags
could not be read for the page at hand.
pub fn swapcache(&self) -> Option<bool>
[src]
pub fn swapcache(&self) -> Option<bool>
[src]Returns Some(true)
if the corresponding bit is set; Some(false)
otherwise.
It returns None
if /proc/kpageflags
could not be read for the page at hand.
pub fn swapbacked(&self) -> Option<bool>
[src]
pub fn swapbacked(&self) -> Option<bool>
[src]Returns Some(true)
if the corresponding bit is set; Some(false)
otherwise.
It returns None
if /proc/kpageflags
could not be read for the page at hand.
pub fn compound_head(&self) -> Option<bool>
[src]
pub fn compound_head(&self) -> Option<bool>
[src]Returns Some(true)
if the corresponding bit is set; Some(false)
otherwise.
It returns None
if /proc/kpageflags
could not be read for the page at hand.
pub fn compound_tail(&self) -> Option<bool>
[src]
pub fn compound_tail(&self) -> Option<bool>
[src]Returns Some(true)
if the corresponding bit is set; Some(false)
otherwise.
It returns None
if /proc/kpageflags
could not be read for the page at hand.
pub fn huge(&self) -> Option<bool>
[src]
pub fn huge(&self) -> Option<bool>
[src]Returns Some(true)
if the corresponding bit is set; Some(false)
otherwise.
It returns None
if /proc/kpageflags
could not be read for the page at hand.
pub fn unevictable(&self) -> Option<bool>
[src]
pub fn unevictable(&self) -> Option<bool>
[src]Returns Some(true)
if the corresponding bit is set; Some(false)
otherwise.
It returns None
if /proc/kpageflags
could not be read for the page at hand.
pub fn hwpoison(&self) -> Option<bool>
[src]
pub fn hwpoison(&self) -> Option<bool>
[src]Returns Some(true)
if the corresponding bit is set; Some(false)
otherwise.
It returns None
if /proc/kpageflags
could not be read for the page at hand.
pub fn nopage(&self) -> Option<bool>
[src]
pub fn nopage(&self) -> Option<bool>
[src]Returns Some(true)
if the corresponding bit is set; Some(false)
otherwise.
It returns None
if /proc/kpageflags
could not be read for the page at hand.
pub fn ksm(&self) -> Option<bool>
[src]
pub fn ksm(&self) -> Option<bool>
[src]Returns Some(true)
if the corresponding bit is set; Some(false)
otherwise.
It returns None
if /proc/kpageflags
could not be read for the page at hand.
pub fn thp(&self) -> Option<bool>
[src]
pub fn thp(&self) -> Option<bool>
[src]Returns Some(true)
if the corresponding bit is set; Some(false)
otherwise.
It returns None
if /proc/kpageflags
could not be read for the page at hand.
pub fn offline(&self) -> Option<bool>
[src]
pub fn offline(&self) -> Option<bool>
[src]Returns Some(true)
if the corresponding bit is set; Some(false)
otherwise.
It returns None
if /proc/kpageflags
could not be read for the page at hand.
pub fn zero_page(&self) -> Option<bool>
[src]
pub fn zero_page(&self) -> Option<bool>
[src]Returns Some(true)
if the corresponding bit is set; Some(false)
otherwise.
It returns None
if /proc/kpageflags
could not be read for the page at hand.
pub fn idle(&self) -> Option<bool>
[src]
pub fn idle(&self) -> Option<bool>
[src]Returns Some(true)
if the corresponding bit is set; Some(false)
otherwise.
It returns None
if /proc/kpageflags
could not be read for the page at hand.
pub fn pgtable(&self) -> Option<bool>
[src]
pub fn pgtable(&self) -> Option<bool>
[src]Returns Some(true)
if the corresponding bit is set; Some(false)
otherwise.
It returns None
if /proc/kpageflags
could not be read for the page at hand.
Trait Implementations
impl Clone for PageMapEntry
[src]
impl Clone for PageMapEntry
[src]fn clone(&self) -> PageMapEntry
[src]
fn clone(&self) -> PageMapEntry
[src]Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]Performs copy-assignment from source
. Read more
impl Debug for PageMapEntry
[src]
impl Debug for PageMapEntry
[src]impl Display for PageMapEntry
[src]
impl Display for PageMapEntry
[src]impl Copy for PageMapEntry
[src]
Auto Trait Implementations
impl RefUnwindSafe for PageMapEntry
impl Send for PageMapEntry
impl Sync for PageMapEntry
impl Unpin for PageMapEntry
impl UnwindSafe for PageMapEntry
Blanket Implementations
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]pub fn borrow_mut(&mut self) -> &mut T
[src]
pub fn borrow_mut(&mut self) -> &mut T
[src]Mutably borrows from an owned value. Read more
impl<T> ToOwned for T where
T: Clone,
[src]
impl<T> ToOwned for T where
T: Clone,
[src]type Owned = T
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn to_owned(&self) -> T
[src]Creates owned data from borrowed data, usually by cloning. Read more
pub fn clone_into(&self, target: &mut T)
[src]
pub fn clone_into(&self, target: &mut T)
[src]🔬 This is a nightly-only experimental API. (toowned_clone_into
)
recently added
Uses borrowed data to replace owned data, usually by cloning. Read more