#[repr(C)]
pub struct StivaleSmpInfo { pub acpi_processor_uid: u32, pub lapic_id: u32, pub target_stack: u64, pub goto_address: u64, pub extra: u64, }
Expand description

SMP imformation structure.

Fields

acpi_processor_uid: u32

ACPI Processor UID as specified by MADT.

lapic_id: u32

LAPIC ID as specified by MADT.

target_stack: u64

The stack that will be loaded in ESP/RSP once the goto_address field is loaded. This MUST point to a valid stack of at least 256 bytes in size, and 16-byte aligned. target_stack is an unused field for the struct describing the BSP.

goto_address: u64

This field is polled by the started APs until the kernel on another CPU performs an atomic write to this field. When that happens, bootloader code will load up ESP/RSP with the stack value as specified in target_stack. It will then proceed to load a pointer to this very structure into either register RDI for 64-bit or on the stack for 32-bit, then, goto_address is called (a bogus return address is pushed onto the stack) and execution is handed off. The CPU state will be the same as describedin “kernel entry machine state”, with the exception of ESP/RSP and RDI/stack arg being set up as above. goto_address is an unused field for the struct describing the BSP.

extra: u64

This field is polled by the started APs until the kernel on another CPU performs an atomic write to this field. When that happens, bootloader code will load up ESP/RSP with the stack value as specified in target_stack. It will then proceed to load a pointer to this very structure into either register RDI for 64-bit or on the stack for 32-bit, then, goto_address is called (a bogus return address is pushed onto the stack) and execution is handed off.

The CPU state will be the same as described in “kernel entry machine state”, with the exception of ESP/RSP and RDI/stack arg being set up as above. goto_address is an unused field for the struct describing the BSP.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.