Struct rsdp::Rsdp[][src]

#[repr(C, packed)]
pub struct Rsdp { /* fields omitted */ }
Expand description

The first structure found in ACPI. It just tells us where the RSDT is.

On BIOS systems, it is either found in the first 1KB of the Extended Bios Data Area, or between 0x000E0000 and 0x000FFFFF. The signature is always on a 16 byte boundary. On (U)EFI, it may not be located in these locations, and so an address should be found in the EFI configuration table instead.

The recommended way of locating the RSDP is to let the bootloader do it - Multiboot2 can pass a tag with the physical address of it. If this is not possible, a manual scan can be done.

If revision > 0, (the hardware ACPI version is Version 2.0 or greater), the RSDP contains some new fields. For ACPI Version 1.0, these fields are not valid and should not be accessed. For ACPI Version 2.0+, xsdt_address should be used (truncated to u32 on x86) instead of rsdt_address.

Implementations

This searches for a RSDP on BIOS systems.

Safety

This function probes memory in three locations:

  • It reads a word from 40:0e to locate the EBDA.
  • The first 1KiB of the EBDA (Extended BIOS Data Area).
  • The BIOS memory area at 0xe0000..=0xfffff.

This should be fine on all BIOS systems. However, UEFI platforms are free to put the RSDP wherever they please, so this won’t always find the RSDP. Further, prodding these memory locations may have unintended side-effects. On UEFI systems, the RSDP should be found in the Configuration Table, using two GUIDs: - ACPI v1.0 structures use eb9d2d30-2d88-11d3-9a16-0090273fc14d. - ACPI v2.0 or later structures use 8868e871-e4f1-11d3-bc22-0080c73c8881. You should search the entire table for the v2.0 GUID before searching for the v1.0 one.

Checks that: 1) The signature is correct 2) The checksum is correct 3) For Version 2.0+, that the extension checksum is correct

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

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

Performs the conversion.

Performs the conversion.

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.