[][src]Struct kernel::mpu::Region

pub struct Region {
    start_address: *const u8,
    size: usize,

MPU region.

This is one contiguous address space protected by the MPU.


start_address: *const u8

The memory address where the region starts.

For maximum compatibility, we use a u8 pointer, however, note that many memory protection units have very strict alignment requirements for the memory regions protected by the MPU.

size: usize

The number of bytes of memory in the MPU region.


impl Region[src]

pub fn new(start_address: *const u8, size: usize) -> Region[src]

Create a new MPU region with a given starting point and length in bytes.

pub fn start_address(&self) -> *const u8[src]

Getter: retrieve the address of the start of the MPU region.

pub fn size(&self) -> usize[src]

Getter: retrieve the length of the region in bytes.

Trait Implementations

impl Copy for Region[src]

impl Clone for Region[src]

Auto Trait Implementations

impl Unpin for Region

impl !Send for Region

impl !Sync for Region

Blanket Implementations

impl<T> From<T> for T[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> Into<U> for T where
    U: From<T>, 

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> Borrow<T> for T where
    T: ?Sized

impl<T> BorrowMut<T> for T where
    T: ?Sized

impl<T> Any for T where
    T: 'static + ?Sized