pub struct AcpiTables<H: Handler> {
pub rsdp_revision: u8,
/* private fields */
}
Expand description
AcpiTables
should be constructed after finding the RSDP or RSDT/XSDT and allows enumeration
of the system’s ACPI tables.
Fields§
§rsdp_revision: u8
Implementations§
Source§impl<H> AcpiTables<H>where
H: Handler,
impl<H> AcpiTables<H>where
H: Handler,
Sourcepub unsafe fn from_rsdp(
handler: H,
rsdp_address: usize,
) -> Result<AcpiTables<H>, AcpiError>
pub unsafe fn from_rsdp( handler: H, rsdp_address: usize, ) -> Result<AcpiTables<H>, AcpiError>
Construct an AcpiTables
from the physical address of the RSDP.
§Safety
The address of the RSDP must be valid.
Sourcepub unsafe fn from_rsdt(
handler: H,
rsdp_revision: u8,
rsdt_address: usize,
) -> Result<AcpiTables<H>, AcpiError>
pub unsafe fn from_rsdt( handler: H, rsdp_revision: u8, rsdt_address: usize, ) -> Result<AcpiTables<H>, AcpiError>
Construct an AcpiTables
from the physical address of the RSDT/XSDT, and the revision
found in the RSDP.
§Safety
The address of the RSDT must be valid.
Sourcepub fn table_entries(&self) -> impl Iterator<Item = usize>
pub fn table_entries(&self) -> impl Iterator<Item = usize>
Iterate over the physical addresses of the SDTs.
Sourcepub fn table_headers(&self) -> impl Iterator<Item = (usize, SdtHeader)>
pub fn table_headers(&self) -> impl Iterator<Item = (usize, SdtHeader)>
Iterate over the headers of each SDT, along with their physical addresses.
Sourcepub fn find_tables<T>(&self) -> impl Iterator<Item = PhysicalMapping<H, T>>where
T: AcpiTable,
pub fn find_tables<T>(&self) -> impl Iterator<Item = PhysicalMapping<H, T>>where
T: AcpiTable,
Find all tables with the signature T::SIGNATURE
.
Sourcepub fn find_table<T>(&self) -> Option<PhysicalMapping<H, T>>where
T: AcpiTable,
pub fn find_table<T>(&self) -> Option<PhysicalMapping<H, T>>where
T: AcpiTable,
Find the first table with the signature T::SIGNATURE
.
pub fn dsdt(&self) -> Result<AmlTable, AcpiError>
pub fn ssdts(&self) -> impl Iterator<Item = AmlTable>
Trait Implementations§
impl<H> Send for AcpiTables<H>
impl<H> Sync for AcpiTables<H>
Auto Trait Implementations§
impl<H> Freeze for AcpiTables<H>where
H: Freeze,
impl<H> RefUnwindSafe for AcpiTables<H>where
H: RefUnwindSafe,
impl<H> Unpin for AcpiTables<H>where
H: Unpin,
impl<H> UnwindSafe for AcpiTables<H>where
H: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more