From a7967eea163a59926a72554ee77e4d19b1510b2c Mon Sep 17 00:00:00 2001 From: Elyes HAOUAS Date: Sat, 2 Mar 2019 11:11:36 +0100 Subject: [PATCH] arch/x86/acpi: Clean up comments As we are running ACPI v3.0, references to older than v3.0 are removed. Change-Id: I0cce0035ed2b952d59cc1a4a9e6017dae67ef6db Signed-off-by: Elyes HAOUAS Reviewed-on: https://review.coreboot.org/c/31689 Tested-by: build bot (Jenkins) Reviewed-by: Nico Huber --- src/arch/x86/include/arch/acpi.h | 32 ++++++++++++-------------------- 1 file changed, 12 insertions(+), 20 deletions(-) diff --git a/src/arch/x86/include/arch/acpi.h b/src/arch/x86/include/arch/acpi.h index aced58aa62..b3a5ce796a 100644 --- a/src/arch/x86/include/arch/acpi.h +++ b/src/arch/x86/include/arch/acpi.h @@ -90,14 +90,13 @@ typedef struct acpi_rsdp { char signature[8]; /* RSDP signature */ u8 checksum; /* Checksum of the first 20 bytes */ char oem_id[6]; /* OEM ID */ - u8 revision; /* 0 for ACPI 1.0, 2 for ACPI 2.0/3.0/4.0/6.2a */ + u8 revision; /* RSDP revision */ u32 rsdt_address; /* Physical address of RSDT (32 bits) */ u32 length; /* Total RSDP length (incl. extended part) */ u64 xsdt_address; /* Physical address of XSDT (64 bits) */ u8 ext_checksum; /* Checksum of the whole table */ u8 reserved[3]; } __packed acpi_rsdp_t; -/* Note: ACPI 1.0 didn't have length, xsdt_address, and ext_checksum. */ /* GAS (Generic Address Structure) */ typedef struct acpi_gen_regaddr { @@ -106,9 +105,7 @@ typedef struct acpi_gen_regaddr { u8 bit_offset; /* Register bit offset */ union { u8 resv; /* Reserved in ACPI 2.0 - 2.0b */ - u8 access_size; /* Access size in - * ACPI 2.0c/3.0/4.0/5.0/6.2a - */ + u8 access_size; /* Access size since ACPI 2.0c */ }; u32 addrl; /* Register address, low 32 bits */ u32 addrh; /* Register address, high 32 bits */ @@ -484,11 +481,7 @@ typedef struct acpi_fadt { struct acpi_table_header header; u32 firmware_ctrl; u32 dsdt; - u8 reserved; /* Eliminated in ACPI 2.0. Platforms should set - * this field to zero but field values of one - * are also allowed to maintain compatibility - * with ACPI 1.0. - */ + u8 reserved; /* Should be 0 */ u8 preferred_pm_profile; u16 sci_int; u32 smi_cmd; @@ -578,7 +571,7 @@ typedef struct acpi_fadt { /* Bits 20-31: reserved ACPI 3.0 & 4.0 */ #define ACPI_FADT_HW_REDUCED_ACPI (1 << 20) #define ACPI_FADT_LOW_PWR_IDLE_S0 (1 << 21) -/* bits 22-31: reserved ACPI 5.0/6.2a */ +/* bits 22-31: reserved since ACPI 5.0 */ /* FADT Boot Architecture Flags */ #define ACPI_FADT_LEGACY_DEVICES (1 << 0) @@ -592,7 +585,7 @@ typedef struct acpi_fadt { /* FADT ARM Boot Architecture Flags */ #define ACPI_FADT_ARM_PSCI_COMPLIANT (1 << 0) #define ACPI_FADT_ARM_PSCI_USE_HVC (1 << 1) -/* bits 2-16: reserved ACPI 6.2a */ +/* bits 2-16: reserved since ACPI 5.1 */ /* FADT Preferred Power Management Profile */ enum acpi_preferred_pm_profiles { @@ -604,7 +597,7 @@ enum acpi_preferred_pm_profiles { PM_SOHO_SERVER = 5, PM_APPLIANCE_PC = 6, PM_PERFORMANCE_SERVER = 7, - PM_TABLET = 8, /* ACPI 5.0/6.2a */ + PM_TABLET = 8, /* ACPI 5.0 & greater */ }; /* FACS (Firmware ACPI Control Structure) */ @@ -617,10 +610,10 @@ typedef struct acpi_facs { u32 flags; /* FACS flags */ u32 x_firmware_waking_vector_l; /* X FW waking vector, low */ u32 x_firmware_waking_vector_h; /* X FW waking vector, high */ - u8 version; /* ACPI 6.2-A: 2 */ - u8 resv1[3]; /* ACPI 6.2-A: 0 */ + u8 version; /* FACS version */ + u8 resv1[3]; /* This value is 0 */ u32 ospm_flags; /* 64BIT_WAKE_F */ - u8 resv2[24]; /* ACPI 6.2-A: 0 */ + u8 resv2[24]; /* This value is 0 */ } __packed acpi_facs_t; /* FACS flags */ @@ -678,7 +671,7 @@ typedef struct acpi_bert { u64 error_region; } __packed acpi_bert_t; -/* Generic Error Data Entry (ACPI spec v6.2-A, table 382) */ +/* Generic Error Data Entry */ typedef struct acpi_hest_generic_data { guid_t section_type; u32 error_severity; @@ -691,7 +684,7 @@ typedef struct acpi_hest_generic_data { /* error data */ } __packed acpi_hest_generic_data_t; -/* Generic Error Data Entry (ACPI spec v6.2-A, table 382) */ +/* Generic Error Data Entry v300 */ typedef struct acpi_hest_generic_data_v300 { guid_t section_type; u32 error_severity; @@ -717,7 +710,7 @@ typedef struct acpi_hest_generic_data_v300 { #define ACPI_GENERROR_VALID_FRUID_TEXT BIT(1) #define ACPI_GENERROR_VALID_TIMESTAMP BIT(2) -/* Generic Error Status Block (ACPI spec v6.2-A, table 381) */ +/* Generic Error Status Block */ typedef struct acpi_generic_error_status { u32 block_status; u32 raw_data_offset; /* must follow any generic entries */ @@ -755,7 +748,6 @@ typedef struct acpi_tstate { /* Port types for ACPI _UPC object */ enum acpi_upc_type { - /* These types are defined in ACPI 6.2 section 9.14 */ UPC_TYPE_A, UPC_TYPE_MINI_AB, UPC_TYPE_EXPRESSCARD,