pub trait BootInformation: 'static {
    type MemoryRegion<'a>: MemoryRegion;
    type MemoryRegions<'a>: Iterator<Item = Self::MemoryRegion<'a>>;
    type ElfSection<'a>: ElfSection;
    type ElfSections<'a>: Iterator<Item = Self::ElfSection<'a>>;
    type Module<'a>: Module;
    type Modules<'a>: Iterator<Item = Self::Module<'a>>;
    type AdditionalReservedMemoryRegions: Iterator<Item = ReservedMemoryRegion>;

    // Required methods
    fn start(&self) -> Option<VirtualAddress>;
    fn len(&self) -> usize;
    fn memory_regions(&self) -> Result<Self::MemoryRegions<'_>, &'static str>;
    fn elf_sections(&self) -> Result<Self::ElfSections<'_>, &'static str>;
    fn modules(&self) -> Self::Modules<'_>;
    fn additional_reserved_memory_regions(
        &self
    ) -> Result<Self::AdditionalReservedMemoryRegions, &'static str>;
    fn kernel_end(&self) -> Result<VirtualAddress, &'static str>;
    fn rsdp(&self) -> Option<PhysicalAddress>;
    fn stack_size(&self) -> Result<usize, &'static str>;
    fn framebuffer_info(&self) -> Option<FramebufferInfo>;

    // Provided method
    fn is_empty(&self) -> bool { ... }
}

Required Associated Types§

type MemoryRegion<'a>: MemoryRegion

type MemoryRegions<'a>: Iterator<Item = Self::MemoryRegion<'a>>

type ElfSection<'a>: ElfSection

type ElfSections<'a>: Iterator<Item = Self::ElfSection<'a>>

type Module<'a>: Module

type Modules<'a>: Iterator<Item = Self::Module<'a>>

type AdditionalReservedMemoryRegions: Iterator<Item = ReservedMemoryRegion>

Required Methods§

fn start(&self) -> Option<VirtualAddress>

Returns the boot information’s starting virtual address.

fn len(&self) -> usize

Returns the boot information’s length.

fn memory_regions(&self) -> Result<Self::MemoryRegions<'_>, &'static str>

Returns memory regions describing the physical memory.

fn elf_sections(&self) -> Result<Self::ElfSections<'_>, &'static str>

Returns the kernel’s ELF sections.

fn modules(&self) -> Self::Modules<'_>

Returns the modules found in the kernel image.

fn additional_reserved_memory_regions( &self ) -> Result<Self::AdditionalReservedMemoryRegions, &'static str>

Returns additional reserved memory regions that aren’t included in the list of regions returned by [memory_regions].

fn kernel_end(&self) -> Result<VirtualAddress, &'static str>

Returns the end of the kernel’s image in memory.

fn rsdp(&self) -> Option<PhysicalAddress>

Returns the RSDP if it was provided by the bootloader.

fn stack_size(&self) -> Result<usize, &'static str>

Returns the stack size in bytes.

fn framebuffer_info(&self) -> Option<FramebufferInfo>

Returns information about the graphical framebuffer, if available.

Provided Methods§

fn is_empty(&self) -> bool

Returns whether the boot information is empty.

Implementations on Foreign Types§

§

impl BootInformation for BootInformation

§

type MemoryRegion<'a> = &'a MemoryArea

§

type MemoryRegions<'a> = MemoryRegions<'a>

§

type ElfSection<'a> = ElfSection

§

type ElfSections<'a> = ElfSectionIter

§

type Module<'a> = &'a ModuleTag

§

type Modules<'a> = ModuleIter<'a>

§

type AdditionalReservedMemoryRegions = IntoIter<ReservedMemoryRegion, 3>

§

fn start(&self) -> Option<VirtualAddress>

§

fn len(&self) -> usize

§

fn memory_regions( &self ) -> Result<<BootInformation as BootInformation>::MemoryRegions<'_>, &'static str>

§

fn elf_sections( &self ) -> Result<<BootInformation as BootInformation>::ElfSections<'static>, &'static str>

§

fn modules(&self) -> <BootInformation as BootInformation>::Modules<'_>

§

fn additional_reserved_memory_regions( &self ) -> Result<<BootInformation as BootInformation>::AdditionalReservedMemoryRegions, &'static str>

§

fn kernel_end(&self) -> Result<VirtualAddress, &'static str>

§

fn rsdp(&self) -> Option<PhysicalAddress>

§

fn stack_size(&self) -> Result<usize, &'static str>

§

fn framebuffer_info(&self) -> Option<FramebufferInfo>

Implementors§