RSDT: Difference between revisions
[unchecked revision] | [unchecked revision] |
Content deleted Content added
m Bot: Replace deprecated source tag with syntaxhighlight |
|||
(10 intermediate revisions by 8 users not shown) | |||
Line 1:
{{ACPI}}
'''RSDT''' (Root System Description Table) is a data structure used in the [[ACPI]] programming interface. This table contains pointers to all the other System Description Tables.
Line 7 ⟶ 9:
==Validating the RSDT==
You only need to sum all the bytes in the table and compare the result to 0 (mod 0x100).
==Structure==
The RSDT is the main System Description Table. However there are many kinds of SDT. All the SDT may be split into two parts. One (the header) which is common to all the SDT
The structure of the header is:
<
struct ACPISDTHeader {
char Signature[4];
Line 23 ⟶ 25:
uint32_t CreatorID;
uint32_t CreatorRevision;
};
</syntaxhighlight>
=== Header fields ===
==== Signature ====
Line 32 ⟶ 34:
Total size of the table, inclusive of the header.
==== Checksum ====
A 8-bit checksum field of the whole table, inclusive of the header. All bytes of the table summed must be equal to 0 (mod
<
bool doChecksum(ACPISDTHeader *tableHeader)
{
Line 45 ⟶ 47:
return sum == 0;
}
</syntaxhighlight>
=== Other fields ===
In case you used RsdtPointer, the complete table structure is:
<
struct RSDT {
struct ACPISDTHeader h;
uint32_t PointerToOtherSDT[(h.Length - sizeof(h)) / 4];
};
</syntaxhighlight>
If you instead used the XsdtPointer, then the table is:
<
struct XSDT {
struct ACPISDTHeader h;
uint64_t PointerToOtherSDT[(h.Length - sizeof(h)) / 8];
};
</syntaxhighlight>
== How to use ==
Well, suppose you want to find the [[FADT]]. The FADT, being a SDT has a ACPISDTHeader. It's signature is "FACP".
You may use this code:
<
void *findFACP(void *RootSDT)
{
Line 82 ⟶ 84:
return NULL;
}
</syntaxhighlight>
== What can you find? ==
Line 98 ⟶ 100:
* "ERST": Error Record Serialization Table ([[ERST]])
* "FACP": Fixed ACPI Description Table ([[FADT]])
* "FACS": Firmware
* "HEST": Hardware Error Source Table ([[HEST]])
* "MSCT": Maximum System Characteristics Table ([[MSCT]])
Line 105 ⟶ 107:
* "PMTT" Platform Memory Topology Table ([[PMTT]])
* "PSDT": Persistent System Description Table ([[PSDT]])
* "RASF": ACPI RAS
* "RSDT": Root System Description Table (This wiki page; included for completeness)
* "SBST": Smart Battery Specification Table ([[SBST]])
Line 118 ⟶ 120:
== What's next? ==
You should now parse each table pointed by the
[[Category:ACPI]]
|