Struct uefi::table::boot::MemoryType[][src]

#[repr(transparent)]
pub struct MemoryType(pub u32);
Expand description

The type of a memory range.

UEFI allows firmwares and operating systems to introduce new memory types in the 0x70000000..0xFFFFFFFF range. Therefore, we don’t know the full set of memory types at compile time, and it is not safe to model this C enum as a Rust enum.

Implementations

impl MemoryType[src]

pub const RESERVED: MemoryType[src]

This enum variant is not used.

pub const LOADER_CODE: MemoryType[src]

The code portions of a loaded UEFI application.

pub const LOADER_DATA: MemoryType[src]

The data portions of a loaded UEFI applications, as well as any memory allocated by it.

pub const BOOT_SERVICES_CODE: MemoryType[src]

Code of the boot drivers.

Can be reused after OS is loaded.

pub const BOOT_SERVICES_DATA: MemoryType[src]

Memory used to store boot drivers’ data.

Can be reused after OS is loaded.

pub const RUNTIME_SERVICES_CODE: MemoryType[src]

Runtime drivers’ code.

pub const RUNTIME_SERVICES_DATA: MemoryType[src]

Runtime services’ code.

pub const CONVENTIONAL: MemoryType[src]

Free usable memory.

pub const UNUSABLE: MemoryType[src]

Memory in which errors have been detected.

pub const ACPI_RECLAIM: MemoryType[src]

Memory that holds ACPI tables. Can be reclaimed after they are parsed.

pub const ACPI_NON_VOLATILE: MemoryType[src]

Firmware-reserved addresses.

pub const MMIO: MemoryType[src]

A region used for memory-mapped I/O.

pub const MMIO_PORT_SPACE: MemoryType[src]

Address space used for memory-mapped port I/O.

pub const PAL_CODE: MemoryType[src]

Address space which is part of the processor.

pub const PERSISTENT_MEMORY: MemoryType[src]

Memory region which is usable and is also non-volatile.

impl MemoryType[src]

pub const fn custom(value: u32) -> MemoryType[src]

Construct a custom MemoryType. Values in the range 0x80000000..=0xffffffff are free for use if you are an OS loader.

Trait Implementations

impl Clone for MemoryType[src]

fn clone(&self) -> MemoryType[src]

Returns a copy of the value. Read more

fn clone_from(&mut self, source: &Self)1.0.0[src]

Performs copy-assignment from source. Read more

impl Debug for MemoryType[src]

fn fmt(&self, f: &mut Formatter<'_>) -> Result[src]

Formats the value using the given formatter. Read more

impl PartialEq<MemoryType> for MemoryType[src]

fn eq(&self, other: &MemoryType) -> bool[src]

This method tests for self and other values to be equal, and is used by ==. Read more

fn ne(&self, other: &MemoryType) -> bool[src]

This method tests for !=.

impl Copy for MemoryType[src]

impl Eq for MemoryType[src]

impl StructuralEq for MemoryType[src]

impl StructuralPartialEq for MemoryType[src]

Auto Trait Implementations

impl Send for MemoryType

impl Sync for MemoryType

impl Unpin for MemoryType

Blanket Implementations

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

pub fn type_id(&self) -> TypeId[src]

Gets the TypeId of self. Read more

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

pub fn borrow(&self) -> &T[src]

Immutably borrows from an owned value. Read more

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

pub fn borrow_mut(&mut self) -> &mut T[src]

Mutably borrows from an owned value. Read more

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

pub fn from(t: T) -> T[src]

Performs the conversion.

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

pub fn into(self) -> U[src]

Performs the conversion.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]

Performs the conversion.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.

pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>[src]

Performs the conversion.