[][src]Trait sunrise_kernel::paging::lands::VirtualSpaceLand

pub trait VirtualSpaceLand {
    const START: VirtualAddress;
    const END: VirtualAddress;
    fn start_addr() -> VirtualAddress { ... }
fn end_addr() -> VirtualAddress { ... }
fn length() -> usize { ... }
fn contains_address(address: VirtualAddress) -> bool { ... }
fn contains_region(start_address: VirtualAddress, size: usize) -> bool { ... }
fn check_contains_address(
        address: VirtualAddress
    ) -> Result<(), KernelError> { ... }
fn check_contains_region(
        address: VirtualAddress,
        length: usize
    ) -> Result<(), KernelError> { ... } }

A trait describing the splitting of virtual memory between Kernel and User. Implemented by UserLand and KernelLand

Associated Constants

const START: VirtualAddress

The first address in this land.

const END: VirtualAddress

The last address in this land.

Loading content...

Provided methods

fn start_addr() -> VirtualAddress

The first address in this land.

fn end_addr() -> VirtualAddress

The last address in this land.

fn length() -> usize

The length of this land.

fn contains_address(address: VirtualAddress) -> bool

Is the address contained in this Land ?

fn contains_region(start_address: VirtualAddress, size: usize) -> bool

Is the region fully contained in this Land ?

Panics

Panics if size is 0.

fn check_contains_address(address: VirtualAddress) -> Result<(), KernelError>

Checks that a given address falls in this land, or return an InvalidAddress otherwise

fn check_contains_region(
    address: VirtualAddress,
    length: usize
) -> Result<(), KernelError>

Checks that a given region falls in this land, or return an InvalidAddress otherwise

Loading content...

Implementors

impl VirtualSpaceLand for KernelLand[src]

impl VirtualSpaceLand for RecursiveTablesLand[src]

impl VirtualSpaceLand for UserLand[src]

Loading content...