Kernel: Add more structures to ACPI
This commit is contained in:
parent
3a59a64355
commit
2c59c9a3cc
|
@ -9,6 +9,15 @@ namespace Kernel
|
||||||
class ACPI
|
class ACPI
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
|
struct GAS
|
||||||
|
{
|
||||||
|
uint8_t address_space_id;
|
||||||
|
uint8_t register_bit_width;
|
||||||
|
uint8_t register_bit_offset;
|
||||||
|
uint8_t access_size;
|
||||||
|
uint64_t address;
|
||||||
|
} __attribute__((packed));
|
||||||
|
|
||||||
struct SDTHeader
|
struct SDTHeader
|
||||||
{
|
{
|
||||||
uint8_t signature[4];
|
uint8_t signature[4];
|
||||||
|
@ -81,6 +90,20 @@ namespace Kernel
|
||||||
uint64_t hypervison_vendor_identity;
|
uint64_t hypervison_vendor_identity;
|
||||||
} __attribute__((packed));
|
} __attribute__((packed));
|
||||||
|
|
||||||
|
struct HPET : public SDTHeader
|
||||||
|
{
|
||||||
|
uint8_t hardware_rev_id;
|
||||||
|
uint8_t comparator_count : 5;
|
||||||
|
uint8_t count_size_cap : 1;
|
||||||
|
uint8_t reserved : 1;
|
||||||
|
uint8_t legacy_replacement_irq_routing_cable : 1;
|
||||||
|
uint16_t pci_vendor_id;
|
||||||
|
GAS base_address;
|
||||||
|
uint8_t hpet_number;
|
||||||
|
uint16_t main_counter_minimum_clock_tick;
|
||||||
|
uint8_t page_protection_and_oem_attribute;
|
||||||
|
} __attribute__((packed));
|
||||||
|
|
||||||
public:
|
public:
|
||||||
static BAN::ErrorOr<void> initialize();
|
static BAN::ErrorOr<void> initialize();
|
||||||
static ACPI& get();
|
static ACPI& get();
|
||||||
|
|
Loading…
Reference in New Issue