* [edk2-platforms][PATCH v2 1/1] MinPlatformPkg/AcpiTables: Update structures for ACPI 6.3
@ 2021-09-24 18:22 Michael Kubacki
2021-10-02 1:13 ` Nate DeSimone
2021-10-02 1:14 ` Nate DeSimone
0 siblings, 2 replies; 3+ messages in thread
From: Michael Kubacki @ 2021-09-24 18:22 UTC (permalink / raw)
To: devel
Cc: Chasel Chiu, Nate DeSimone, Liming Gao, Eric Dong, Daniel Maddy,
Michael Kubacki
From: Daniel Maddy <danmad@microsoft.com>
REF:https://bugzilla.tianocore.org/show_bug.cgi?id=3535
Updates ACPI table structures in MinPlatformPkg for ACPI 6.3.
Cc: Chasel Chiu <chasel.chiu@intel.com>
Cc: Nate DeSimone <nathaniel.l.desimone@intel.com>
Cc: Liming Gao <gaoliming@byosoft.com.cn>
Cc: Eric Dong <eric.dong@intel.com>
Cc: Daniel Maddy <danmad@microsoft.com>
Co-authored-by: Michael Kubacki <michael.kubacki@microsoft.com>
Signed-off-by: Michael Kubacki <michael.kubacki@microsoft.com>
Reviewed-by: Nate DeSimone <nathaniel.l.desimone@intel.com>
---
Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/AcpiPlatform.c | 181 ++++++++++----------
Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/Facs/Facs.c | 11 +-
Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/Fadt/Fadt.c | 74 ++++----
3 files changed, 138 insertions(+), 128 deletions(-)
diff --git a/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/AcpiPlatform.c b/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/AcpiPlatform.c
index 843ba832ce67..f5c4f2c3f1a9 100644
--- a/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/AcpiPlatform.c
+++ b/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/AcpiPlatform.c
@@ -2,6 +2,7 @@
ACPI Platform Driver
Copyright (c) 2017 - 2021, Intel Corporation. All rights reserved.<BR>
+Copyright (c) Microsoft Corporation.<BR>
SPDX-License-Identifier: BSD-2-Clause-Patent
**/
@@ -11,7 +12,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent
#pragma pack(1)
typedef struct {
- UINT32 AcpiProcessorId;
+ UINT32 AcpiProcessorUid;
UINT32 ApicId;
UINT32 Flags;
UINT32 SocketNum;
@@ -25,9 +26,9 @@ typedef struct {
// Define Union of IO APIC & Local APIC structure;
//
typedef union {
- EFI_ACPI_4_0_PROCESSOR_LOCAL_APIC_STRUCTURE AcpiLocalApic;
- EFI_ACPI_4_0_IO_APIC_STRUCTURE AcpiIoApic;
- EFI_ACPI_4_0_PROCESSOR_LOCAL_X2APIC_STRUCTURE AcpiLocalx2Apic;
+ EFI_ACPI_6_3_PROCESSOR_LOCAL_APIC_STRUCTURE AcpiLocalApic;
+ EFI_ACPI_6_3_IO_APIC_STRUCTURE AcpiIoApic;
+ EFI_ACPI_6_3_PROCESSOR_LOCAL_X2APIC_STRUCTURE AcpiLocalx2Apic;
struct {
UINT8 Type;
UINT8 Length;
@@ -36,9 +37,9 @@ typedef union {
#pragma pack()
-extern EFI_ACPI_5_0_FIRMWARE_ACPI_CONTROL_STRUCTURE Facs;
-extern EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE Fadt;
-extern EFI_ACPI_HIGH_PRECISION_EVENT_TIMER_TABLE_HEADER Hpet;
+extern EFI_ACPI_6_3_FIRMWARE_ACPI_CONTROL_STRUCTURE Facs;
+extern EFI_ACPI_6_3_FIXED_ACPI_DESCRIPTION_TABLE Fadt;
+extern EFI_ACPI_HIGH_PRECISION_EVENT_TIMER_TABLE_HEADER Hpet;
extern EFI_ACPI_WSMT_TABLE Wsmt;
VOID *mLocalTable[] = {
@@ -103,7 +104,7 @@ DebugDisplayReOrderTable (
for (Index = 0; Index < mNumberOfCpus; Index++) {
DEBUG ((DEBUG_INFO, " %02d 0x%02X 0x%02X %d %d %d\n",
Index,
- CpuApicIdOrderTable[Index].AcpiProcessorId,
+ CpuApicIdOrderTable[Index].AcpiProcessorUid,
CpuApicIdOrderTable[Index].ApicId,
CpuApicIdOrderTable[Index].Thread,
CpuApicIdOrderTable[Index].Flags,
@@ -118,31 +119,31 @@ AppendCpuMapTableEntry (
)
{
EFI_STATUS Status;
- EFI_ACPI_4_0_PROCESSOR_LOCAL_APIC_STRUCTURE *LocalApicPtr;
- EFI_ACPI_4_0_PROCESSOR_LOCAL_X2APIC_STRUCTURE *LocalX2ApicPtr;
+ EFI_ACPI_6_3_PROCESSOR_LOCAL_APIC_STRUCTURE *LocalApicPtr;
+ EFI_ACPI_6_3_PROCESSOR_LOCAL_X2APIC_STRUCTURE *LocalX2ApicPtr;
UINT8 Type;
Status = EFI_SUCCESS;
Type = ((ACPI_APIC_STRUCTURE_PTR *)ApicPtr)->AcpiApicCommon.Type;
- LocalApicPtr = (EFI_ACPI_4_0_PROCESSOR_LOCAL_APIC_STRUCTURE *)(&((ACPI_APIC_STRUCTURE_PTR *)ApicPtr)->AcpiLocalApic);
- LocalX2ApicPtr = (EFI_ACPI_4_0_PROCESSOR_LOCAL_X2APIC_STRUCTURE *)(&((ACPI_APIC_STRUCTURE_PTR *)ApicPtr)->AcpiLocalx2Apic);
+ LocalApicPtr = (EFI_ACPI_6_3_PROCESSOR_LOCAL_APIC_STRUCTURE *)(&((ACPI_APIC_STRUCTURE_PTR *)ApicPtr)->AcpiLocalApic);
+ LocalX2ApicPtr = (EFI_ACPI_6_3_PROCESSOR_LOCAL_X2APIC_STRUCTURE *)(&((ACPI_APIC_STRUCTURE_PTR *)ApicPtr)->AcpiLocalx2Apic);
- if(Type == EFI_ACPI_4_0_PROCESSOR_LOCAL_APIC) {
+ if(Type == EFI_ACPI_6_3_PROCESSOR_LOCAL_APIC) {
if(!mX2ApicEnabled) {
- LocalApicPtr->Flags = (UINT8)mCpuApicIdOrderTable[LocalApicCounter].Flags;
- LocalApicPtr->ApicId = (UINT8)mCpuApicIdOrderTable[LocalApicCounter].ApicId;
- LocalApicPtr->AcpiProcessorId = (UINT8)mCpuApicIdOrderTable[LocalApicCounter].AcpiProcessorId;
+ LocalApicPtr->Flags = (UINT8)mCpuApicIdOrderTable[LocalApicCounter].Flags;
+ LocalApicPtr->ApicId = (UINT8)mCpuApicIdOrderTable[LocalApicCounter].ApicId;
+ LocalApicPtr->AcpiProcessorUid = (UINT8)mCpuApicIdOrderTable[LocalApicCounter].AcpiProcessorUid;
} else {
- LocalApicPtr->Flags = 0;
- LocalApicPtr->ApicId = 0xFF;
- LocalApicPtr->AcpiProcessorId = (UINT8)0xFF;
+ LocalApicPtr->Flags = 0;
+ LocalApicPtr->ApicId = 0xFF;
+ LocalApicPtr->AcpiProcessorUid = (UINT8)0xFF;
Status = EFI_UNSUPPORTED;
}
- } else if(Type == EFI_ACPI_4_0_PROCESSOR_LOCAL_X2APIC) {
+ } else if(Type == EFI_ACPI_6_3_PROCESSOR_LOCAL_X2APIC) {
if(mX2ApicEnabled) {
LocalX2ApicPtr->Flags = (UINT8)mCpuApicIdOrderTable[LocalApicCounter].Flags;
LocalX2ApicPtr->X2ApicId = mCpuApicIdOrderTable[LocalApicCounter].ApicId;
- LocalX2ApicPtr->AcpiProcessorUid = mCpuApicIdOrderTable[LocalApicCounter].AcpiProcessorId;
+ LocalX2ApicPtr->AcpiProcessorUid = mCpuApicIdOrderTable[LocalApicCounter].AcpiProcessorUid;
} else {
LocalX2ApicPtr->Flags = 0;
LocalX2ApicPtr->X2ApicId = (UINT32)-1;
@@ -201,15 +202,15 @@ SortCpuLocalApicInTable (
//update processorbitMask
if (CpuIdMapPtr->Flags == 1) {
if (mForceX2ApicId) {
- CpuIdMapPtr->SocketNum &= 0x7;
- CpuIdMapPtr->AcpiProcessorId &= 0xFF; //keep lower 8bit due to use Proc obj in dsdt
+ CpuIdMapPtr->SocketNum &= 0x7;
+ CpuIdMapPtr->AcpiProcessorUid &= 0xFF; //keep lower 8bit due to use Proc obj in dsdt
}
}
} else { //not enabled
- CpuIdMapPtr->ApicId = (UINT32)-1;
- CpuIdMapPtr->Thread = (UINT32)-1;
- CpuIdMapPtr->Flags = 0;
- CpuIdMapPtr->SocketNum = (UINT32)-1;
+ CpuIdMapPtr->ApicId = (UINT32)-1;
+ CpuIdMapPtr->Thread = (UINT32)-1;
+ CpuIdMapPtr->Flags = 0;
+ CpuIdMapPtr->SocketNum = (UINT32)-1;
} //end if PROC ENABLE
} //end for CurrentProcessor
@@ -280,12 +281,12 @@ SortCpuLocalApicInTable (
}
//
- // 5. Re-assigen AcpiProcessorId for AcpiProcessorUId uses purpose.
+ // 5. Re-assign AcpiProcessorId for AcpiProcessorUid uses purpose.
//
for (Socket = 0; Socket < FixedPcdGet32 (PcdMaxCpuSocketCount); Socket++) {
for (CurrProcessor = 0, Index = 0; CurrProcessor < mNumberOfCpus; CurrProcessor++) {
if (mCpuApicIdOrderTable[CurrProcessor].Flags && (mCpuApicIdOrderTable[CurrProcessor].SocketNum == Socket)) {
- mCpuApicIdOrderTable[CurrProcessor].AcpiProcessorId = (ProcessorInfoBuffer.Location.Package << mNumOfBitShift) + Index;
+ mCpuApicIdOrderTable[CurrProcessor].AcpiProcessorUid = (ProcessorInfoBuffer.Location.Package << mNumOfBitShift) + Index;
Index++;
}
}
@@ -312,17 +313,17 @@ typedef struct {
} STRUCTURE_HEADER;
STRUCTURE_HEADER mMadtStructureTable[] = {
- {EFI_ACPI_4_0_PROCESSOR_LOCAL_APIC, sizeof (EFI_ACPI_4_0_PROCESSOR_LOCAL_APIC_STRUCTURE)},
- {EFI_ACPI_4_0_IO_APIC, sizeof (EFI_ACPI_4_0_IO_APIC_STRUCTURE)},
- {EFI_ACPI_4_0_INTERRUPT_SOURCE_OVERRIDE, sizeof (EFI_ACPI_4_0_INTERRUPT_SOURCE_OVERRIDE_STRUCTURE)},
- {EFI_ACPI_4_0_NON_MASKABLE_INTERRUPT_SOURCE, sizeof (EFI_ACPI_4_0_NON_MASKABLE_INTERRUPT_SOURCE_STRUCTURE)},
- {EFI_ACPI_4_0_LOCAL_APIC_NMI, sizeof (EFI_ACPI_4_0_LOCAL_APIC_NMI_STRUCTURE)},
- {EFI_ACPI_4_0_LOCAL_APIC_ADDRESS_OVERRIDE, sizeof (EFI_ACPI_4_0_LOCAL_APIC_ADDRESS_OVERRIDE_STRUCTURE)},
- {EFI_ACPI_4_0_IO_SAPIC, sizeof (EFI_ACPI_4_0_IO_SAPIC_STRUCTURE)},
- {EFI_ACPI_4_0_LOCAL_SAPIC, sizeof (EFI_ACPI_4_0_PROCESSOR_LOCAL_SAPIC_STRUCTURE)},
- {EFI_ACPI_4_0_PLATFORM_INTERRUPT_SOURCES, sizeof (EFI_ACPI_4_0_PLATFORM_INTERRUPT_SOURCES_STRUCTURE)},
- {EFI_ACPI_4_0_PROCESSOR_LOCAL_X2APIC, sizeof (EFI_ACPI_4_0_PROCESSOR_LOCAL_X2APIC_STRUCTURE)},
- {EFI_ACPI_4_0_LOCAL_X2APIC_NMI, sizeof (EFI_ACPI_4_0_LOCAL_X2APIC_NMI_STRUCTURE)}
+ {EFI_ACPI_6_3_PROCESSOR_LOCAL_APIC, sizeof (EFI_ACPI_6_3_PROCESSOR_LOCAL_APIC_STRUCTURE)},
+ {EFI_ACPI_6_3_IO_APIC, sizeof (EFI_ACPI_6_3_IO_APIC_STRUCTURE)},
+ {EFI_ACPI_6_3_INTERRUPT_SOURCE_OVERRIDE, sizeof (EFI_ACPI_6_3_INTERRUPT_SOURCE_OVERRIDE_STRUCTURE)},
+ {EFI_ACPI_6_3_NON_MASKABLE_INTERRUPT_SOURCE, sizeof (EFI_ACPI_6_3_NON_MASKABLE_INTERRUPT_SOURCE_STRUCTURE)},
+ {EFI_ACPI_6_3_LOCAL_APIC_NMI, sizeof (EFI_ACPI_6_3_LOCAL_APIC_NMI_STRUCTURE)},
+ {EFI_ACPI_6_3_LOCAL_APIC_ADDRESS_OVERRIDE, sizeof (EFI_ACPI_6_3_LOCAL_APIC_ADDRESS_OVERRIDE_STRUCTURE)},
+ {EFI_ACPI_6_3_IO_SAPIC, sizeof (EFI_ACPI_6_3_IO_SAPIC_STRUCTURE)},
+ {EFI_ACPI_6_3_LOCAL_SAPIC, sizeof (EFI_ACPI_6_3_PROCESSOR_LOCAL_SAPIC_STRUCTURE)},
+ {EFI_ACPI_6_3_PLATFORM_INTERRUPT_SOURCES, sizeof (EFI_ACPI_6_3_PLATFORM_INTERRUPT_SOURCES_STRUCTURE)},
+ {EFI_ACPI_6_3_PROCESSOR_LOCAL_X2APIC, sizeof (EFI_ACPI_6_3_PROCESSOR_LOCAL_X2APIC_STRUCTURE)},
+ {EFI_ACPI_6_3_LOCAL_X2APIC_NMI, sizeof (EFI_ACPI_6_3_LOCAL_X2APIC_NMI_STRUCTURE)}
};
/**
@@ -481,7 +482,7 @@ InitializeHeader (
**/
EFI_STATUS
InitializeMadtHeader (
- IN OUT EFI_ACPI_4_0_MULTIPLE_APIC_DESCRIPTION_TABLE_HEADER *MadtHeader
+ IN OUT EFI_ACPI_6_3_MULTIPLE_APIC_DESCRIPTION_TABLE_HEADER *MadtHeader
)
{
EFI_STATUS Status;
@@ -493,8 +494,8 @@ InitializeMadtHeader (
Status = InitializeHeader (
&MadtHeader->Header,
- EFI_ACPI_4_0_MULTIPLE_APIC_DESCRIPTION_TABLE_SIGNATURE,
- EFI_ACPI_4_0_MULTIPLE_APIC_DESCRIPTION_TABLE_REVISION,
+ EFI_ACPI_6_3_MULTIPLE_APIC_DESCRIPTION_TABLE_SIGNATURE,
+ EFI_ACPI_6_3_MULTIPLE_APIC_DESCRIPTION_TABLE_REVISION,
0
);
if (EFI_ERROR (Status)) {
@@ -502,7 +503,7 @@ InitializeMadtHeader (
}
MadtHeader->LocalApicAddress = PcdGet32(PcdLocalApicAddress);
- MadtHeader->Flags = EFI_ACPI_4_0_PCAT_COMPAT;
+ MadtHeader->Flags = EFI_ACPI_6_3_PCAT_COMPAT;
return EFI_SUCCESS;
}
@@ -539,7 +540,7 @@ CopyStructure (
//
// Initialize the number of table entries and the table based on the table header passed in.
//
- if (Header->Signature == EFI_ACPI_4_0_MULTIPLE_APIC_DESCRIPTION_TABLE_SIGNATURE) {
+ if (Header->Signature == EFI_ACPI_6_3_MULTIPLE_APIC_DESCRIPTION_TABLE_SIGNATURE) {
TableNumEntries = sizeof (mMadtStructureTable) / sizeof (STRUCTURE_HEADER);
StructureTable = mMadtStructureTable;
} else {
@@ -649,7 +650,7 @@ BuildAcpiTable (
return EFI_INVALID_PARAMETER;
}
- if (AcpiHeader->Signature != EFI_ACPI_4_0_MULTIPLE_APIC_DESCRIPTION_TABLE_SIGNATURE) {
+ if (AcpiHeader->Signature != EFI_ACPI_6_3_MULTIPLE_APIC_DESCRIPTION_TABLE_SIGNATURE) {
DEBUG ((
DEBUG_ERROR,
"MADT header signature is expected, actually 0x%08x\n",
@@ -740,15 +741,15 @@ InstallMadtFromScratch (
{
EFI_STATUS Status;
UINTN Index;
- EFI_ACPI_4_0_MULTIPLE_APIC_DESCRIPTION_TABLE_HEADER *NewMadtTable;
+ EFI_ACPI_6_3_MULTIPLE_APIC_DESCRIPTION_TABLE_HEADER *NewMadtTable;
UINTN TableHandle;
- EFI_ACPI_4_0_MULTIPLE_APIC_DESCRIPTION_TABLE_HEADER MadtTableHeader;
- EFI_ACPI_4_0_PROCESSOR_LOCAL_APIC_STRUCTURE ProcLocalApicStruct;
- EFI_ACPI_4_0_IO_APIC_STRUCTURE IoApicStruct;
- EFI_ACPI_4_0_INTERRUPT_SOURCE_OVERRIDE_STRUCTURE IntSrcOverrideStruct;
- EFI_ACPI_4_0_LOCAL_APIC_NMI_STRUCTURE LocalApciNmiStruct;
- EFI_ACPI_4_0_PROCESSOR_LOCAL_X2APIC_STRUCTURE ProcLocalX2ApicStruct;
- EFI_ACPI_4_0_LOCAL_X2APIC_NMI_STRUCTURE LocalX2ApicNmiStruct;
+ EFI_ACPI_6_3_MULTIPLE_APIC_DESCRIPTION_TABLE_HEADER MadtTableHeader;
+ EFI_ACPI_6_3_PROCESSOR_LOCAL_APIC_STRUCTURE ProcLocalApicStruct;
+ EFI_ACPI_6_3_IO_APIC_STRUCTURE IoApicStruct;
+ EFI_ACPI_6_3_INTERRUPT_SOURCE_OVERRIDE_STRUCTURE IntSrcOverrideStruct;
+ EFI_ACPI_6_3_LOCAL_APIC_NMI_STRUCTURE LocalApciNmiStruct;
+ EFI_ACPI_6_3_PROCESSOR_LOCAL_X2APIC_STRUCTURE ProcLocalX2ApicStruct;
+ EFI_ACPI_6_3_LOCAL_X2APIC_NMI_STRUCTURE LocalX2ApicNmiStruct;
STRUCTURE_HEADER **MadtStructs;
UINTN MaxMadtStructCount;
UINTN MadtStructsIndex;
@@ -809,11 +810,11 @@ InstallMadtFromScratch (
//
// Build Processor Local APIC Structures and Processor Local X2APIC Structures
//
- ProcLocalApicStruct.Type = EFI_ACPI_4_0_PROCESSOR_LOCAL_APIC;
- ProcLocalApicStruct.Length = sizeof (EFI_ACPI_4_0_PROCESSOR_LOCAL_APIC_STRUCTURE);
+ ProcLocalApicStruct.Type = EFI_ACPI_6_3_PROCESSOR_LOCAL_APIC;
+ ProcLocalApicStruct.Length = sizeof (EFI_ACPI_6_3_PROCESSOR_LOCAL_APIC_STRUCTURE);
- ProcLocalX2ApicStruct.Type = EFI_ACPI_4_0_PROCESSOR_LOCAL_X2APIC;
- ProcLocalX2ApicStruct.Length = sizeof (EFI_ACPI_4_0_PROCESSOR_LOCAL_X2APIC_STRUCTURE);
+ ProcLocalX2ApicStruct.Type = EFI_ACPI_6_3_PROCESSOR_LOCAL_X2APIC;
+ ProcLocalX2ApicStruct.Length = sizeof (EFI_ACPI_6_3_PROCESSOR_LOCAL_X2APIC_STRUCTURE);
ProcLocalX2ApicStruct.Reserved[0] = 0;
ProcLocalX2ApicStruct.Reserved[1] = 0;
@@ -824,9 +825,9 @@ InstallMadtFromScratch (
// use a processor local x2APIC structure.
//
if (!mX2ApicEnabled && mCpuApicIdOrderTable[Index].ApicId < MAX_UINT8) {
- ProcLocalApicStruct.Flags = (UINT8) mCpuApicIdOrderTable[Index].Flags;
- ProcLocalApicStruct.ApicId = (UINT8) mCpuApicIdOrderTable[Index].ApicId;
- ProcLocalApicStruct.AcpiProcessorId = (UINT8) mCpuApicIdOrderTable[Index].AcpiProcessorId;
+ ProcLocalApicStruct.Flags = (UINT8) mCpuApicIdOrderTable[Index].Flags;
+ ProcLocalApicStruct.ApicId = (UINT8) mCpuApicIdOrderTable[Index].ApicId;
+ ProcLocalApicStruct.AcpiProcessorUid = (UINT8) mCpuApicIdOrderTable[Index].AcpiProcessorUid;
ASSERT (MadtStructsIndex < MaxMadtStructCount);
Status = CopyStructure (
@@ -837,7 +838,7 @@ InstallMadtFromScratch (
} else if (mCpuApicIdOrderTable[Index].ApicId != 0xFFFFFFFF) {
ProcLocalX2ApicStruct.Flags = (UINT8) mCpuApicIdOrderTable[Index].Flags;
ProcLocalX2ApicStruct.X2ApicId = mCpuApicIdOrderTable[Index].ApicId;
- ProcLocalX2ApicStruct.AcpiProcessorUid = mCpuApicIdOrderTable[Index].AcpiProcessorId;
+ ProcLocalX2ApicStruct.AcpiProcessorUid = mCpuApicIdOrderTable[Index].AcpiProcessorUid;
ASSERT (MadtStructsIndex < MaxMadtStructCount);
Status = CopyStructure (
@@ -855,8 +856,8 @@ InstallMadtFromScratch (
//
// Build I/O APIC Structures
//
- IoApicStruct.Type = EFI_ACPI_4_0_IO_APIC;
- IoApicStruct.Length = sizeof (EFI_ACPI_4_0_IO_APIC_STRUCTURE);
+ IoApicStruct.Type = EFI_ACPI_6_3_IO_APIC;
+ IoApicStruct.Length = sizeof (EFI_ACPI_6_3_IO_APIC_STRUCTURE);
IoApicStruct.Reserved = 0;
PcIoApicEnable = PcdGet32 (PcdPcIoApicEnable);
@@ -902,8 +903,8 @@ InstallMadtFromScratch (
//
// Build Interrupt Source Override Structures
//
- IntSrcOverrideStruct.Type = EFI_ACPI_4_0_INTERRUPT_SOURCE_OVERRIDE;
- IntSrcOverrideStruct.Length = sizeof (EFI_ACPI_4_0_INTERRUPT_SOURCE_OVERRIDE_STRUCTURE);
+ IntSrcOverrideStruct.Type = EFI_ACPI_6_3_INTERRUPT_SOURCE_OVERRIDE;
+ IntSrcOverrideStruct.Length = sizeof (EFI_ACPI_6_3_INTERRUPT_SOURCE_OVERRIDE_STRUCTURE);
//
// IRQ0=>IRQ2 Interrupt Source Override Structure
@@ -946,11 +947,11 @@ InstallMadtFromScratch (
//
// Build Local APIC NMI Structures
//
- LocalApciNmiStruct.Type = EFI_ACPI_4_0_LOCAL_APIC_NMI;
- LocalApciNmiStruct.Length = sizeof (EFI_ACPI_4_0_LOCAL_APIC_NMI_STRUCTURE);
- LocalApciNmiStruct.AcpiProcessorId = 0xFF; // Applies to all processors
- LocalApciNmiStruct.Flags = 0x0005; // Flags - Edge-tiggered, Active High
- LocalApciNmiStruct.LocalApicLint = 0x1;
+ LocalApciNmiStruct.Type = EFI_ACPI_6_3_LOCAL_APIC_NMI;
+ LocalApciNmiStruct.Length = sizeof (EFI_ACPI_6_3_LOCAL_APIC_NMI_STRUCTURE);
+ LocalApciNmiStruct.AcpiProcessorUid = 0xFF; // Applies to all processors
+ LocalApciNmiStruct.Flags = 0x0005; // Flags - Edge-tiggered, Active High
+ LocalApciNmiStruct.LocalApicLint = 0x1;
ASSERT (MadtStructsIndex < MaxMadtStructCount);
Status = CopyStructure (
@@ -967,8 +968,8 @@ InstallMadtFromScratch (
// Build Local x2APIC NMI Structure
//
if (mX2ApicEnabled) {
- LocalX2ApicNmiStruct.Type = EFI_ACPI_4_0_LOCAL_X2APIC_NMI;
- LocalX2ApicNmiStruct.Length = sizeof (EFI_ACPI_4_0_LOCAL_X2APIC_NMI_STRUCTURE);
+ LocalX2ApicNmiStruct.Type = EFI_ACPI_6_3_LOCAL_X2APIC_NMI;
+ LocalX2ApicNmiStruct.Length = sizeof (EFI_ACPI_6_3_LOCAL_X2APIC_NMI_STRUCTURE);
LocalX2ApicNmiStruct.Flags = 0x000D; // Flags - Level-tiggered, Active High
LocalX2ApicNmiStruct.AcpiProcessorUid = 0xFFFFFFFF; // Applies to all processors
LocalX2ApicNmiStruct.LocalX2ApicLint = 0x01;
@@ -992,12 +993,12 @@ InstallMadtFromScratch (
// Build Madt Structure from the Madt Header and collection of pointers in MadtStructs[]
//
Status = BuildAcpiTable (
- (EFI_ACPI_DESCRIPTION_HEADER *) &MadtTableHeader,
- sizeof (EFI_ACPI_4_0_MULTIPLE_APIC_DESCRIPTION_TABLE_HEADER),
- MadtStructs,
- MadtStructsIndex,
- (UINT8 **) &NewMadtTable
- );
+ (EFI_ACPI_DESCRIPTION_HEADER *) &MadtTableHeader,
+ sizeof (EFI_ACPI_6_3_MULTIPLE_APIC_DESCRIPTION_TABLE_HEADER),
+ MadtStructs,
+ MadtStructsIndex,
+ (UINT8 **)&NewMadtTable
+ );
if (EFI_ERROR (Status)) {
DEBUG ((DEBUG_ERROR, "BuildAcpiTable failed: %r\n", Status));
goto Done;
@@ -1087,7 +1088,7 @@ InstallMcfgFromScratch (
}
//
- // Publish Madt Structure to ACPI
+ // Publish Mcfg Structure to ACPI
//
Status = mAcpiTable->InstallAcpiTable (
mAcpiTable,
@@ -1120,7 +1121,7 @@ PlatformUpdateTables (
EFI_ACPI_DESCRIPTION_HEADER *TableHeader;
UINT8 *TempOemId;
UINT64 TempOemTableId;
- EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE *FadtHeader;
+ EFI_ACPI_6_3_FIXED_ACPI_DESCRIPTION_TABLE *FadtHeader;
EFI_ACPI_HIGH_PRECISION_EVENT_TIMER_TABLE_HEADER *HpetTable;
UINT32 HpetBaseAddress;
EFI_ACPI_HIGH_PRECISION_EVENT_TIMER_BLOCK_ID HpetBlockId;
@@ -1177,12 +1178,12 @@ PlatformUpdateTables (
//
switch (Table->Signature) {
- case EFI_ACPI_4_0_MULTIPLE_APIC_DESCRIPTION_TABLE_SIGNATURE:
- ASSERT (FALSE);
+ case EFI_ACPI_6_3_MULTIPLE_APIC_DESCRIPTION_TABLE_SIGNATURE:
+ ASSERT(FALSE);
break;
- case EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE_SIGNATURE:
- FadtHeader = (EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE *) Table;
+ case EFI_ACPI_6_3_FIXED_ACPI_DESCRIPTION_TABLE_SIGNATURE:
+ FadtHeader = (EFI_ACPI_6_3_FIXED_ACPI_DESCRIPTION_TABLE *) Table;
FadtHeader->PreferredPmProfile = PcdGet8 (PcdFadtPreferredPmProfile);
FadtHeader->IaPcBootArch = PcdGet16 (PcdFadtIaPcBootArch);
@@ -1228,7 +1229,7 @@ PlatformUpdateTables (
DEBUG ((DEBUG_INFO, " Flags 0x%x\n", FadtHeader->Flags));
break;
- case EFI_ACPI_3_0_HIGH_PRECISION_EVENT_TIMER_TABLE_SIGNATURE:
+ case EFI_ACPI_6_3_HIGH_PRECISION_EVENT_TIMER_TABLE_SIGNATURE:
HpetTable = (EFI_ACPI_HIGH_PRECISION_EVENT_TIMER_TABLE_HEADER *)Table;
HpetBaseAddress = PcdGet32 (PcdHpetBaseAddress);
HpetTable->BaseAddressLower32Bit.Address = HpetBaseAddress;
@@ -1280,8 +1281,8 @@ IsHardwareChange (
UINTN HWChangeSize;
UINT32 PciId;
UINTN Handle;
- EFI_ACPI_2_0_FIRMWARE_ACPI_CONTROL_STRUCTURE *FacsPtr;
- EFI_ACPI_3_0_FIXED_ACPI_DESCRIPTION_TABLE *pFADT;
+ EFI_ACPI_6_3_FIRMWARE_ACPI_CONTROL_STRUCTURE *FacsPtr;
+ EFI_ACPI_6_3_FIXED_ACPI_DESCRIPTION_TABLE *pFADT;
HandleCount = 0;
HandleBuffer = NULL;
@@ -1327,7 +1328,7 @@ IsHardwareChange (
//
Handle = 0;
Status = LocateAcpiTableBySignature (
- EFI_ACPI_1_0_FIXED_ACPI_DESCRIPTION_TABLE_SIGNATURE,
+ EFI_ACPI_6_3_FIXED_ACPI_DESCRIPTION_TABLE_SIGNATURE,
(EFI_ACPI_DESCRIPTION_HEADER **) &pFADT,
&Handle
);
@@ -1349,7 +1350,7 @@ IsHardwareChange (
//
// Set HardwareSignature value based on CRC value.
//
- FacsPtr = (EFI_ACPI_2_0_FIRMWARE_ACPI_CONTROL_STRUCTURE *)(UINTN)pFADT->FirmwareCtrl;
+ FacsPtr = (EFI_ACPI_6_3_FIRMWARE_ACPI_CONTROL_STRUCTURE *)(UINTN)pFADT->FirmwareCtrl;
FacsPtr->HardwareSignature = CRC;
FreePool (HWChange);
}
diff --git a/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/Facs/Facs.c b/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/Facs/Facs.c
index cde6e478c6b9..8700c44e633d 100644
--- a/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/Facs/Facs.c
+++ b/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/Facs/Facs.c
@@ -1,9 +1,10 @@
/** @file
- This file contains a structure definition for the ACPI 5.0 Firmware ACPI
+ This file contains a structure definition for the ACPI 6.3 Firmware ACPI
Control Structure (FACS). The contents of this file should only be modified
for bug fixes, no porting is required.
Copyright (c) 2017, Intel Corporation. All rights reserved.<BR>
+Copyright (c) Microsoft Corporation.<BR>
SPDX-License-Identifier: BSD-2-Clause-Patent
**/
@@ -35,9 +36,9 @@ SPDX-License-Identifier: BSD-2-Clause-Patent
// Please modify all values in Facs.h only.
//
-EFI_ACPI_5_0_FIRMWARE_ACPI_CONTROL_STRUCTURE Facs = {
- EFI_ACPI_5_0_FIRMWARE_ACPI_CONTROL_STRUCTURE_SIGNATURE,
- sizeof (EFI_ACPI_5_0_FIRMWARE_ACPI_CONTROL_STRUCTURE),
+EFI_ACPI_6_3_FIRMWARE_ACPI_CONTROL_STRUCTURE Facs = {
+ EFI_ACPI_6_3_FIRMWARE_ACPI_CONTROL_STRUCTURE_SIGNATURE,
+ sizeof (EFI_ACPI_6_3_FIRMWARE_ACPI_CONTROL_STRUCTURE),
//
// Hardware Signature will be updated at runtime
@@ -48,7 +49,7 @@ EFI_ACPI_5_0_FIRMWARE_ACPI_CONTROL_STRUCTURE Facs = {
EFI_ACPI_GLOBAL_LOCK,
EFI_ACPI_FIRMWARE_CONTROL_STRUCTURE_FLAGS,
EFI_ACPI_X_FIRMWARE_WAKING_VECTOR,
- EFI_ACPI_5_0_FIRMWARE_ACPI_CONTROL_STRUCTURE_VERSION,
+ EFI_ACPI_6_3_FIRMWARE_ACPI_CONTROL_STRUCTURE_VERSION,
{
EFI_ACPI_RESERVED_BYTE,
EFI_ACPI_RESERVED_BYTE,
diff --git a/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/Fadt/Fadt.c b/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/Fadt/Fadt.c
index 6efb38cda40d..3418e960972f 100644
--- a/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/Fadt/Fadt.c
+++ b/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/Fadt/Fadt.c
@@ -1,9 +1,10 @@
/** @file
- This file contains a structure definition for the ACPI 5.0 Fixed ACPI
+ This file contains a structure definition for the ACPI 6.3 Fixed ACPI
Description Table (FADT). The contents of this file should only be modified
for bug fixes, no porting is required.
Copyright (c) 2017, Intel Corporation. All rights reserved.<BR>
+Copyright (c) Microsoft Corporation.<BR>
SPDX-License-Identifier: BSD-2-Clause-Patent
**/
@@ -44,9 +45,13 @@ SPDX-License-Identifier: BSD-2-Clause-Patent
//
// IA-PC Boot Architecture Flags
//
-
#define EFI_ACPI_IAPC_BOOT_ARCH 0 // To be fixed
+//
+// ARM Boot Architecture Flags
+//
+#define EFI_ACPI_ARM_BOOT_ARCH 0 // To be fixed
+
//
// Fixed Feature Flags
//
@@ -55,7 +60,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent
//
// PM1A Event Register Block Generic Address Information
//
-#define EFI_ACPI_PM1A_EVT_BLK_ADDRESS_SPACE_ID EFI_ACPI_2_0_SYSTEM_IO
+#define EFI_ACPI_PM1A_EVT_BLK_ADDRESS_SPACE_ID EFI_ACPI_6_3_SYSTEM_IO
#define EFI_ACPI_PM1A_EVT_BLK_BIT_WIDTH 0x20
#define EFI_ACPI_PM1A_EVT_BLK_BIT_OFFSET 0x00
#define EFI_ACPI_PM1A_EVT_BLK_ADDRESS 0 // To be fixed
@@ -63,7 +68,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent
//
// PM1B Event Register Block Generic Address Information
//
-#define EFI_ACPI_PM1B_EVT_BLK_ADDRESS_SPACE_ID EFI_ACPI_2_0_SYSTEM_IO
+#define EFI_ACPI_PM1B_EVT_BLK_ADDRESS_SPACE_ID EFI_ACPI_6_3_SYSTEM_IO
#define EFI_ACPI_PM1B_EVT_BLK_BIT_WIDTH 0x00
#define EFI_ACPI_PM1B_EVT_BLK_BIT_OFFSET 0x00
#define EFI_ACPI_PM1B_EVT_BLK_ADDRESS 0 // To be fixed
@@ -71,7 +76,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent
//
// PM1A Control Register Block Generic Address Information
//
-#define EFI_ACPI_PM1A_CNT_BLK_ADDRESS_SPACE_ID EFI_ACPI_2_0_SYSTEM_IO
+#define EFI_ACPI_PM1A_CNT_BLK_ADDRESS_SPACE_ID EFI_ACPI_6_3_SYSTEM_IO
#define EFI_ACPI_PM1A_CNT_BLK_BIT_WIDTH 0x10
#define EFI_ACPI_PM1A_CNT_BLK_BIT_OFFSET 0x00
#define EFI_ACPI_PM1A_CNT_BLK_ADDRESS 0 // To be fixed
@@ -79,7 +84,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent
//
// PM1B Control Register Block Generic Address Information
//
-#define EFI_ACPI_PM1B_CNT_BLK_ADDRESS_SPACE_ID EFI_ACPI_2_0_SYSTEM_IO
+#define EFI_ACPI_PM1B_CNT_BLK_ADDRESS_SPACE_ID EFI_ACPI_6_3_SYSTEM_IO
#define EFI_ACPI_PM1B_CNT_BLK_BIT_WIDTH 0x00
#define EFI_ACPI_PM1B_CNT_BLK_BIT_OFFSET 0x00
#define EFI_ACPI_PM1B_CNT_BLK_ADDRESS 0 // To be fixed
@@ -87,7 +92,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent
//
// PM2 Control Register Block Generic Address Information
//
-#define EFI_ACPI_PM2_CNT_BLK_ADDRESS_SPACE_ID EFI_ACPI_2_0_SYSTEM_IO
+#define EFI_ACPI_PM2_CNT_BLK_ADDRESS_SPACE_ID EFI_ACPI_6_3_SYSTEM_IO
#define EFI_ACPI_PM2_CNT_BLK_BIT_WIDTH 0x08
#define EFI_ACPI_PM2_CNT_BLK_BIT_OFFSET 0x00
#define EFI_ACPI_PM2_CNT_BLK_ADDRESS 0 // To be fixed
@@ -96,7 +101,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent
// Power Management Timer Control Register Block Generic Address
// Information
//
-#define EFI_ACPI_PM_TMR_BLK_ADDRESS_SPACE_ID EFI_ACPI_2_0_SYSTEM_IO
+#define EFI_ACPI_PM_TMR_BLK_ADDRESS_SPACE_ID EFI_ACPI_6_3_SYSTEM_IO
#define EFI_ACPI_PM_TMR_BLK_BIT_WIDTH 0x20
#define EFI_ACPI_PM_TMR_BLK_BIT_OFFSET 0x00
#define EFI_ACPI_PM_TMR_BLK_ADDRESS 0 // To be fixed
@@ -105,7 +110,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent
// General Purpose Event 0 Register Block Generic Address
// Information
//
-#define EFI_ACPI_GPE0_BLK_ADDRESS_SPACE_ID EFI_ACPI_2_0_SYSTEM_IO
+#define EFI_ACPI_GPE0_BLK_ADDRESS_SPACE_ID EFI_ACPI_6_3_SYSTEM_IO
#define EFI_ACPI_GPE0_BLK_BIT_WIDTH 0 // size of R_PCH_ACPI_GPE0_STS_127_96 + R_PCH_ACPI_GPE0_EN_127_96
#define EFI_ACPI_GPE0_BLK_BIT_OFFSET 0x00
#define EFI_ACPI_GPE0_BLK_ADDRESS 0 // To be fixed
@@ -114,14 +119,14 @@ SPDX-License-Identifier: BSD-2-Clause-Patent
// General Purpose Event 1 Register Block Generic Address
// Information
//
-#define EFI_ACPI_GPE1_BLK_ADDRESS_SPACE_ID EFI_ACPI_2_0_SYSTEM_IO
+#define EFI_ACPI_GPE1_BLK_ADDRESS_SPACE_ID EFI_ACPI_6_3_SYSTEM_IO
#define EFI_ACPI_GPE1_BLK_BIT_WIDTH 0x0
#define EFI_ACPI_GPE1_BLK_BIT_OFFSET 0x0
#define EFI_ACPI_GPE1_BLK_ADDRESS 0 // To be fixed
//
// Reset Register Generic Address Information
//
-#define EFI_ACPI_RESET_REG_ADDRESS_SPACE_ID EFI_ACPI_2_0_SYSTEM_IO
+#define EFI_ACPI_RESET_REG_ADDRESS_SPACE_ID EFI_ACPI_6_3_SYSTEM_IO
#define EFI_ACPI_RESET_REG_BIT_WIDTH 0x08
#define EFI_ACPI_RESET_REG_BIT_OFFSET 0x00
#define EFI_ACPI_RESET_REG_ADDRESS 0x00000CF9
@@ -162,11 +167,11 @@ SPDX-License-Identifier: BSD-2-Clause-Patent
// Please modify all values in Fadt.h only.
//
-EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE Fadt = {
+EFI_ACPI_6_3_FIXED_ACPI_DESCRIPTION_TABLE Fadt = {
{
- EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE_SIGNATURE,
- sizeof (EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE),
- EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE_REVISION,
+ EFI_ACPI_6_3_FIXED_ACPI_DESCRIPTION_TABLE_SIGNATURE,
+ sizeof (EFI_ACPI_6_3_FIXED_ACPI_DESCRIPTION_TABLE),
+ EFI_ACPI_6_3_FIXED_ACPI_DESCRIPTION_TABLE_REVISION,
//
// Checksum will be updated at runtime
@@ -187,9 +192,9 @@ EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE Fadt = {
//
// These addresses will be updated at runtime
//
- 0x00000000,
0x00000000,
-
+ 0x00000000,
+
EFI_ACPI_RESERVED_BYTE,
EFI_ACPI_PREFERRED_PM_PROFILE,
EFI_ACPI_SCI_INT,
@@ -198,7 +203,7 @@ EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE Fadt = {
EFI_ACPI_ACPI_DISABLE,
EFI_ACPI_S4_BIOS_REQ,
EFI_ACPI_PSTATE_CNT,
-
+
EFI_ACPI_PM1A_EVT_BLK_ADDRESS,
EFI_ACPI_PM1B_EVT_BLK_ADDRESS,
EFI_ACPI_PM1A_CNT_BLK_ADDRESS,
@@ -240,15 +245,13 @@ EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE Fadt = {
EFI_ACPI_RESET_REG_ADDRESS_SPACE_ID,
EFI_ACPI_RESET_REG_BIT_WIDTH,
EFI_ACPI_RESET_REG_BIT_OFFSET,
- EFI_ACPI_5_0_BYTE,
+ EFI_ACPI_6_3_BYTE,
EFI_ACPI_RESET_REG_ADDRESS
},
EFI_ACPI_RESET_VALUE,
- {
- EFI_ACPI_RESERVED_BYTE,
- EFI_ACPI_RESERVED_BYTE,
- EFI_ACPI_RESERVED_BYTE
- },
+
+ EFI_ACPI_ARM_BOOT_ARCH,
+ EFI_ACPI_6_3_FIXED_ACPI_DESCRIPTION_TABLE_MINOR_REVISION,
//
// These addresses will be updated at runtime
@@ -263,7 +266,7 @@ EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE Fadt = {
EFI_ACPI_PM1A_EVT_BLK_ADDRESS_SPACE_ID,
EFI_ACPI_PM1A_EVT_BLK_BIT_WIDTH,
EFI_ACPI_PM1A_EVT_BLK_BIT_OFFSET,
- EFI_ACPI_5_0_WORD,
+ EFI_ACPI_6_3_WORD,
EFI_ACPI_PM1A_EVT_BLK_ADDRESS
},
{
@@ -273,7 +276,7 @@ EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE Fadt = {
EFI_ACPI_PM1B_EVT_BLK_ADDRESS_SPACE_ID,
EFI_ACPI_PM1B_EVT_BLK_BIT_WIDTH,
EFI_ACPI_PM1B_EVT_BLK_BIT_OFFSET,
- EFI_ACPI_5_0_WORD,
+ EFI_ACPI_6_3_WORD,
EFI_ACPI_PM1B_EVT_BLK_ADDRESS
},
{
@@ -283,7 +286,7 @@ EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE Fadt = {
EFI_ACPI_PM1A_CNT_BLK_ADDRESS_SPACE_ID,
EFI_ACPI_PM1A_CNT_BLK_BIT_WIDTH,
EFI_ACPI_PM1A_CNT_BLK_BIT_OFFSET,
- EFI_ACPI_5_0_WORD,
+ EFI_ACPI_6_3_WORD,
EFI_ACPI_PM1A_CNT_BLK_ADDRESS
},
{
@@ -293,7 +296,7 @@ EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE Fadt = {
EFI_ACPI_PM1B_CNT_BLK_ADDRESS_SPACE_ID,
EFI_ACPI_PM1B_CNT_BLK_BIT_WIDTH,
EFI_ACPI_PM1B_CNT_BLK_BIT_OFFSET,
- EFI_ACPI_5_0_WORD,
+ EFI_ACPI_6_3_WORD,
EFI_ACPI_PM1B_CNT_BLK_ADDRESS
},
{
@@ -303,7 +306,7 @@ EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE Fadt = {
EFI_ACPI_PM2_CNT_BLK_ADDRESS_SPACE_ID,
EFI_ACPI_PM2_CNT_BLK_BIT_WIDTH,
EFI_ACPI_PM2_CNT_BLK_BIT_OFFSET,
- EFI_ACPI_5_0_BYTE,
+ EFI_ACPI_6_3_BYTE,
EFI_ACPI_PM2_CNT_BLK_ADDRESS
},
{
@@ -313,7 +316,7 @@ EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE Fadt = {
EFI_ACPI_PM_TMR_BLK_ADDRESS_SPACE_ID,
EFI_ACPI_PM_TMR_BLK_BIT_WIDTH,
EFI_ACPI_PM_TMR_BLK_BIT_OFFSET,
- EFI_ACPI_5_0_DWORD,
+ EFI_ACPI_6_3_DWORD,
EFI_ACPI_PM_TMR_BLK_ADDRESS
},
{
@@ -323,7 +326,7 @@ EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE Fadt = {
EFI_ACPI_GPE0_BLK_ADDRESS_SPACE_ID,
EFI_ACPI_GPE0_BLK_BIT_WIDTH,
EFI_ACPI_GPE0_BLK_BIT_OFFSET,
- EFI_ACPI_5_0_BYTE,
+ EFI_ACPI_6_3_BYTE,
EFI_ACPI_GPE0_BLK_ADDRESS
},
{
@@ -333,7 +336,7 @@ EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE Fadt = {
EFI_ACPI_GPE1_BLK_ADDRESS_SPACE_ID,
EFI_ACPI_GPE1_BLK_BIT_WIDTH,
EFI_ACPI_GPE1_BLK_BIT_OFFSET,
- EFI_ACPI_5_0_BYTE,
+ EFI_ACPI_6_3_BYTE,
EFI_ACPI_GPE1_BLK_ADDRESS
},
{
@@ -355,5 +358,10 @@ EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE Fadt = {
0,
0,
0
- }
+ },
+
+ //
+ // Hypervisor Vendor Identity
+ //
+ 0x0000000000000000,
};
--
2.28.0.windows.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [edk2-platforms][PATCH v2 1/1] MinPlatformPkg/AcpiTables: Update structures for ACPI 6.3
2021-09-24 18:22 [edk2-platforms][PATCH v2 1/1] MinPlatformPkg/AcpiTables: Update structures for ACPI 6.3 Michael Kubacki
@ 2021-10-02 1:13 ` Nate DeSimone
2021-10-02 1:14 ` Nate DeSimone
1 sibling, 0 replies; 3+ messages in thread
From: Nate DeSimone @ 2021-10-02 1:13 UTC (permalink / raw)
To: mikuback@linux.microsoft.com, devel@edk2.groups.io
Cc: Chiu, Chasel, Liming Gao, Dong, Eric, Maddy, Daniel,
Michael Kubacki
Reviewed-by: Nate DeSimone <nathaniel.l.desimone@intel.com>
> -----Original Message-----
> From: mikuback@linux.microsoft.com <mikuback@linux.microsoft.com>
> Sent: Friday, September 24, 2021 11:23 AM
> To: devel@edk2.groups.io
> Cc: Chiu, Chasel <chasel.chiu@intel.com>; Desimone, Nathaniel L
> <nathaniel.l.desimone@intel.com>; Liming Gao
> <gaoliming@byosoft.com.cn>; Dong, Eric <eric.dong@intel.com>; Maddy,
> Daniel <danmad@microsoft.com>; Michael Kubacki
> <michael.kubacki@microsoft.com>
> Subject: [edk2-platforms][PATCH v2 1/1] MinPlatformPkg/AcpiTables:
> Update structures for ACPI 6.3
>
> From: Daniel Maddy <danmad@microsoft.com>
>
> REF:https://bugzilla.tianocore.org/show_bug.cgi?id=3535
>
> Updates ACPI table structures in MinPlatformPkg for ACPI 6.3.
>
> Cc: Chasel Chiu <chasel.chiu@intel.com>
> Cc: Nate DeSimone <nathaniel.l.desimone@intel.com>
> Cc: Liming Gao <gaoliming@byosoft.com.cn>
> Cc: Eric Dong <eric.dong@intel.com>
> Cc: Daniel Maddy <danmad@microsoft.com>
> Co-authored-by: Michael Kubacki <michael.kubacki@microsoft.com>
> Signed-off-by: Michael Kubacki <michael.kubacki@microsoft.com>
> Reviewed-by: Nate DeSimone <nathaniel.l.desimone@intel.com>
> ---
> Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/AcpiPlatform.c | 181
> ++++++++++----------
> Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/Facs/Facs.c | 11 +-
> Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/Fadt/Fadt.c | 74 ++++----
> 3 files changed, 138 insertions(+), 128 deletions(-)
>
> diff --git a/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/AcpiPlatform.c
> b/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/AcpiPlatform.c
> index 843ba832ce67..f5c4f2c3f1a9 100644
> --- a/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/AcpiPlatform.c
> +++ b/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/AcpiPlatform.c
> @@ -2,6 +2,7 @@
> ACPI Platform Driver
>
> Copyright (c) 2017 - 2021, Intel Corporation. All rights reserved.<BR>
> +Copyright (c) Microsoft Corporation.<BR>
> SPDX-License-Identifier: BSD-2-Clause-Patent
>
> **/
> @@ -11,7 +12,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent #pragma
> pack(1)
>
> typedef struct {
> - UINT32 AcpiProcessorId;
> + UINT32 AcpiProcessorUid;
> UINT32 ApicId;
> UINT32 Flags;
> UINT32 SocketNum;
> @@ -25,9 +26,9 @@ typedef struct {
> // Define Union of IO APIC & Local APIC structure; // typedef union {
> - EFI_ACPI_4_0_PROCESSOR_LOCAL_APIC_STRUCTURE AcpiLocalApic;
> - EFI_ACPI_4_0_IO_APIC_STRUCTURE AcpiIoApic;
> - EFI_ACPI_4_0_PROCESSOR_LOCAL_X2APIC_STRUCTURE AcpiLocalx2Apic;
> + EFI_ACPI_6_3_PROCESSOR_LOCAL_APIC_STRUCTURE AcpiLocalApic;
> + EFI_ACPI_6_3_IO_APIC_STRUCTURE AcpiIoApic;
> + EFI_ACPI_6_3_PROCESSOR_LOCAL_X2APIC_STRUCTURE AcpiLocalx2Apic;
> struct {
> UINT8 Type;
> UINT8 Length;
> @@ -36,9 +37,9 @@ typedef union {
>
> #pragma pack()
>
> -extern EFI_ACPI_5_0_FIRMWARE_ACPI_CONTROL_STRUCTURE Facs; -
> extern EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE Fadt; -extern
> EFI_ACPI_HIGH_PRECISION_EVENT_TIMER_TABLE_HEADER Hpet;
> +extern EFI_ACPI_6_3_FIRMWARE_ACPI_CONTROL_STRUCTURE Facs;
> +extern EFI_ACPI_6_3_FIXED_ACPI_DESCRIPTION_TABLE Fadt;
> +extern EFI_ACPI_HIGH_PRECISION_EVENT_TIMER_TABLE_HEADER Hpet;
> extern EFI_ACPI_WSMT_TABLE Wsmt;
>
> VOID *mLocalTable[] = {
> @@ -103,7 +104,7 @@ DebugDisplayReOrderTable (
> for (Index = 0; Index < mNumberOfCpus; Index++) {
> DEBUG ((DEBUG_INFO, " %02d 0x%02X 0x%02X %d %d
> %d\n",
> Index,
> - CpuApicIdOrderTable[Index].AcpiProcessorId,
> + CpuApicIdOrderTable[Index].AcpiProcessorUid,
> CpuApicIdOrderTable[Index].ApicId,
> CpuApicIdOrderTable[Index].Thread,
> CpuApicIdOrderTable[Index].Flags, @@ -118,31 +119,31 @@
> AppendCpuMapTableEntry (
> )
> {
> EFI_STATUS Status;
> - EFI_ACPI_4_0_PROCESSOR_LOCAL_APIC_STRUCTURE *LocalApicPtr;
> - EFI_ACPI_4_0_PROCESSOR_LOCAL_X2APIC_STRUCTURE *LocalX2ApicPtr;
> + EFI_ACPI_6_3_PROCESSOR_LOCAL_APIC_STRUCTURE *LocalApicPtr;
> + EFI_ACPI_6_3_PROCESSOR_LOCAL_X2APIC_STRUCTURE *LocalX2ApicPtr;
> UINT8 Type;
>
> Status = EFI_SUCCESS;
> Type = ((ACPI_APIC_STRUCTURE_PTR *)ApicPtr)->AcpiApicCommon.Type;
> - LocalApicPtr = (EFI_ACPI_4_0_PROCESSOR_LOCAL_APIC_STRUCTURE
> *)(&((ACPI_APIC_STRUCTURE_PTR *)ApicPtr)->AcpiLocalApic);
> - LocalX2ApicPtr = (EFI_ACPI_4_0_PROCESSOR_LOCAL_X2APIC_STRUCTURE
> *)(&((ACPI_APIC_STRUCTURE_PTR *)ApicPtr)->AcpiLocalx2Apic);
> + LocalApicPtr = (EFI_ACPI_6_3_PROCESSOR_LOCAL_APIC_STRUCTURE
> + *)(&((ACPI_APIC_STRUCTURE_PTR *)ApicPtr)->AcpiLocalApic);
> + LocalX2ApicPtr = (EFI_ACPI_6_3_PROCESSOR_LOCAL_X2APIC_STRUCTURE
> + *)(&((ACPI_APIC_STRUCTURE_PTR *)ApicPtr)->AcpiLocalx2Apic);
>
> - if(Type == EFI_ACPI_4_0_PROCESSOR_LOCAL_APIC) {
> + if(Type == EFI_ACPI_6_3_PROCESSOR_LOCAL_APIC) {
> if(!mX2ApicEnabled) {
> - LocalApicPtr->Flags =
> (UINT8)mCpuApicIdOrderTable[LocalApicCounter].Flags;
> - LocalApicPtr->ApicId =
> (UINT8)mCpuApicIdOrderTable[LocalApicCounter].ApicId;
> - LocalApicPtr->AcpiProcessorId =
> (UINT8)mCpuApicIdOrderTable[LocalApicCounter].AcpiProcessorId;
> + LocalApicPtr->Flags =
> (UINT8)mCpuApicIdOrderTable[LocalApicCounter].Flags;
> + LocalApicPtr->ApicId =
> (UINT8)mCpuApicIdOrderTable[LocalApicCounter].ApicId;
> + LocalApicPtr->AcpiProcessorUid =
> + (UINT8)mCpuApicIdOrderTable[LocalApicCounter].AcpiProcessorUid;
> } else {
> - LocalApicPtr->Flags = 0;
> - LocalApicPtr->ApicId = 0xFF;
> - LocalApicPtr->AcpiProcessorId = (UINT8)0xFF;
> + LocalApicPtr->Flags = 0;
> + LocalApicPtr->ApicId = 0xFF;
> + LocalApicPtr->AcpiProcessorUid = (UINT8)0xFF;
> Status = EFI_UNSUPPORTED;
> }
> - } else if(Type == EFI_ACPI_4_0_PROCESSOR_LOCAL_X2APIC) {
> + } else if(Type == EFI_ACPI_6_3_PROCESSOR_LOCAL_X2APIC) {
> if(mX2ApicEnabled) {
> LocalX2ApicPtr->Flags =
> (UINT8)mCpuApicIdOrderTable[LocalApicCounter].Flags;
> LocalX2ApicPtr->X2ApicId =
> mCpuApicIdOrderTable[LocalApicCounter].ApicId;
> - LocalX2ApicPtr->AcpiProcessorUid =
> mCpuApicIdOrderTable[LocalApicCounter].AcpiProcessorId;
> + LocalX2ApicPtr->AcpiProcessorUid =
> + mCpuApicIdOrderTable[LocalApicCounter].AcpiProcessorUid;
> } else {
> LocalX2ApicPtr->Flags = 0;
> LocalX2ApicPtr->X2ApicId = (UINT32)-1;
> @@ -201,15 +202,15 @@ SortCpuLocalApicInTable (
> //update processorbitMask
> if (CpuIdMapPtr->Flags == 1) {
> if (mForceX2ApicId) {
> - CpuIdMapPtr->SocketNum &= 0x7;
> - CpuIdMapPtr->AcpiProcessorId &= 0xFF; //keep lower 8bit due to use
> Proc obj in dsdt
> + CpuIdMapPtr->SocketNum &= 0x7;
> + CpuIdMapPtr->AcpiProcessorUid &= 0xFF; //keep lower 8bit due
> + to use Proc obj in dsdt
> }
> }
> } else { //not enabled
> - CpuIdMapPtr->ApicId = (UINT32)-1;
> - CpuIdMapPtr->Thread = (UINT32)-1;
> - CpuIdMapPtr->Flags = 0;
> - CpuIdMapPtr->SocketNum = (UINT32)-1;
> + CpuIdMapPtr->ApicId = (UINT32)-1;
> + CpuIdMapPtr->Thread = (UINT32)-1;
> + CpuIdMapPtr->Flags = 0;
> + CpuIdMapPtr->SocketNum = (UINT32)-1;
> } //end if PROC ENABLE
> } //end for CurrentProcessor
>
> @@ -280,12 +281,12 @@ SortCpuLocalApicInTable (
> }
>
> //
> - // 5. Re-assigen AcpiProcessorId for AcpiProcessorUId uses purpose.
> + // 5. Re-assign AcpiProcessorId for AcpiProcessorUid uses purpose.
> //
> for (Socket = 0; Socket < FixedPcdGet32 (PcdMaxCpuSocketCount);
> Socket++) {
> for (CurrProcessor = 0, Index = 0; CurrProcessor < mNumberOfCpus;
> CurrProcessor++) {
> if (mCpuApicIdOrderTable[CurrProcessor].Flags &&
> (mCpuApicIdOrderTable[CurrProcessor].SocketNum == Socket)) {
> - mCpuApicIdOrderTable[CurrProcessor].AcpiProcessorId =
> (ProcessorInfoBuffer.Location.Package << mNumOfBitShift) + Index;
> + mCpuApicIdOrderTable[CurrProcessor].AcpiProcessorUid =
> + (ProcessorInfoBuffer.Location.Package << mNumOfBitShift) + Index;
> Index++;
> }
> }
> @@ -312,17 +313,17 @@ typedef struct {
> } STRUCTURE_HEADER;
>
> STRUCTURE_HEADER mMadtStructureTable[] = {
> - {EFI_ACPI_4_0_PROCESSOR_LOCAL_APIC, sizeof
> (EFI_ACPI_4_0_PROCESSOR_LOCAL_APIC_STRUCTURE)},
> - {EFI_ACPI_4_0_IO_APIC, sizeof
> (EFI_ACPI_4_0_IO_APIC_STRUCTURE)},
> - {EFI_ACPI_4_0_INTERRUPT_SOURCE_OVERRIDE, sizeof
> (EFI_ACPI_4_0_INTERRUPT_SOURCE_OVERRIDE_STRUCTURE)},
> - {EFI_ACPI_4_0_NON_MASKABLE_INTERRUPT_SOURCE, sizeof
> (EFI_ACPI_4_0_NON_MASKABLE_INTERRUPT_SOURCE_STRUCTURE)},
> - {EFI_ACPI_4_0_LOCAL_APIC_NMI, sizeof
> (EFI_ACPI_4_0_LOCAL_APIC_NMI_STRUCTURE)},
> - {EFI_ACPI_4_0_LOCAL_APIC_ADDRESS_OVERRIDE, sizeof
> (EFI_ACPI_4_0_LOCAL_APIC_ADDRESS_OVERRIDE_STRUCTURE)},
> - {EFI_ACPI_4_0_IO_SAPIC, sizeof
> (EFI_ACPI_4_0_IO_SAPIC_STRUCTURE)},
> - {EFI_ACPI_4_0_LOCAL_SAPIC, sizeof
> (EFI_ACPI_4_0_PROCESSOR_LOCAL_SAPIC_STRUCTURE)},
> - {EFI_ACPI_4_0_PLATFORM_INTERRUPT_SOURCES, sizeof
> (EFI_ACPI_4_0_PLATFORM_INTERRUPT_SOURCES_STRUCTURE)},
> - {EFI_ACPI_4_0_PROCESSOR_LOCAL_X2APIC, sizeof
> (EFI_ACPI_4_0_PROCESSOR_LOCAL_X2APIC_STRUCTURE)},
> - {EFI_ACPI_4_0_LOCAL_X2APIC_NMI, sizeof
> (EFI_ACPI_4_0_LOCAL_X2APIC_NMI_STRUCTURE)}
> + {EFI_ACPI_6_3_PROCESSOR_LOCAL_APIC, sizeof
> (EFI_ACPI_6_3_PROCESSOR_LOCAL_APIC_STRUCTURE)},
> + {EFI_ACPI_6_3_IO_APIC, sizeof
> (EFI_ACPI_6_3_IO_APIC_STRUCTURE)},
> + {EFI_ACPI_6_3_INTERRUPT_SOURCE_OVERRIDE, sizeof
> (EFI_ACPI_6_3_INTERRUPT_SOURCE_OVERRIDE_STRUCTURE)},
> + {EFI_ACPI_6_3_NON_MASKABLE_INTERRUPT_SOURCE, sizeof
> (EFI_ACPI_6_3_NON_MASKABLE_INTERRUPT_SOURCE_STRUCTURE)},
> + {EFI_ACPI_6_3_LOCAL_APIC_NMI, sizeof
> (EFI_ACPI_6_3_LOCAL_APIC_NMI_STRUCTURE)},
> + {EFI_ACPI_6_3_LOCAL_APIC_ADDRESS_OVERRIDE, sizeof
> (EFI_ACPI_6_3_LOCAL_APIC_ADDRESS_OVERRIDE_STRUCTURE)},
> + {EFI_ACPI_6_3_IO_SAPIC, sizeof
> (EFI_ACPI_6_3_IO_SAPIC_STRUCTURE)},
> + {EFI_ACPI_6_3_LOCAL_SAPIC, sizeof
> (EFI_ACPI_6_3_PROCESSOR_LOCAL_SAPIC_STRUCTURE)},
> + {EFI_ACPI_6_3_PLATFORM_INTERRUPT_SOURCES, sizeof
> (EFI_ACPI_6_3_PLATFORM_INTERRUPT_SOURCES_STRUCTURE)},
> + {EFI_ACPI_6_3_PROCESSOR_LOCAL_X2APIC, sizeof
> (EFI_ACPI_6_3_PROCESSOR_LOCAL_X2APIC_STRUCTURE)},
> + {EFI_ACPI_6_3_LOCAL_X2APIC_NMI, sizeof
> (EFI_ACPI_6_3_LOCAL_X2APIC_NMI_STRUCTURE)}
> };
>
> /**
> @@ -481,7 +482,7 @@ InitializeHeader (
> **/
> EFI_STATUS
> InitializeMadtHeader (
> - IN OUT EFI_ACPI_4_0_MULTIPLE_APIC_DESCRIPTION_TABLE_HEADER
> *MadtHeader
> + IN OUT EFI_ACPI_6_3_MULTIPLE_APIC_DESCRIPTION_TABLE_HEADER
> + *MadtHeader
> )
> {
> EFI_STATUS Status;
> @@ -493,8 +494,8 @@ InitializeMadtHeader (
>
> Status = InitializeHeader (
> &MadtHeader->Header,
> - EFI_ACPI_4_0_MULTIPLE_APIC_DESCRIPTION_TABLE_SIGNATURE,
> - EFI_ACPI_4_0_MULTIPLE_APIC_DESCRIPTION_TABLE_REVISION,
> + EFI_ACPI_6_3_MULTIPLE_APIC_DESCRIPTION_TABLE_SIGNATURE,
> + EFI_ACPI_6_3_MULTIPLE_APIC_DESCRIPTION_TABLE_REVISION,
> 0
> );
> if (EFI_ERROR (Status)) {
> @@ -502,7 +503,7 @@ InitializeMadtHeader (
> }
>
> MadtHeader->LocalApicAddress = PcdGet32(PcdLocalApicAddress);
> - MadtHeader->Flags = EFI_ACPI_4_0_PCAT_COMPAT;
> + MadtHeader->Flags = EFI_ACPI_6_3_PCAT_COMPAT;
>
> return EFI_SUCCESS;
> }
> @@ -539,7 +540,7 @@ CopyStructure (
> //
> // Initialize the number of table entries and the table based on the table
> header passed in.
> //
> - if (Header->Signature ==
> EFI_ACPI_4_0_MULTIPLE_APIC_DESCRIPTION_TABLE_SIGNATURE) {
> + if (Header->Signature ==
> + EFI_ACPI_6_3_MULTIPLE_APIC_DESCRIPTION_TABLE_SIGNATURE) {
> TableNumEntries = sizeof (mMadtStructureTable) / sizeof
> (STRUCTURE_HEADER);
> StructureTable = mMadtStructureTable;
> } else {
> @@ -649,7 +650,7 @@ BuildAcpiTable (
> return EFI_INVALID_PARAMETER;
> }
>
> - if (AcpiHeader->Signature !=
> EFI_ACPI_4_0_MULTIPLE_APIC_DESCRIPTION_TABLE_SIGNATURE) {
> + if (AcpiHeader->Signature !=
> + EFI_ACPI_6_3_MULTIPLE_APIC_DESCRIPTION_TABLE_SIGNATURE) {
> DEBUG ((
> DEBUG_ERROR,
> "MADT header signature is expected, actually 0x%08x\n", @@ -740,15
> +741,15 @@ InstallMadtFromScratch ( {
> EFI_STATUS Status;
> UINTN Index;
> - EFI_ACPI_4_0_MULTIPLE_APIC_DESCRIPTION_TABLE_HEADER
> *NewMadtTable;
> + EFI_ACPI_6_3_MULTIPLE_APIC_DESCRIPTION_TABLE_HEADER
> *NewMadtTable;
> UINTN TableHandle;
> - EFI_ACPI_4_0_MULTIPLE_APIC_DESCRIPTION_TABLE_HEADER
> MadtTableHeader;
> - EFI_ACPI_4_0_PROCESSOR_LOCAL_APIC_STRUCTURE
> ProcLocalApicStruct;
> - EFI_ACPI_4_0_IO_APIC_STRUCTURE IoApicStruct;
> - EFI_ACPI_4_0_INTERRUPT_SOURCE_OVERRIDE_STRUCTURE
> IntSrcOverrideStruct;
> - EFI_ACPI_4_0_LOCAL_APIC_NMI_STRUCTURE LocalApciNmiStruct;
> - EFI_ACPI_4_0_PROCESSOR_LOCAL_X2APIC_STRUCTURE
> ProcLocalX2ApicStruct;
> - EFI_ACPI_4_0_LOCAL_X2APIC_NMI_STRUCTURE
> LocalX2ApicNmiStruct;
> + EFI_ACPI_6_3_MULTIPLE_APIC_DESCRIPTION_TABLE_HEADER
> MadtTableHeader;
> + EFI_ACPI_6_3_PROCESSOR_LOCAL_APIC_STRUCTURE
> ProcLocalApicStruct;
> + EFI_ACPI_6_3_IO_APIC_STRUCTURE IoApicStruct;
> + EFI_ACPI_6_3_INTERRUPT_SOURCE_OVERRIDE_STRUCTURE
> IntSrcOverrideStruct;
> + EFI_ACPI_6_3_LOCAL_APIC_NMI_STRUCTURE LocalApciNmiStruct;
> + EFI_ACPI_6_3_PROCESSOR_LOCAL_X2APIC_STRUCTURE
> ProcLocalX2ApicStruct;
> + EFI_ACPI_6_3_LOCAL_X2APIC_NMI_STRUCTURE
> LocalX2ApicNmiStruct;
> STRUCTURE_HEADER **MadtStructs;
> UINTN MaxMadtStructCount;
> UINTN MadtStructsIndex;
> @@ -809,11 +810,11 @@ InstallMadtFromScratch (
> //
> // Build Processor Local APIC Structures and Processor Local X2APIC
> Structures
> //
> - ProcLocalApicStruct.Type = EFI_ACPI_4_0_PROCESSOR_LOCAL_APIC;
> - ProcLocalApicStruct.Length = sizeof
> (EFI_ACPI_4_0_PROCESSOR_LOCAL_APIC_STRUCTURE);
> + ProcLocalApicStruct.Type = EFI_ACPI_6_3_PROCESSOR_LOCAL_APIC;
> + ProcLocalApicStruct.Length = sizeof
> + (EFI_ACPI_6_3_PROCESSOR_LOCAL_APIC_STRUCTURE);
>
> - ProcLocalX2ApicStruct.Type = EFI_ACPI_4_0_PROCESSOR_LOCAL_X2APIC;
> - ProcLocalX2ApicStruct.Length = sizeof
> (EFI_ACPI_4_0_PROCESSOR_LOCAL_X2APIC_STRUCTURE);
> + ProcLocalX2ApicStruct.Type = EFI_ACPI_6_3_PROCESSOR_LOCAL_X2APIC;
> + ProcLocalX2ApicStruct.Length = sizeof
> + (EFI_ACPI_6_3_PROCESSOR_LOCAL_X2APIC_STRUCTURE);
> ProcLocalX2ApicStruct.Reserved[0] = 0;
> ProcLocalX2ApicStruct.Reserved[1] = 0;
>
> @@ -824,9 +825,9 @@ InstallMadtFromScratch (
> // use a processor local x2APIC structure.
> //
> if (!mX2ApicEnabled && mCpuApicIdOrderTable[Index].ApicId <
> MAX_UINT8) {
> - ProcLocalApicStruct.Flags = (UINT8)
> mCpuApicIdOrderTable[Index].Flags;
> - ProcLocalApicStruct.ApicId = (UINT8)
> mCpuApicIdOrderTable[Index].ApicId;
> - ProcLocalApicStruct.AcpiProcessorId = (UINT8)
> mCpuApicIdOrderTable[Index].AcpiProcessorId;
> + ProcLocalApicStruct.Flags = (UINT8)
> mCpuApicIdOrderTable[Index].Flags;
> + ProcLocalApicStruct.ApicId = (UINT8)
> mCpuApicIdOrderTable[Index].ApicId;
> + ProcLocalApicStruct.AcpiProcessorUid = (UINT8)
> + mCpuApicIdOrderTable[Index].AcpiProcessorUid;
>
> ASSERT (MadtStructsIndex < MaxMadtStructCount);
> Status = CopyStructure (
> @@ -837,7 +838,7 @@ InstallMadtFromScratch (
> } else if (mCpuApicIdOrderTable[Index].ApicId != 0xFFFFFFFF) {
> ProcLocalX2ApicStruct.Flags = (UINT8)
> mCpuApicIdOrderTable[Index].Flags;
> ProcLocalX2ApicStruct.X2ApicId =
> mCpuApicIdOrderTable[Index].ApicId;
> - ProcLocalX2ApicStruct.AcpiProcessorUid =
> mCpuApicIdOrderTable[Index].AcpiProcessorId;
> + ProcLocalX2ApicStruct.AcpiProcessorUid =
> + mCpuApicIdOrderTable[Index].AcpiProcessorUid;
>
> ASSERT (MadtStructsIndex < MaxMadtStructCount);
> Status = CopyStructure (
> @@ -855,8 +856,8 @@ InstallMadtFromScratch (
> //
> // Build I/O APIC Structures
> //
> - IoApicStruct.Type = EFI_ACPI_4_0_IO_APIC;
> - IoApicStruct.Length = sizeof (EFI_ACPI_4_0_IO_APIC_STRUCTURE);
> + IoApicStruct.Type = EFI_ACPI_6_3_IO_APIC; IoApicStruct.Length =
> + sizeof (EFI_ACPI_6_3_IO_APIC_STRUCTURE);
> IoApicStruct.Reserved = 0;
>
> PcIoApicEnable = PcdGet32 (PcdPcIoApicEnable); @@ -902,8 +903,8 @@
> InstallMadtFromScratch (
> //
> // Build Interrupt Source Override Structures
> //
> - IntSrcOverrideStruct.Type =
> EFI_ACPI_4_0_INTERRUPT_SOURCE_OVERRIDE;
> - IntSrcOverrideStruct.Length = sizeof
> (EFI_ACPI_4_0_INTERRUPT_SOURCE_OVERRIDE_STRUCTURE);
> + IntSrcOverrideStruct.Type =
> EFI_ACPI_6_3_INTERRUPT_SOURCE_OVERRIDE;
> + IntSrcOverrideStruct.Length = sizeof
> + (EFI_ACPI_6_3_INTERRUPT_SOURCE_OVERRIDE_STRUCTURE);
>
> //
> // IRQ0=>IRQ2 Interrupt Source Override Structure @@ -946,11 +947,11
> @@ InstallMadtFromScratch (
> //
> // Build Local APIC NMI Structures
> //
> - LocalApciNmiStruct.Type = EFI_ACPI_4_0_LOCAL_APIC_NMI;
> - LocalApciNmiStruct.Length = sizeof
> (EFI_ACPI_4_0_LOCAL_APIC_NMI_STRUCTURE);
> - LocalApciNmiStruct.AcpiProcessorId = 0xFF; // Applies to all processors
> - LocalApciNmiStruct.Flags = 0x0005; // Flags - Edge-tiggered, Active
> High
> - LocalApciNmiStruct.LocalApicLint = 0x1;
> + LocalApciNmiStruct.Type = EFI_ACPI_6_3_LOCAL_APIC_NMI;
> + LocalApciNmiStruct.Length = sizeof
> (EFI_ACPI_6_3_LOCAL_APIC_NMI_STRUCTURE);
> + LocalApciNmiStruct.AcpiProcessorUid = 0xFF; // Applies to all processors
> + LocalApciNmiStruct.Flags = 0x0005; // Flags - Edge-tiggered, Active
> High
> + LocalApciNmiStruct.LocalApicLint = 0x1;
>
> ASSERT (MadtStructsIndex < MaxMadtStructCount);
> Status = CopyStructure (
> @@ -967,8 +968,8 @@ InstallMadtFromScratch (
> // Build Local x2APIC NMI Structure
> //
> if (mX2ApicEnabled) {
> - LocalX2ApicNmiStruct.Type = EFI_ACPI_4_0_LOCAL_X2APIC_NMI;
> - LocalX2ApicNmiStruct.Length = sizeof
> (EFI_ACPI_4_0_LOCAL_X2APIC_NMI_STRUCTURE);
> + LocalX2ApicNmiStruct.Type = EFI_ACPI_6_3_LOCAL_X2APIC_NMI;
> + LocalX2ApicNmiStruct.Length = sizeof
> + (EFI_ACPI_6_3_LOCAL_X2APIC_NMI_STRUCTURE);
> LocalX2ApicNmiStruct.Flags = 0x000D; // Flags - Level-tiggered,
> Active High
> LocalX2ApicNmiStruct.AcpiProcessorUid = 0xFFFFFFFF; // Applies to all
> processors
> LocalX2ApicNmiStruct.LocalX2ApicLint = 0x01; @@ -992,12 +993,12 @@
> InstallMadtFromScratch (
> // Build Madt Structure from the Madt Header and collection of pointers in
> MadtStructs[]
> //
> Status = BuildAcpiTable (
> - (EFI_ACPI_DESCRIPTION_HEADER *) &MadtTableHeader,
> - sizeof
> (EFI_ACPI_4_0_MULTIPLE_APIC_DESCRIPTION_TABLE_HEADER),
> - MadtStructs,
> - MadtStructsIndex,
> - (UINT8 **) &NewMadtTable
> - );
> + (EFI_ACPI_DESCRIPTION_HEADER *) &MadtTableHeader,
> + sizeof
> (EFI_ACPI_6_3_MULTIPLE_APIC_DESCRIPTION_TABLE_HEADER),
> + MadtStructs,
> + MadtStructsIndex,
> + (UINT8 **)&NewMadtTable
> + );
> if (EFI_ERROR (Status)) {
> DEBUG ((DEBUG_ERROR, "BuildAcpiTable failed: %r\n", Status));
> goto Done;
> @@ -1087,7 +1088,7 @@ InstallMcfgFromScratch (
> }
>
> //
> - // Publish Madt Structure to ACPI
> + // Publish Mcfg Structure to ACPI
> //
> Status = mAcpiTable->InstallAcpiTable (
> mAcpiTable,
> @@ -1120,7 +1121,7 @@ PlatformUpdateTables (
> EFI_ACPI_DESCRIPTION_HEADER *TableHeader;
> UINT8 *TempOemId;
> UINT64 TempOemTableId;
> - EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE *FadtHeader;
> + EFI_ACPI_6_3_FIXED_ACPI_DESCRIPTION_TABLE *FadtHeader;
> EFI_ACPI_HIGH_PRECISION_EVENT_TIMER_TABLE_HEADER *HpetTable;
> UINT32 HpetBaseAddress;
> EFI_ACPI_HIGH_PRECISION_EVENT_TIMER_BLOCK_ID HpetBlockId;
> @@ -1177,12 +1178,12 @@ PlatformUpdateTables (
> //
> switch (Table->Signature) {
>
> - case EFI_ACPI_4_0_MULTIPLE_APIC_DESCRIPTION_TABLE_SIGNATURE:
> - ASSERT (FALSE);
> + case EFI_ACPI_6_3_MULTIPLE_APIC_DESCRIPTION_TABLE_SIGNATURE:
> + ASSERT(FALSE);
> break;
>
> - case EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE_SIGNATURE:
> - FadtHeader = (EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE *)
> Table;
> + case EFI_ACPI_6_3_FIXED_ACPI_DESCRIPTION_TABLE_SIGNATURE:
> + FadtHeader = (EFI_ACPI_6_3_FIXED_ACPI_DESCRIPTION_TABLE *) Table;
>
> FadtHeader->PreferredPmProfile = PcdGet8
> (PcdFadtPreferredPmProfile);
> FadtHeader->IaPcBootArch = PcdGet16 (PcdFadtIaPcBootArch);
> @@ -1228,7 +1229,7 @@ PlatformUpdateTables (
> DEBUG ((DEBUG_INFO, " Flags 0x%x\n", FadtHeader->Flags));
> break;
>
> - case EFI_ACPI_3_0_HIGH_PRECISION_EVENT_TIMER_TABLE_SIGNATURE:
> + case EFI_ACPI_6_3_HIGH_PRECISION_EVENT_TIMER_TABLE_SIGNATURE:
> HpetTable = (EFI_ACPI_HIGH_PRECISION_EVENT_TIMER_TABLE_HEADER
> *)Table;
> HpetBaseAddress = PcdGet32 (PcdHpetBaseAddress);
> HpetTable->BaseAddressLower32Bit.Address = HpetBaseAddress; @@ -
> 1280,8 +1281,8 @@ IsHardwareChange (
> UINTN HWChangeSize;
> UINT32 PciId;
> UINTN Handle;
> - EFI_ACPI_2_0_FIRMWARE_ACPI_CONTROL_STRUCTURE *FacsPtr;
> - EFI_ACPI_3_0_FIXED_ACPI_DESCRIPTION_TABLE *pFADT;
> + EFI_ACPI_6_3_FIRMWARE_ACPI_CONTROL_STRUCTURE *FacsPtr;
> + EFI_ACPI_6_3_FIXED_ACPI_DESCRIPTION_TABLE *pFADT;
>
> HandleCount = 0;
> HandleBuffer = NULL;
> @@ -1327,7 +1328,7 @@ IsHardwareChange (
> //
> Handle = 0;
> Status = LocateAcpiTableBySignature (
> - EFI_ACPI_1_0_FIXED_ACPI_DESCRIPTION_TABLE_SIGNATURE,
> + EFI_ACPI_6_3_FIXED_ACPI_DESCRIPTION_TABLE_SIGNATURE,
> (EFI_ACPI_DESCRIPTION_HEADER **) &pFADT,
> &Handle
> );
> @@ -1349,7 +1350,7 @@ IsHardwareChange (
> //
> // Set HardwareSignature value based on CRC value.
> //
> - FacsPtr = (EFI_ACPI_2_0_FIRMWARE_ACPI_CONTROL_STRUCTURE
> *)(UINTN)pFADT->FirmwareCtrl;
> + FacsPtr = (EFI_ACPI_6_3_FIRMWARE_ACPI_CONTROL_STRUCTURE
> + *)(UINTN)pFADT->FirmwareCtrl;
> FacsPtr->HardwareSignature = CRC;
> FreePool (HWChange);
> }
> diff --git a/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/Facs/Facs.c
> b/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/Facs/Facs.c
> index cde6e478c6b9..8700c44e633d 100644
> --- a/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/Facs/Facs.c
> +++ b/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/Facs/Facs.c
> @@ -1,9 +1,10 @@
> /** @file
> - This file contains a structure definition for the ACPI 5.0 Firmware ACPI
> + This file contains a structure definition for the ACPI 6.3 Firmware
> + ACPI
> Control Structure (FACS). The contents of this file should only be modified
> for bug fixes, no porting is required.
>
> Copyright (c) 2017, Intel Corporation. All rights reserved.<BR>
> +Copyright (c) Microsoft Corporation.<BR>
> SPDX-License-Identifier: BSD-2-Clause-Patent
>
> **/
> @@ -35,9 +36,9 @@ SPDX-License-Identifier: BSD-2-Clause-Patent // Please
> modify all values in Facs.h only.
> //
>
> -EFI_ACPI_5_0_FIRMWARE_ACPI_CONTROL_STRUCTURE Facs = {
> - EFI_ACPI_5_0_FIRMWARE_ACPI_CONTROL_STRUCTURE_SIGNATURE,
> - sizeof (EFI_ACPI_5_0_FIRMWARE_ACPI_CONTROL_STRUCTURE),
> +EFI_ACPI_6_3_FIRMWARE_ACPI_CONTROL_STRUCTURE Facs = {
> + EFI_ACPI_6_3_FIRMWARE_ACPI_CONTROL_STRUCTURE_SIGNATURE,
> + sizeof (EFI_ACPI_6_3_FIRMWARE_ACPI_CONTROL_STRUCTURE),
>
> //
> // Hardware Signature will be updated at runtime @@ -48,7 +49,7 @@
> EFI_ACPI_5_0_FIRMWARE_ACPI_CONTROL_STRUCTURE Facs = {
> EFI_ACPI_GLOBAL_LOCK,
> EFI_ACPI_FIRMWARE_CONTROL_STRUCTURE_FLAGS,
> EFI_ACPI_X_FIRMWARE_WAKING_VECTOR,
> - EFI_ACPI_5_0_FIRMWARE_ACPI_CONTROL_STRUCTURE_VERSION,
> + EFI_ACPI_6_3_FIRMWARE_ACPI_CONTROL_STRUCTURE_VERSION,
> {
> EFI_ACPI_RESERVED_BYTE,
> EFI_ACPI_RESERVED_BYTE,
> diff --git a/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/Fadt/Fadt.c
> b/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/Fadt/Fadt.c
> index 6efb38cda40d..3418e960972f 100644
> --- a/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/Fadt/Fadt.c
> +++ b/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/Fadt/Fadt.c
> @@ -1,9 +1,10 @@
> /** @file
> - This file contains a structure definition for the ACPI 5.0 Fixed ACPI
> + This file contains a structure definition for the ACPI 6.3 Fixed ACPI
> Description Table (FADT). The contents of this file should only be modified
> for bug fixes, no porting is required.
>
> Copyright (c) 2017, Intel Corporation. All rights reserved.<BR>
> +Copyright (c) Microsoft Corporation.<BR>
> SPDX-License-Identifier: BSD-2-Clause-Patent
>
> **/
> @@ -44,9 +45,13 @@ SPDX-License-Identifier: BSD-2-Clause-Patent // // IA-
> PC Boot Architecture Flags //
> -
> #define EFI_ACPI_IAPC_BOOT_ARCH 0 // To be fixed
>
> +//
> +// ARM Boot Architecture Flags
> +//
> +#define EFI_ACPI_ARM_BOOT_ARCH 0 // To be fixed
> +
> //
> // Fixed Feature Flags
> //
> @@ -55,7 +60,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent // //
> PM1A Event Register Block Generic Address Information // -#define
> EFI_ACPI_PM1A_EVT_BLK_ADDRESS_SPACE_ID EFI_ACPI_2_0_SYSTEM_IO
> +#define EFI_ACPI_PM1A_EVT_BLK_ADDRESS_SPACE_ID
> EFI_ACPI_6_3_SYSTEM_IO
> #define EFI_ACPI_PM1A_EVT_BLK_BIT_WIDTH 0x20
> #define EFI_ACPI_PM1A_EVT_BLK_BIT_OFFSET 0x00
> #define EFI_ACPI_PM1A_EVT_BLK_ADDRESS 0 // To be fixed
> @@ -63,7 +68,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent // //
> PM1B Event Register Block Generic Address Information // -#define
> EFI_ACPI_PM1B_EVT_BLK_ADDRESS_SPACE_ID EFI_ACPI_2_0_SYSTEM_IO
> +#define EFI_ACPI_PM1B_EVT_BLK_ADDRESS_SPACE_ID
> EFI_ACPI_6_3_SYSTEM_IO
> #define EFI_ACPI_PM1B_EVT_BLK_BIT_WIDTH 0x00
> #define EFI_ACPI_PM1B_EVT_BLK_BIT_OFFSET 0x00
> #define EFI_ACPI_PM1B_EVT_BLK_ADDRESS 0 // To be fixed
> @@ -71,7 +76,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent // //
> PM1A Control Register Block Generic Address Information // -#define
> EFI_ACPI_PM1A_CNT_BLK_ADDRESS_SPACE_ID EFI_ACPI_2_0_SYSTEM_IO
> +#define EFI_ACPI_PM1A_CNT_BLK_ADDRESS_SPACE_ID
> EFI_ACPI_6_3_SYSTEM_IO
> #define EFI_ACPI_PM1A_CNT_BLK_BIT_WIDTH 0x10
> #define EFI_ACPI_PM1A_CNT_BLK_BIT_OFFSET 0x00
> #define EFI_ACPI_PM1A_CNT_BLK_ADDRESS 0 // To be fixed
> @@ -79,7 +84,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent // //
> PM1B Control Register Block Generic Address Information // -#define
> EFI_ACPI_PM1B_CNT_BLK_ADDRESS_SPACE_ID EFI_ACPI_2_0_SYSTEM_IO
> +#define EFI_ACPI_PM1B_CNT_BLK_ADDRESS_SPACE_ID
> EFI_ACPI_6_3_SYSTEM_IO
> #define EFI_ACPI_PM1B_CNT_BLK_BIT_WIDTH 0x00
> #define EFI_ACPI_PM1B_CNT_BLK_BIT_OFFSET 0x00
> #define EFI_ACPI_PM1B_CNT_BLK_ADDRESS 0 // To be fixed
> @@ -87,7 +92,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent // //
> PM2 Control Register Block Generic Address Information // -#define
> EFI_ACPI_PM2_CNT_BLK_ADDRESS_SPACE_ID EFI_ACPI_2_0_SYSTEM_IO
> +#define EFI_ACPI_PM2_CNT_BLK_ADDRESS_SPACE_ID
> EFI_ACPI_6_3_SYSTEM_IO
> #define EFI_ACPI_PM2_CNT_BLK_BIT_WIDTH 0x08
> #define EFI_ACPI_PM2_CNT_BLK_BIT_OFFSET 0x00
> #define EFI_ACPI_PM2_CNT_BLK_ADDRESS 0 // To be fixed
> @@ -96,7 +101,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent //
> Power Management Timer Control Register Block Generic Address //
> Information // -#define EFI_ACPI_PM_TMR_BLK_ADDRESS_SPACE_ID
> EFI_ACPI_2_0_SYSTEM_IO
> +#define EFI_ACPI_PM_TMR_BLK_ADDRESS_SPACE_ID
> EFI_ACPI_6_3_SYSTEM_IO
> #define EFI_ACPI_PM_TMR_BLK_BIT_WIDTH 0x20
> #define EFI_ACPI_PM_TMR_BLK_BIT_OFFSET 0x00
> #define EFI_ACPI_PM_TMR_BLK_ADDRESS 0 // To be fixed
> @@ -105,7 +110,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent //
> General Purpose Event 0 Register Block Generic Address // Information // -
> #define EFI_ACPI_GPE0_BLK_ADDRESS_SPACE_ID
> EFI_ACPI_2_0_SYSTEM_IO
> +#define EFI_ACPI_GPE0_BLK_ADDRESS_SPACE_ID
> EFI_ACPI_6_3_SYSTEM_IO
> #define EFI_ACPI_GPE0_BLK_BIT_WIDTH 0 // size of
> R_PCH_ACPI_GPE0_STS_127_96 + R_PCH_ACPI_GPE0_EN_127_96
> #define EFI_ACPI_GPE0_BLK_BIT_OFFSET 0x00
> #define EFI_ACPI_GPE0_BLK_ADDRESS 0 // To be fixed
> @@ -114,14 +119,14 @@ SPDX-License-Identifier: BSD-2-Clause-Patent //
> General Purpose Event 1 Register Block Generic Address // Information // -
> #define EFI_ACPI_GPE1_BLK_ADDRESS_SPACE_ID
> EFI_ACPI_2_0_SYSTEM_IO
> +#define EFI_ACPI_GPE1_BLK_ADDRESS_SPACE_ID
> EFI_ACPI_6_3_SYSTEM_IO
> #define EFI_ACPI_GPE1_BLK_BIT_WIDTH 0x0
> #define EFI_ACPI_GPE1_BLK_BIT_OFFSET 0x0
> #define EFI_ACPI_GPE1_BLK_ADDRESS 0 // To be fixed
> //
> // Reset Register Generic Address Information // -#define
> EFI_ACPI_RESET_REG_ADDRESS_SPACE_ID EFI_ACPI_2_0_SYSTEM_IO
> +#define EFI_ACPI_RESET_REG_ADDRESS_SPACE_ID
> EFI_ACPI_6_3_SYSTEM_IO
> #define EFI_ACPI_RESET_REG_BIT_WIDTH 0x08
> #define EFI_ACPI_RESET_REG_BIT_OFFSET 0x00
> #define EFI_ACPI_RESET_REG_ADDRESS 0x00000CF9
> @@ -162,11 +167,11 @@ SPDX-License-Identifier: BSD-2-Clause-Patent //
> Please modify all values in Fadt.h only.
> //
>
> -EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE Fadt = {
> +EFI_ACPI_6_3_FIXED_ACPI_DESCRIPTION_TABLE Fadt = {
> {
> - EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE_SIGNATURE,
> - sizeof (EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE),
> - EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE_REVISION,
> + EFI_ACPI_6_3_FIXED_ACPI_DESCRIPTION_TABLE_SIGNATURE,
> + sizeof (EFI_ACPI_6_3_FIXED_ACPI_DESCRIPTION_TABLE),
> + EFI_ACPI_6_3_FIXED_ACPI_DESCRIPTION_TABLE_REVISION,
>
> //
> // Checksum will be updated at runtime @@ -187,9 +192,9 @@
> EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE Fadt = {
> //
> // These addresses will be updated at runtime
> //
> - 0x00000000,
> 0x00000000,
> -
> + 0x00000000,
> +
> EFI_ACPI_RESERVED_BYTE,
> EFI_ACPI_PREFERRED_PM_PROFILE,
> EFI_ACPI_SCI_INT,
> @@ -198,7 +203,7 @@ EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE
> Fadt = {
> EFI_ACPI_ACPI_DISABLE,
> EFI_ACPI_S4_BIOS_REQ,
> EFI_ACPI_PSTATE_CNT,
> -
> +
> EFI_ACPI_PM1A_EVT_BLK_ADDRESS,
> EFI_ACPI_PM1B_EVT_BLK_ADDRESS,
> EFI_ACPI_PM1A_CNT_BLK_ADDRESS,
> @@ -240,15 +245,13 @@ EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE
> Fadt = {
> EFI_ACPI_RESET_REG_ADDRESS_SPACE_ID,
> EFI_ACPI_RESET_REG_BIT_WIDTH,
> EFI_ACPI_RESET_REG_BIT_OFFSET,
> - EFI_ACPI_5_0_BYTE,
> + EFI_ACPI_6_3_BYTE,
> EFI_ACPI_RESET_REG_ADDRESS
> },
> EFI_ACPI_RESET_VALUE,
> - {
> - EFI_ACPI_RESERVED_BYTE,
> - EFI_ACPI_RESERVED_BYTE,
> - EFI_ACPI_RESERVED_BYTE
> - },
> +
> + EFI_ACPI_ARM_BOOT_ARCH,
> + EFI_ACPI_6_3_FIXED_ACPI_DESCRIPTION_TABLE_MINOR_REVISION,
>
> //
> // These addresses will be updated at runtime @@ -263,7 +266,7 @@
> EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE Fadt = {
> EFI_ACPI_PM1A_EVT_BLK_ADDRESS_SPACE_ID,
> EFI_ACPI_PM1A_EVT_BLK_BIT_WIDTH,
> EFI_ACPI_PM1A_EVT_BLK_BIT_OFFSET,
> - EFI_ACPI_5_0_WORD,
> + EFI_ACPI_6_3_WORD,
> EFI_ACPI_PM1A_EVT_BLK_ADDRESS
> },
> {
> @@ -273,7 +276,7 @@ EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE
> Fadt = {
> EFI_ACPI_PM1B_EVT_BLK_ADDRESS_SPACE_ID,
> EFI_ACPI_PM1B_EVT_BLK_BIT_WIDTH,
> EFI_ACPI_PM1B_EVT_BLK_BIT_OFFSET,
> - EFI_ACPI_5_0_WORD,
> + EFI_ACPI_6_3_WORD,
> EFI_ACPI_PM1B_EVT_BLK_ADDRESS
> },
> {
> @@ -283,7 +286,7 @@ EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE
> Fadt = {
> EFI_ACPI_PM1A_CNT_BLK_ADDRESS_SPACE_ID,
> EFI_ACPI_PM1A_CNT_BLK_BIT_WIDTH,
> EFI_ACPI_PM1A_CNT_BLK_BIT_OFFSET,
> - EFI_ACPI_5_0_WORD,
> + EFI_ACPI_6_3_WORD,
> EFI_ACPI_PM1A_CNT_BLK_ADDRESS
> },
> {
> @@ -293,7 +296,7 @@ EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE
> Fadt = {
> EFI_ACPI_PM1B_CNT_BLK_ADDRESS_SPACE_ID,
> EFI_ACPI_PM1B_CNT_BLK_BIT_WIDTH,
> EFI_ACPI_PM1B_CNT_BLK_BIT_OFFSET,
> - EFI_ACPI_5_0_WORD,
> + EFI_ACPI_6_3_WORD,
> EFI_ACPI_PM1B_CNT_BLK_ADDRESS
> },
> {
> @@ -303,7 +306,7 @@ EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE
> Fadt = {
> EFI_ACPI_PM2_CNT_BLK_ADDRESS_SPACE_ID,
> EFI_ACPI_PM2_CNT_BLK_BIT_WIDTH,
> EFI_ACPI_PM2_CNT_BLK_BIT_OFFSET,
> - EFI_ACPI_5_0_BYTE,
> + EFI_ACPI_6_3_BYTE,
> EFI_ACPI_PM2_CNT_BLK_ADDRESS
> },
> {
> @@ -313,7 +316,7 @@ EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE
> Fadt = {
> EFI_ACPI_PM_TMR_BLK_ADDRESS_SPACE_ID,
> EFI_ACPI_PM_TMR_BLK_BIT_WIDTH,
> EFI_ACPI_PM_TMR_BLK_BIT_OFFSET,
> - EFI_ACPI_5_0_DWORD,
> + EFI_ACPI_6_3_DWORD,
> EFI_ACPI_PM_TMR_BLK_ADDRESS
> },
> {
> @@ -323,7 +326,7 @@ EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE
> Fadt = {
> EFI_ACPI_GPE0_BLK_ADDRESS_SPACE_ID,
> EFI_ACPI_GPE0_BLK_BIT_WIDTH,
> EFI_ACPI_GPE0_BLK_BIT_OFFSET,
> - EFI_ACPI_5_0_BYTE,
> + EFI_ACPI_6_3_BYTE,
> EFI_ACPI_GPE0_BLK_ADDRESS
> },
> {
> @@ -333,7 +336,7 @@ EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE
> Fadt = {
> EFI_ACPI_GPE1_BLK_ADDRESS_SPACE_ID,
> EFI_ACPI_GPE1_BLK_BIT_WIDTH,
> EFI_ACPI_GPE1_BLK_BIT_OFFSET,
> - EFI_ACPI_5_0_BYTE,
> + EFI_ACPI_6_3_BYTE,
> EFI_ACPI_GPE1_BLK_ADDRESS
> },
> {
> @@ -355,5 +358,10 @@ EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE
> Fadt = {
> 0,
> 0,
> 0
> - }
> + },
> +
> + //
> + // Hypervisor Vendor Identity
> + //
> + 0x0000000000000000,
> };
> --
> 2.28.0.windows.1
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [edk2-platforms][PATCH v2 1/1] MinPlatformPkg/AcpiTables: Update structures for ACPI 6.3
2021-09-24 18:22 [edk2-platforms][PATCH v2 1/1] MinPlatformPkg/AcpiTables: Update structures for ACPI 6.3 Michael Kubacki
2021-10-02 1:13 ` Nate DeSimone
@ 2021-10-02 1:14 ` Nate DeSimone
1 sibling, 0 replies; 3+ messages in thread
From: Nate DeSimone @ 2021-10-02 1:14 UTC (permalink / raw)
To: mikuback@linux.microsoft.com, devel@edk2.groups.io
Cc: Chiu, Chasel, Liming Gao, Dong, Eric, Maddy, Daniel,
Michael Kubacki
Pushed: https://github.com/tianocore/edk2-platforms/commit/bbb431a
> -----Original Message-----
> From: mikuback@linux.microsoft.com <mikuback@linux.microsoft.com>
> Sent: Friday, September 24, 2021 11:23 AM
> To: devel@edk2.groups.io
> Cc: Chiu, Chasel <chasel.chiu@intel.com>; Desimone, Nathaniel L
> <nathaniel.l.desimone@intel.com>; Liming Gao
> <gaoliming@byosoft.com.cn>; Dong, Eric <eric.dong@intel.com>; Maddy,
> Daniel <danmad@microsoft.com>; Michael Kubacki
> <michael.kubacki@microsoft.com>
> Subject: [edk2-platforms][PATCH v2 1/1] MinPlatformPkg/AcpiTables:
> Update structures for ACPI 6.3
>
> From: Daniel Maddy <danmad@microsoft.com>
>
> REF:https://bugzilla.tianocore.org/show_bug.cgi?id=3535
>
> Updates ACPI table structures in MinPlatformPkg for ACPI 6.3.
>
> Cc: Chasel Chiu <chasel.chiu@intel.com>
> Cc: Nate DeSimone <nathaniel.l.desimone@intel.com>
> Cc: Liming Gao <gaoliming@byosoft.com.cn>
> Cc: Eric Dong <eric.dong@intel.com>
> Cc: Daniel Maddy <danmad@microsoft.com>
> Co-authored-by: Michael Kubacki <michael.kubacki@microsoft.com>
> Signed-off-by: Michael Kubacki <michael.kubacki@microsoft.com>
> Reviewed-by: Nate DeSimone <nathaniel.l.desimone@intel.com>
> ---
> Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/AcpiPlatform.c | 181
> ++++++++++----------
> Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/Facs/Facs.c | 11 +-
> Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/Fadt/Fadt.c | 74 ++++----
> 3 files changed, 138 insertions(+), 128 deletions(-)
>
> diff --git a/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/AcpiPlatform.c
> b/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/AcpiPlatform.c
> index 843ba832ce67..f5c4f2c3f1a9 100644
> --- a/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/AcpiPlatform.c
> +++ b/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/AcpiPlatform.c
> @@ -2,6 +2,7 @@
> ACPI Platform Driver
>
> Copyright (c) 2017 - 2021, Intel Corporation. All rights reserved.<BR>
> +Copyright (c) Microsoft Corporation.<BR>
> SPDX-License-Identifier: BSD-2-Clause-Patent
>
> **/
> @@ -11,7 +12,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent #pragma
> pack(1)
>
> typedef struct {
> - UINT32 AcpiProcessorId;
> + UINT32 AcpiProcessorUid;
> UINT32 ApicId;
> UINT32 Flags;
> UINT32 SocketNum;
> @@ -25,9 +26,9 @@ typedef struct {
> // Define Union of IO APIC & Local APIC structure; // typedef union {
> - EFI_ACPI_4_0_PROCESSOR_LOCAL_APIC_STRUCTURE AcpiLocalApic;
> - EFI_ACPI_4_0_IO_APIC_STRUCTURE AcpiIoApic;
> - EFI_ACPI_4_0_PROCESSOR_LOCAL_X2APIC_STRUCTURE AcpiLocalx2Apic;
> + EFI_ACPI_6_3_PROCESSOR_LOCAL_APIC_STRUCTURE AcpiLocalApic;
> + EFI_ACPI_6_3_IO_APIC_STRUCTURE AcpiIoApic;
> + EFI_ACPI_6_3_PROCESSOR_LOCAL_X2APIC_STRUCTURE AcpiLocalx2Apic;
> struct {
> UINT8 Type;
> UINT8 Length;
> @@ -36,9 +37,9 @@ typedef union {
>
> #pragma pack()
>
> -extern EFI_ACPI_5_0_FIRMWARE_ACPI_CONTROL_STRUCTURE Facs; -
> extern EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE Fadt; -extern
> EFI_ACPI_HIGH_PRECISION_EVENT_TIMER_TABLE_HEADER Hpet;
> +extern EFI_ACPI_6_3_FIRMWARE_ACPI_CONTROL_STRUCTURE Facs;
> +extern EFI_ACPI_6_3_FIXED_ACPI_DESCRIPTION_TABLE Fadt;
> +extern EFI_ACPI_HIGH_PRECISION_EVENT_TIMER_TABLE_HEADER Hpet;
> extern EFI_ACPI_WSMT_TABLE Wsmt;
>
> VOID *mLocalTable[] = {
> @@ -103,7 +104,7 @@ DebugDisplayReOrderTable (
> for (Index = 0; Index < mNumberOfCpus; Index++) {
> DEBUG ((DEBUG_INFO, " %02d 0x%02X 0x%02X %d %d
> %d\n",
> Index,
> - CpuApicIdOrderTable[Index].AcpiProcessorId,
> + CpuApicIdOrderTable[Index].AcpiProcessorUid,
> CpuApicIdOrderTable[Index].ApicId,
> CpuApicIdOrderTable[Index].Thread,
> CpuApicIdOrderTable[Index].Flags, @@ -118,31 +119,31 @@
> AppendCpuMapTableEntry (
> )
> {
> EFI_STATUS Status;
> - EFI_ACPI_4_0_PROCESSOR_LOCAL_APIC_STRUCTURE *LocalApicPtr;
> - EFI_ACPI_4_0_PROCESSOR_LOCAL_X2APIC_STRUCTURE *LocalX2ApicPtr;
> + EFI_ACPI_6_3_PROCESSOR_LOCAL_APIC_STRUCTURE *LocalApicPtr;
> + EFI_ACPI_6_3_PROCESSOR_LOCAL_X2APIC_STRUCTURE *LocalX2ApicPtr;
> UINT8 Type;
>
> Status = EFI_SUCCESS;
> Type = ((ACPI_APIC_STRUCTURE_PTR *)ApicPtr)->AcpiApicCommon.Type;
> - LocalApicPtr = (EFI_ACPI_4_0_PROCESSOR_LOCAL_APIC_STRUCTURE
> *)(&((ACPI_APIC_STRUCTURE_PTR *)ApicPtr)->AcpiLocalApic);
> - LocalX2ApicPtr = (EFI_ACPI_4_0_PROCESSOR_LOCAL_X2APIC_STRUCTURE
> *)(&((ACPI_APIC_STRUCTURE_PTR *)ApicPtr)->AcpiLocalx2Apic);
> + LocalApicPtr = (EFI_ACPI_6_3_PROCESSOR_LOCAL_APIC_STRUCTURE
> + *)(&((ACPI_APIC_STRUCTURE_PTR *)ApicPtr)->AcpiLocalApic);
> + LocalX2ApicPtr = (EFI_ACPI_6_3_PROCESSOR_LOCAL_X2APIC_STRUCTURE
> + *)(&((ACPI_APIC_STRUCTURE_PTR *)ApicPtr)->AcpiLocalx2Apic);
>
> - if(Type == EFI_ACPI_4_0_PROCESSOR_LOCAL_APIC) {
> + if(Type == EFI_ACPI_6_3_PROCESSOR_LOCAL_APIC) {
> if(!mX2ApicEnabled) {
> - LocalApicPtr->Flags =
> (UINT8)mCpuApicIdOrderTable[LocalApicCounter].Flags;
> - LocalApicPtr->ApicId =
> (UINT8)mCpuApicIdOrderTable[LocalApicCounter].ApicId;
> - LocalApicPtr->AcpiProcessorId =
> (UINT8)mCpuApicIdOrderTable[LocalApicCounter].AcpiProcessorId;
> + LocalApicPtr->Flags =
> (UINT8)mCpuApicIdOrderTable[LocalApicCounter].Flags;
> + LocalApicPtr->ApicId =
> (UINT8)mCpuApicIdOrderTable[LocalApicCounter].ApicId;
> + LocalApicPtr->AcpiProcessorUid =
> + (UINT8)mCpuApicIdOrderTable[LocalApicCounter].AcpiProcessorUid;
> } else {
> - LocalApicPtr->Flags = 0;
> - LocalApicPtr->ApicId = 0xFF;
> - LocalApicPtr->AcpiProcessorId = (UINT8)0xFF;
> + LocalApicPtr->Flags = 0;
> + LocalApicPtr->ApicId = 0xFF;
> + LocalApicPtr->AcpiProcessorUid = (UINT8)0xFF;
> Status = EFI_UNSUPPORTED;
> }
> - } else if(Type == EFI_ACPI_4_0_PROCESSOR_LOCAL_X2APIC) {
> + } else if(Type == EFI_ACPI_6_3_PROCESSOR_LOCAL_X2APIC) {
> if(mX2ApicEnabled) {
> LocalX2ApicPtr->Flags =
> (UINT8)mCpuApicIdOrderTable[LocalApicCounter].Flags;
> LocalX2ApicPtr->X2ApicId =
> mCpuApicIdOrderTable[LocalApicCounter].ApicId;
> - LocalX2ApicPtr->AcpiProcessorUid =
> mCpuApicIdOrderTable[LocalApicCounter].AcpiProcessorId;
> + LocalX2ApicPtr->AcpiProcessorUid =
> + mCpuApicIdOrderTable[LocalApicCounter].AcpiProcessorUid;
> } else {
> LocalX2ApicPtr->Flags = 0;
> LocalX2ApicPtr->X2ApicId = (UINT32)-1;
> @@ -201,15 +202,15 @@ SortCpuLocalApicInTable (
> //update processorbitMask
> if (CpuIdMapPtr->Flags == 1) {
> if (mForceX2ApicId) {
> - CpuIdMapPtr->SocketNum &= 0x7;
> - CpuIdMapPtr->AcpiProcessorId &= 0xFF; //keep lower 8bit due to use
> Proc obj in dsdt
> + CpuIdMapPtr->SocketNum &= 0x7;
> + CpuIdMapPtr->AcpiProcessorUid &= 0xFF; //keep lower 8bit due
> + to use Proc obj in dsdt
> }
> }
> } else { //not enabled
> - CpuIdMapPtr->ApicId = (UINT32)-1;
> - CpuIdMapPtr->Thread = (UINT32)-1;
> - CpuIdMapPtr->Flags = 0;
> - CpuIdMapPtr->SocketNum = (UINT32)-1;
> + CpuIdMapPtr->ApicId = (UINT32)-1;
> + CpuIdMapPtr->Thread = (UINT32)-1;
> + CpuIdMapPtr->Flags = 0;
> + CpuIdMapPtr->SocketNum = (UINT32)-1;
> } //end if PROC ENABLE
> } //end for CurrentProcessor
>
> @@ -280,12 +281,12 @@ SortCpuLocalApicInTable (
> }
>
> //
> - // 5. Re-assigen AcpiProcessorId for AcpiProcessorUId uses purpose.
> + // 5. Re-assign AcpiProcessorId for AcpiProcessorUid uses purpose.
> //
> for (Socket = 0; Socket < FixedPcdGet32 (PcdMaxCpuSocketCount);
> Socket++) {
> for (CurrProcessor = 0, Index = 0; CurrProcessor < mNumberOfCpus;
> CurrProcessor++) {
> if (mCpuApicIdOrderTable[CurrProcessor].Flags &&
> (mCpuApicIdOrderTable[CurrProcessor].SocketNum == Socket)) {
> - mCpuApicIdOrderTable[CurrProcessor].AcpiProcessorId =
> (ProcessorInfoBuffer.Location.Package << mNumOfBitShift) + Index;
> + mCpuApicIdOrderTable[CurrProcessor].AcpiProcessorUid =
> + (ProcessorInfoBuffer.Location.Package << mNumOfBitShift) + Index;
> Index++;
> }
> }
> @@ -312,17 +313,17 @@ typedef struct {
> } STRUCTURE_HEADER;
>
> STRUCTURE_HEADER mMadtStructureTable[] = {
> - {EFI_ACPI_4_0_PROCESSOR_LOCAL_APIC, sizeof
> (EFI_ACPI_4_0_PROCESSOR_LOCAL_APIC_STRUCTURE)},
> - {EFI_ACPI_4_0_IO_APIC, sizeof
> (EFI_ACPI_4_0_IO_APIC_STRUCTURE)},
> - {EFI_ACPI_4_0_INTERRUPT_SOURCE_OVERRIDE, sizeof
> (EFI_ACPI_4_0_INTERRUPT_SOURCE_OVERRIDE_STRUCTURE)},
> - {EFI_ACPI_4_0_NON_MASKABLE_INTERRUPT_SOURCE, sizeof
> (EFI_ACPI_4_0_NON_MASKABLE_INTERRUPT_SOURCE_STRUCTURE)},
> - {EFI_ACPI_4_0_LOCAL_APIC_NMI, sizeof
> (EFI_ACPI_4_0_LOCAL_APIC_NMI_STRUCTURE)},
> - {EFI_ACPI_4_0_LOCAL_APIC_ADDRESS_OVERRIDE, sizeof
> (EFI_ACPI_4_0_LOCAL_APIC_ADDRESS_OVERRIDE_STRUCTURE)},
> - {EFI_ACPI_4_0_IO_SAPIC, sizeof
> (EFI_ACPI_4_0_IO_SAPIC_STRUCTURE)},
> - {EFI_ACPI_4_0_LOCAL_SAPIC, sizeof
> (EFI_ACPI_4_0_PROCESSOR_LOCAL_SAPIC_STRUCTURE)},
> - {EFI_ACPI_4_0_PLATFORM_INTERRUPT_SOURCES, sizeof
> (EFI_ACPI_4_0_PLATFORM_INTERRUPT_SOURCES_STRUCTURE)},
> - {EFI_ACPI_4_0_PROCESSOR_LOCAL_X2APIC, sizeof
> (EFI_ACPI_4_0_PROCESSOR_LOCAL_X2APIC_STRUCTURE)},
> - {EFI_ACPI_4_0_LOCAL_X2APIC_NMI, sizeof
> (EFI_ACPI_4_0_LOCAL_X2APIC_NMI_STRUCTURE)}
> + {EFI_ACPI_6_3_PROCESSOR_LOCAL_APIC, sizeof
> (EFI_ACPI_6_3_PROCESSOR_LOCAL_APIC_STRUCTURE)},
> + {EFI_ACPI_6_3_IO_APIC, sizeof
> (EFI_ACPI_6_3_IO_APIC_STRUCTURE)},
> + {EFI_ACPI_6_3_INTERRUPT_SOURCE_OVERRIDE, sizeof
> (EFI_ACPI_6_3_INTERRUPT_SOURCE_OVERRIDE_STRUCTURE)},
> + {EFI_ACPI_6_3_NON_MASKABLE_INTERRUPT_SOURCE, sizeof
> (EFI_ACPI_6_3_NON_MASKABLE_INTERRUPT_SOURCE_STRUCTURE)},
> + {EFI_ACPI_6_3_LOCAL_APIC_NMI, sizeof
> (EFI_ACPI_6_3_LOCAL_APIC_NMI_STRUCTURE)},
> + {EFI_ACPI_6_3_LOCAL_APIC_ADDRESS_OVERRIDE, sizeof
> (EFI_ACPI_6_3_LOCAL_APIC_ADDRESS_OVERRIDE_STRUCTURE)},
> + {EFI_ACPI_6_3_IO_SAPIC, sizeof
> (EFI_ACPI_6_3_IO_SAPIC_STRUCTURE)},
> + {EFI_ACPI_6_3_LOCAL_SAPIC, sizeof
> (EFI_ACPI_6_3_PROCESSOR_LOCAL_SAPIC_STRUCTURE)},
> + {EFI_ACPI_6_3_PLATFORM_INTERRUPT_SOURCES, sizeof
> (EFI_ACPI_6_3_PLATFORM_INTERRUPT_SOURCES_STRUCTURE)},
> + {EFI_ACPI_6_3_PROCESSOR_LOCAL_X2APIC, sizeof
> (EFI_ACPI_6_3_PROCESSOR_LOCAL_X2APIC_STRUCTURE)},
> + {EFI_ACPI_6_3_LOCAL_X2APIC_NMI, sizeof
> (EFI_ACPI_6_3_LOCAL_X2APIC_NMI_STRUCTURE)}
> };
>
> /**
> @@ -481,7 +482,7 @@ InitializeHeader (
> **/
> EFI_STATUS
> InitializeMadtHeader (
> - IN OUT EFI_ACPI_4_0_MULTIPLE_APIC_DESCRIPTION_TABLE_HEADER
> *MadtHeader
> + IN OUT EFI_ACPI_6_3_MULTIPLE_APIC_DESCRIPTION_TABLE_HEADER
> + *MadtHeader
> )
> {
> EFI_STATUS Status;
> @@ -493,8 +494,8 @@ InitializeMadtHeader (
>
> Status = InitializeHeader (
> &MadtHeader->Header,
> - EFI_ACPI_4_0_MULTIPLE_APIC_DESCRIPTION_TABLE_SIGNATURE,
> - EFI_ACPI_4_0_MULTIPLE_APIC_DESCRIPTION_TABLE_REVISION,
> + EFI_ACPI_6_3_MULTIPLE_APIC_DESCRIPTION_TABLE_SIGNATURE,
> + EFI_ACPI_6_3_MULTIPLE_APIC_DESCRIPTION_TABLE_REVISION,
> 0
> );
> if (EFI_ERROR (Status)) {
> @@ -502,7 +503,7 @@ InitializeMadtHeader (
> }
>
> MadtHeader->LocalApicAddress = PcdGet32(PcdLocalApicAddress);
> - MadtHeader->Flags = EFI_ACPI_4_0_PCAT_COMPAT;
> + MadtHeader->Flags = EFI_ACPI_6_3_PCAT_COMPAT;
>
> return EFI_SUCCESS;
> }
> @@ -539,7 +540,7 @@ CopyStructure (
> //
> // Initialize the number of table entries and the table based on the table
> header passed in.
> //
> - if (Header->Signature ==
> EFI_ACPI_4_0_MULTIPLE_APIC_DESCRIPTION_TABLE_SIGNATURE) {
> + if (Header->Signature ==
> + EFI_ACPI_6_3_MULTIPLE_APIC_DESCRIPTION_TABLE_SIGNATURE) {
> TableNumEntries = sizeof (mMadtStructureTable) / sizeof
> (STRUCTURE_HEADER);
> StructureTable = mMadtStructureTable;
> } else {
> @@ -649,7 +650,7 @@ BuildAcpiTable (
> return EFI_INVALID_PARAMETER;
> }
>
> - if (AcpiHeader->Signature !=
> EFI_ACPI_4_0_MULTIPLE_APIC_DESCRIPTION_TABLE_SIGNATURE) {
> + if (AcpiHeader->Signature !=
> + EFI_ACPI_6_3_MULTIPLE_APIC_DESCRIPTION_TABLE_SIGNATURE) {
> DEBUG ((
> DEBUG_ERROR,
> "MADT header signature is expected, actually 0x%08x\n", @@ -740,15
> +741,15 @@ InstallMadtFromScratch ( {
> EFI_STATUS Status;
> UINTN Index;
> - EFI_ACPI_4_0_MULTIPLE_APIC_DESCRIPTION_TABLE_HEADER
> *NewMadtTable;
> + EFI_ACPI_6_3_MULTIPLE_APIC_DESCRIPTION_TABLE_HEADER
> *NewMadtTable;
> UINTN TableHandle;
> - EFI_ACPI_4_0_MULTIPLE_APIC_DESCRIPTION_TABLE_HEADER
> MadtTableHeader;
> - EFI_ACPI_4_0_PROCESSOR_LOCAL_APIC_STRUCTURE
> ProcLocalApicStruct;
> - EFI_ACPI_4_0_IO_APIC_STRUCTURE IoApicStruct;
> - EFI_ACPI_4_0_INTERRUPT_SOURCE_OVERRIDE_STRUCTURE
> IntSrcOverrideStruct;
> - EFI_ACPI_4_0_LOCAL_APIC_NMI_STRUCTURE LocalApciNmiStruct;
> - EFI_ACPI_4_0_PROCESSOR_LOCAL_X2APIC_STRUCTURE
> ProcLocalX2ApicStruct;
> - EFI_ACPI_4_0_LOCAL_X2APIC_NMI_STRUCTURE
> LocalX2ApicNmiStruct;
> + EFI_ACPI_6_3_MULTIPLE_APIC_DESCRIPTION_TABLE_HEADER
> MadtTableHeader;
> + EFI_ACPI_6_3_PROCESSOR_LOCAL_APIC_STRUCTURE
> ProcLocalApicStruct;
> + EFI_ACPI_6_3_IO_APIC_STRUCTURE IoApicStruct;
> + EFI_ACPI_6_3_INTERRUPT_SOURCE_OVERRIDE_STRUCTURE
> IntSrcOverrideStruct;
> + EFI_ACPI_6_3_LOCAL_APIC_NMI_STRUCTURE LocalApciNmiStruct;
> + EFI_ACPI_6_3_PROCESSOR_LOCAL_X2APIC_STRUCTURE
> ProcLocalX2ApicStruct;
> + EFI_ACPI_6_3_LOCAL_X2APIC_NMI_STRUCTURE
> LocalX2ApicNmiStruct;
> STRUCTURE_HEADER **MadtStructs;
> UINTN MaxMadtStructCount;
> UINTN MadtStructsIndex;
> @@ -809,11 +810,11 @@ InstallMadtFromScratch (
> //
> // Build Processor Local APIC Structures and Processor Local X2APIC
> Structures
> //
> - ProcLocalApicStruct.Type = EFI_ACPI_4_0_PROCESSOR_LOCAL_APIC;
> - ProcLocalApicStruct.Length = sizeof
> (EFI_ACPI_4_0_PROCESSOR_LOCAL_APIC_STRUCTURE);
> + ProcLocalApicStruct.Type = EFI_ACPI_6_3_PROCESSOR_LOCAL_APIC;
> + ProcLocalApicStruct.Length = sizeof
> + (EFI_ACPI_6_3_PROCESSOR_LOCAL_APIC_STRUCTURE);
>
> - ProcLocalX2ApicStruct.Type = EFI_ACPI_4_0_PROCESSOR_LOCAL_X2APIC;
> - ProcLocalX2ApicStruct.Length = sizeof
> (EFI_ACPI_4_0_PROCESSOR_LOCAL_X2APIC_STRUCTURE);
> + ProcLocalX2ApicStruct.Type = EFI_ACPI_6_3_PROCESSOR_LOCAL_X2APIC;
> + ProcLocalX2ApicStruct.Length = sizeof
> + (EFI_ACPI_6_3_PROCESSOR_LOCAL_X2APIC_STRUCTURE);
> ProcLocalX2ApicStruct.Reserved[0] = 0;
> ProcLocalX2ApicStruct.Reserved[1] = 0;
>
> @@ -824,9 +825,9 @@ InstallMadtFromScratch (
> // use a processor local x2APIC structure.
> //
> if (!mX2ApicEnabled && mCpuApicIdOrderTable[Index].ApicId <
> MAX_UINT8) {
> - ProcLocalApicStruct.Flags = (UINT8)
> mCpuApicIdOrderTable[Index].Flags;
> - ProcLocalApicStruct.ApicId = (UINT8)
> mCpuApicIdOrderTable[Index].ApicId;
> - ProcLocalApicStruct.AcpiProcessorId = (UINT8)
> mCpuApicIdOrderTable[Index].AcpiProcessorId;
> + ProcLocalApicStruct.Flags = (UINT8)
> mCpuApicIdOrderTable[Index].Flags;
> + ProcLocalApicStruct.ApicId = (UINT8)
> mCpuApicIdOrderTable[Index].ApicId;
> + ProcLocalApicStruct.AcpiProcessorUid = (UINT8)
> + mCpuApicIdOrderTable[Index].AcpiProcessorUid;
>
> ASSERT (MadtStructsIndex < MaxMadtStructCount);
> Status = CopyStructure (
> @@ -837,7 +838,7 @@ InstallMadtFromScratch (
> } else if (mCpuApicIdOrderTable[Index].ApicId != 0xFFFFFFFF) {
> ProcLocalX2ApicStruct.Flags = (UINT8)
> mCpuApicIdOrderTable[Index].Flags;
> ProcLocalX2ApicStruct.X2ApicId =
> mCpuApicIdOrderTable[Index].ApicId;
> - ProcLocalX2ApicStruct.AcpiProcessorUid =
> mCpuApicIdOrderTable[Index].AcpiProcessorId;
> + ProcLocalX2ApicStruct.AcpiProcessorUid =
> + mCpuApicIdOrderTable[Index].AcpiProcessorUid;
>
> ASSERT (MadtStructsIndex < MaxMadtStructCount);
> Status = CopyStructure (
> @@ -855,8 +856,8 @@ InstallMadtFromScratch (
> //
> // Build I/O APIC Structures
> //
> - IoApicStruct.Type = EFI_ACPI_4_0_IO_APIC;
> - IoApicStruct.Length = sizeof (EFI_ACPI_4_0_IO_APIC_STRUCTURE);
> + IoApicStruct.Type = EFI_ACPI_6_3_IO_APIC; IoApicStruct.Length =
> + sizeof (EFI_ACPI_6_3_IO_APIC_STRUCTURE);
> IoApicStruct.Reserved = 0;
>
> PcIoApicEnable = PcdGet32 (PcdPcIoApicEnable); @@ -902,8 +903,8 @@
> InstallMadtFromScratch (
> //
> // Build Interrupt Source Override Structures
> //
> - IntSrcOverrideStruct.Type =
> EFI_ACPI_4_0_INTERRUPT_SOURCE_OVERRIDE;
> - IntSrcOverrideStruct.Length = sizeof
> (EFI_ACPI_4_0_INTERRUPT_SOURCE_OVERRIDE_STRUCTURE);
> + IntSrcOverrideStruct.Type =
> EFI_ACPI_6_3_INTERRUPT_SOURCE_OVERRIDE;
> + IntSrcOverrideStruct.Length = sizeof
> + (EFI_ACPI_6_3_INTERRUPT_SOURCE_OVERRIDE_STRUCTURE);
>
> //
> // IRQ0=>IRQ2 Interrupt Source Override Structure @@ -946,11 +947,11
> @@ InstallMadtFromScratch (
> //
> // Build Local APIC NMI Structures
> //
> - LocalApciNmiStruct.Type = EFI_ACPI_4_0_LOCAL_APIC_NMI;
> - LocalApciNmiStruct.Length = sizeof
> (EFI_ACPI_4_0_LOCAL_APIC_NMI_STRUCTURE);
> - LocalApciNmiStruct.AcpiProcessorId = 0xFF; // Applies to all processors
> - LocalApciNmiStruct.Flags = 0x0005; // Flags - Edge-tiggered, Active
> High
> - LocalApciNmiStruct.LocalApicLint = 0x1;
> + LocalApciNmiStruct.Type = EFI_ACPI_6_3_LOCAL_APIC_NMI;
> + LocalApciNmiStruct.Length = sizeof
> (EFI_ACPI_6_3_LOCAL_APIC_NMI_STRUCTURE);
> + LocalApciNmiStruct.AcpiProcessorUid = 0xFF; // Applies to all processors
> + LocalApciNmiStruct.Flags = 0x0005; // Flags - Edge-tiggered, Active
> High
> + LocalApciNmiStruct.LocalApicLint = 0x1;
>
> ASSERT (MadtStructsIndex < MaxMadtStructCount);
> Status = CopyStructure (
> @@ -967,8 +968,8 @@ InstallMadtFromScratch (
> // Build Local x2APIC NMI Structure
> //
> if (mX2ApicEnabled) {
> - LocalX2ApicNmiStruct.Type = EFI_ACPI_4_0_LOCAL_X2APIC_NMI;
> - LocalX2ApicNmiStruct.Length = sizeof
> (EFI_ACPI_4_0_LOCAL_X2APIC_NMI_STRUCTURE);
> + LocalX2ApicNmiStruct.Type = EFI_ACPI_6_3_LOCAL_X2APIC_NMI;
> + LocalX2ApicNmiStruct.Length = sizeof
> + (EFI_ACPI_6_3_LOCAL_X2APIC_NMI_STRUCTURE);
> LocalX2ApicNmiStruct.Flags = 0x000D; // Flags - Level-tiggered,
> Active High
> LocalX2ApicNmiStruct.AcpiProcessorUid = 0xFFFFFFFF; // Applies to all
> processors
> LocalX2ApicNmiStruct.LocalX2ApicLint = 0x01; @@ -992,12 +993,12 @@
> InstallMadtFromScratch (
> // Build Madt Structure from the Madt Header and collection of pointers in
> MadtStructs[]
> //
> Status = BuildAcpiTable (
> - (EFI_ACPI_DESCRIPTION_HEADER *) &MadtTableHeader,
> - sizeof
> (EFI_ACPI_4_0_MULTIPLE_APIC_DESCRIPTION_TABLE_HEADER),
> - MadtStructs,
> - MadtStructsIndex,
> - (UINT8 **) &NewMadtTable
> - );
> + (EFI_ACPI_DESCRIPTION_HEADER *) &MadtTableHeader,
> + sizeof
> (EFI_ACPI_6_3_MULTIPLE_APIC_DESCRIPTION_TABLE_HEADER),
> + MadtStructs,
> + MadtStructsIndex,
> + (UINT8 **)&NewMadtTable
> + );
> if (EFI_ERROR (Status)) {
> DEBUG ((DEBUG_ERROR, "BuildAcpiTable failed: %r\n", Status));
> goto Done;
> @@ -1087,7 +1088,7 @@ InstallMcfgFromScratch (
> }
>
> //
> - // Publish Madt Structure to ACPI
> + // Publish Mcfg Structure to ACPI
> //
> Status = mAcpiTable->InstallAcpiTable (
> mAcpiTable,
> @@ -1120,7 +1121,7 @@ PlatformUpdateTables (
> EFI_ACPI_DESCRIPTION_HEADER *TableHeader;
> UINT8 *TempOemId;
> UINT64 TempOemTableId;
> - EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE *FadtHeader;
> + EFI_ACPI_6_3_FIXED_ACPI_DESCRIPTION_TABLE *FadtHeader;
> EFI_ACPI_HIGH_PRECISION_EVENT_TIMER_TABLE_HEADER *HpetTable;
> UINT32 HpetBaseAddress;
> EFI_ACPI_HIGH_PRECISION_EVENT_TIMER_BLOCK_ID HpetBlockId;
> @@ -1177,12 +1178,12 @@ PlatformUpdateTables (
> //
> switch (Table->Signature) {
>
> - case EFI_ACPI_4_0_MULTIPLE_APIC_DESCRIPTION_TABLE_SIGNATURE:
> - ASSERT (FALSE);
> + case EFI_ACPI_6_3_MULTIPLE_APIC_DESCRIPTION_TABLE_SIGNATURE:
> + ASSERT(FALSE);
> break;
>
> - case EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE_SIGNATURE:
> - FadtHeader = (EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE *)
> Table;
> + case EFI_ACPI_6_3_FIXED_ACPI_DESCRIPTION_TABLE_SIGNATURE:
> + FadtHeader = (EFI_ACPI_6_3_FIXED_ACPI_DESCRIPTION_TABLE *) Table;
>
> FadtHeader->PreferredPmProfile = PcdGet8
> (PcdFadtPreferredPmProfile);
> FadtHeader->IaPcBootArch = PcdGet16 (PcdFadtIaPcBootArch);
> @@ -1228,7 +1229,7 @@ PlatformUpdateTables (
> DEBUG ((DEBUG_INFO, " Flags 0x%x\n", FadtHeader->Flags));
> break;
>
> - case EFI_ACPI_3_0_HIGH_PRECISION_EVENT_TIMER_TABLE_SIGNATURE:
> + case EFI_ACPI_6_3_HIGH_PRECISION_EVENT_TIMER_TABLE_SIGNATURE:
> HpetTable = (EFI_ACPI_HIGH_PRECISION_EVENT_TIMER_TABLE_HEADER
> *)Table;
> HpetBaseAddress = PcdGet32 (PcdHpetBaseAddress);
> HpetTable->BaseAddressLower32Bit.Address = HpetBaseAddress; @@ -
> 1280,8 +1281,8 @@ IsHardwareChange (
> UINTN HWChangeSize;
> UINT32 PciId;
> UINTN Handle;
> - EFI_ACPI_2_0_FIRMWARE_ACPI_CONTROL_STRUCTURE *FacsPtr;
> - EFI_ACPI_3_0_FIXED_ACPI_DESCRIPTION_TABLE *pFADT;
> + EFI_ACPI_6_3_FIRMWARE_ACPI_CONTROL_STRUCTURE *FacsPtr;
> + EFI_ACPI_6_3_FIXED_ACPI_DESCRIPTION_TABLE *pFADT;
>
> HandleCount = 0;
> HandleBuffer = NULL;
> @@ -1327,7 +1328,7 @@ IsHardwareChange (
> //
> Handle = 0;
> Status = LocateAcpiTableBySignature (
> - EFI_ACPI_1_0_FIXED_ACPI_DESCRIPTION_TABLE_SIGNATURE,
> + EFI_ACPI_6_3_FIXED_ACPI_DESCRIPTION_TABLE_SIGNATURE,
> (EFI_ACPI_DESCRIPTION_HEADER **) &pFADT,
> &Handle
> );
> @@ -1349,7 +1350,7 @@ IsHardwareChange (
> //
> // Set HardwareSignature value based on CRC value.
> //
> - FacsPtr = (EFI_ACPI_2_0_FIRMWARE_ACPI_CONTROL_STRUCTURE
> *)(UINTN)pFADT->FirmwareCtrl;
> + FacsPtr = (EFI_ACPI_6_3_FIRMWARE_ACPI_CONTROL_STRUCTURE
> + *)(UINTN)pFADT->FirmwareCtrl;
> FacsPtr->HardwareSignature = CRC;
> FreePool (HWChange);
> }
> diff --git a/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/Facs/Facs.c
> b/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/Facs/Facs.c
> index cde6e478c6b9..8700c44e633d 100644
> --- a/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/Facs/Facs.c
> +++ b/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/Facs/Facs.c
> @@ -1,9 +1,10 @@
> /** @file
> - This file contains a structure definition for the ACPI 5.0 Firmware ACPI
> + This file contains a structure definition for the ACPI 6.3 Firmware
> + ACPI
> Control Structure (FACS). The contents of this file should only be modified
> for bug fixes, no porting is required.
>
> Copyright (c) 2017, Intel Corporation. All rights reserved.<BR>
> +Copyright (c) Microsoft Corporation.<BR>
> SPDX-License-Identifier: BSD-2-Clause-Patent
>
> **/
> @@ -35,9 +36,9 @@ SPDX-License-Identifier: BSD-2-Clause-Patent // Please
> modify all values in Facs.h only.
> //
>
> -EFI_ACPI_5_0_FIRMWARE_ACPI_CONTROL_STRUCTURE Facs = {
> - EFI_ACPI_5_0_FIRMWARE_ACPI_CONTROL_STRUCTURE_SIGNATURE,
> - sizeof (EFI_ACPI_5_0_FIRMWARE_ACPI_CONTROL_STRUCTURE),
> +EFI_ACPI_6_3_FIRMWARE_ACPI_CONTROL_STRUCTURE Facs = {
> + EFI_ACPI_6_3_FIRMWARE_ACPI_CONTROL_STRUCTURE_SIGNATURE,
> + sizeof (EFI_ACPI_6_3_FIRMWARE_ACPI_CONTROL_STRUCTURE),
>
> //
> // Hardware Signature will be updated at runtime @@ -48,7 +49,7 @@
> EFI_ACPI_5_0_FIRMWARE_ACPI_CONTROL_STRUCTURE Facs = {
> EFI_ACPI_GLOBAL_LOCK,
> EFI_ACPI_FIRMWARE_CONTROL_STRUCTURE_FLAGS,
> EFI_ACPI_X_FIRMWARE_WAKING_VECTOR,
> - EFI_ACPI_5_0_FIRMWARE_ACPI_CONTROL_STRUCTURE_VERSION,
> + EFI_ACPI_6_3_FIRMWARE_ACPI_CONTROL_STRUCTURE_VERSION,
> {
> EFI_ACPI_RESERVED_BYTE,
> EFI_ACPI_RESERVED_BYTE,
> diff --git a/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/Fadt/Fadt.c
> b/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/Fadt/Fadt.c
> index 6efb38cda40d..3418e960972f 100644
> --- a/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/Fadt/Fadt.c
> +++ b/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/Fadt/Fadt.c
> @@ -1,9 +1,10 @@
> /** @file
> - This file contains a structure definition for the ACPI 5.0 Fixed ACPI
> + This file contains a structure definition for the ACPI 6.3 Fixed ACPI
> Description Table (FADT). The contents of this file should only be modified
> for bug fixes, no porting is required.
>
> Copyright (c) 2017, Intel Corporation. All rights reserved.<BR>
> +Copyright (c) Microsoft Corporation.<BR>
> SPDX-License-Identifier: BSD-2-Clause-Patent
>
> **/
> @@ -44,9 +45,13 @@ SPDX-License-Identifier: BSD-2-Clause-Patent // // IA-
> PC Boot Architecture Flags //
> -
> #define EFI_ACPI_IAPC_BOOT_ARCH 0 // To be fixed
>
> +//
> +// ARM Boot Architecture Flags
> +//
> +#define EFI_ACPI_ARM_BOOT_ARCH 0 // To be fixed
> +
> //
> // Fixed Feature Flags
> //
> @@ -55,7 +60,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent // //
> PM1A Event Register Block Generic Address Information // -#define
> EFI_ACPI_PM1A_EVT_BLK_ADDRESS_SPACE_ID EFI_ACPI_2_0_SYSTEM_IO
> +#define EFI_ACPI_PM1A_EVT_BLK_ADDRESS_SPACE_ID
> EFI_ACPI_6_3_SYSTEM_IO
> #define EFI_ACPI_PM1A_EVT_BLK_BIT_WIDTH 0x20
> #define EFI_ACPI_PM1A_EVT_BLK_BIT_OFFSET 0x00
> #define EFI_ACPI_PM1A_EVT_BLK_ADDRESS 0 // To be fixed
> @@ -63,7 +68,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent // //
> PM1B Event Register Block Generic Address Information // -#define
> EFI_ACPI_PM1B_EVT_BLK_ADDRESS_SPACE_ID EFI_ACPI_2_0_SYSTEM_IO
> +#define EFI_ACPI_PM1B_EVT_BLK_ADDRESS_SPACE_ID
> EFI_ACPI_6_3_SYSTEM_IO
> #define EFI_ACPI_PM1B_EVT_BLK_BIT_WIDTH 0x00
> #define EFI_ACPI_PM1B_EVT_BLK_BIT_OFFSET 0x00
> #define EFI_ACPI_PM1B_EVT_BLK_ADDRESS 0 // To be fixed
> @@ -71,7 +76,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent // //
> PM1A Control Register Block Generic Address Information // -#define
> EFI_ACPI_PM1A_CNT_BLK_ADDRESS_SPACE_ID EFI_ACPI_2_0_SYSTEM_IO
> +#define EFI_ACPI_PM1A_CNT_BLK_ADDRESS_SPACE_ID
> EFI_ACPI_6_3_SYSTEM_IO
> #define EFI_ACPI_PM1A_CNT_BLK_BIT_WIDTH 0x10
> #define EFI_ACPI_PM1A_CNT_BLK_BIT_OFFSET 0x00
> #define EFI_ACPI_PM1A_CNT_BLK_ADDRESS 0 // To be fixed
> @@ -79,7 +84,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent // //
> PM1B Control Register Block Generic Address Information // -#define
> EFI_ACPI_PM1B_CNT_BLK_ADDRESS_SPACE_ID EFI_ACPI_2_0_SYSTEM_IO
> +#define EFI_ACPI_PM1B_CNT_BLK_ADDRESS_SPACE_ID
> EFI_ACPI_6_3_SYSTEM_IO
> #define EFI_ACPI_PM1B_CNT_BLK_BIT_WIDTH 0x00
> #define EFI_ACPI_PM1B_CNT_BLK_BIT_OFFSET 0x00
> #define EFI_ACPI_PM1B_CNT_BLK_ADDRESS 0 // To be fixed
> @@ -87,7 +92,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent // //
> PM2 Control Register Block Generic Address Information // -#define
> EFI_ACPI_PM2_CNT_BLK_ADDRESS_SPACE_ID EFI_ACPI_2_0_SYSTEM_IO
> +#define EFI_ACPI_PM2_CNT_BLK_ADDRESS_SPACE_ID
> EFI_ACPI_6_3_SYSTEM_IO
> #define EFI_ACPI_PM2_CNT_BLK_BIT_WIDTH 0x08
> #define EFI_ACPI_PM2_CNT_BLK_BIT_OFFSET 0x00
> #define EFI_ACPI_PM2_CNT_BLK_ADDRESS 0 // To be fixed
> @@ -96,7 +101,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent //
> Power Management Timer Control Register Block Generic Address //
> Information // -#define EFI_ACPI_PM_TMR_BLK_ADDRESS_SPACE_ID
> EFI_ACPI_2_0_SYSTEM_IO
> +#define EFI_ACPI_PM_TMR_BLK_ADDRESS_SPACE_ID
> EFI_ACPI_6_3_SYSTEM_IO
> #define EFI_ACPI_PM_TMR_BLK_BIT_WIDTH 0x20
> #define EFI_ACPI_PM_TMR_BLK_BIT_OFFSET 0x00
> #define EFI_ACPI_PM_TMR_BLK_ADDRESS 0 // To be fixed
> @@ -105,7 +110,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent //
> General Purpose Event 0 Register Block Generic Address // Information // -
> #define EFI_ACPI_GPE0_BLK_ADDRESS_SPACE_ID
> EFI_ACPI_2_0_SYSTEM_IO
> +#define EFI_ACPI_GPE0_BLK_ADDRESS_SPACE_ID
> EFI_ACPI_6_3_SYSTEM_IO
> #define EFI_ACPI_GPE0_BLK_BIT_WIDTH 0 // size of
> R_PCH_ACPI_GPE0_STS_127_96 + R_PCH_ACPI_GPE0_EN_127_96
> #define EFI_ACPI_GPE0_BLK_BIT_OFFSET 0x00
> #define EFI_ACPI_GPE0_BLK_ADDRESS 0 // To be fixed
> @@ -114,14 +119,14 @@ SPDX-License-Identifier: BSD-2-Clause-Patent //
> General Purpose Event 1 Register Block Generic Address // Information // -
> #define EFI_ACPI_GPE1_BLK_ADDRESS_SPACE_ID
> EFI_ACPI_2_0_SYSTEM_IO
> +#define EFI_ACPI_GPE1_BLK_ADDRESS_SPACE_ID
> EFI_ACPI_6_3_SYSTEM_IO
> #define EFI_ACPI_GPE1_BLK_BIT_WIDTH 0x0
> #define EFI_ACPI_GPE1_BLK_BIT_OFFSET 0x0
> #define EFI_ACPI_GPE1_BLK_ADDRESS 0 // To be fixed
> //
> // Reset Register Generic Address Information // -#define
> EFI_ACPI_RESET_REG_ADDRESS_SPACE_ID EFI_ACPI_2_0_SYSTEM_IO
> +#define EFI_ACPI_RESET_REG_ADDRESS_SPACE_ID
> EFI_ACPI_6_3_SYSTEM_IO
> #define EFI_ACPI_RESET_REG_BIT_WIDTH 0x08
> #define EFI_ACPI_RESET_REG_BIT_OFFSET 0x00
> #define EFI_ACPI_RESET_REG_ADDRESS 0x00000CF9
> @@ -162,11 +167,11 @@ SPDX-License-Identifier: BSD-2-Clause-Patent //
> Please modify all values in Fadt.h only.
> //
>
> -EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE Fadt = {
> +EFI_ACPI_6_3_FIXED_ACPI_DESCRIPTION_TABLE Fadt = {
> {
> - EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE_SIGNATURE,
> - sizeof (EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE),
> - EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE_REVISION,
> + EFI_ACPI_6_3_FIXED_ACPI_DESCRIPTION_TABLE_SIGNATURE,
> + sizeof (EFI_ACPI_6_3_FIXED_ACPI_DESCRIPTION_TABLE),
> + EFI_ACPI_6_3_FIXED_ACPI_DESCRIPTION_TABLE_REVISION,
>
> //
> // Checksum will be updated at runtime @@ -187,9 +192,9 @@
> EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE Fadt = {
> //
> // These addresses will be updated at runtime
> //
> - 0x00000000,
> 0x00000000,
> -
> + 0x00000000,
> +
> EFI_ACPI_RESERVED_BYTE,
> EFI_ACPI_PREFERRED_PM_PROFILE,
> EFI_ACPI_SCI_INT,
> @@ -198,7 +203,7 @@ EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE
> Fadt = {
> EFI_ACPI_ACPI_DISABLE,
> EFI_ACPI_S4_BIOS_REQ,
> EFI_ACPI_PSTATE_CNT,
> -
> +
> EFI_ACPI_PM1A_EVT_BLK_ADDRESS,
> EFI_ACPI_PM1B_EVT_BLK_ADDRESS,
> EFI_ACPI_PM1A_CNT_BLK_ADDRESS,
> @@ -240,15 +245,13 @@ EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE
> Fadt = {
> EFI_ACPI_RESET_REG_ADDRESS_SPACE_ID,
> EFI_ACPI_RESET_REG_BIT_WIDTH,
> EFI_ACPI_RESET_REG_BIT_OFFSET,
> - EFI_ACPI_5_0_BYTE,
> + EFI_ACPI_6_3_BYTE,
> EFI_ACPI_RESET_REG_ADDRESS
> },
> EFI_ACPI_RESET_VALUE,
> - {
> - EFI_ACPI_RESERVED_BYTE,
> - EFI_ACPI_RESERVED_BYTE,
> - EFI_ACPI_RESERVED_BYTE
> - },
> +
> + EFI_ACPI_ARM_BOOT_ARCH,
> + EFI_ACPI_6_3_FIXED_ACPI_DESCRIPTION_TABLE_MINOR_REVISION,
>
> //
> // These addresses will be updated at runtime @@ -263,7 +266,7 @@
> EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE Fadt = {
> EFI_ACPI_PM1A_EVT_BLK_ADDRESS_SPACE_ID,
> EFI_ACPI_PM1A_EVT_BLK_BIT_WIDTH,
> EFI_ACPI_PM1A_EVT_BLK_BIT_OFFSET,
> - EFI_ACPI_5_0_WORD,
> + EFI_ACPI_6_3_WORD,
> EFI_ACPI_PM1A_EVT_BLK_ADDRESS
> },
> {
> @@ -273,7 +276,7 @@ EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE
> Fadt = {
> EFI_ACPI_PM1B_EVT_BLK_ADDRESS_SPACE_ID,
> EFI_ACPI_PM1B_EVT_BLK_BIT_WIDTH,
> EFI_ACPI_PM1B_EVT_BLK_BIT_OFFSET,
> - EFI_ACPI_5_0_WORD,
> + EFI_ACPI_6_3_WORD,
> EFI_ACPI_PM1B_EVT_BLK_ADDRESS
> },
> {
> @@ -283,7 +286,7 @@ EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE
> Fadt = {
> EFI_ACPI_PM1A_CNT_BLK_ADDRESS_SPACE_ID,
> EFI_ACPI_PM1A_CNT_BLK_BIT_WIDTH,
> EFI_ACPI_PM1A_CNT_BLK_BIT_OFFSET,
> - EFI_ACPI_5_0_WORD,
> + EFI_ACPI_6_3_WORD,
> EFI_ACPI_PM1A_CNT_BLK_ADDRESS
> },
> {
> @@ -293,7 +296,7 @@ EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE
> Fadt = {
> EFI_ACPI_PM1B_CNT_BLK_ADDRESS_SPACE_ID,
> EFI_ACPI_PM1B_CNT_BLK_BIT_WIDTH,
> EFI_ACPI_PM1B_CNT_BLK_BIT_OFFSET,
> - EFI_ACPI_5_0_WORD,
> + EFI_ACPI_6_3_WORD,
> EFI_ACPI_PM1B_CNT_BLK_ADDRESS
> },
> {
> @@ -303,7 +306,7 @@ EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE
> Fadt = {
> EFI_ACPI_PM2_CNT_BLK_ADDRESS_SPACE_ID,
> EFI_ACPI_PM2_CNT_BLK_BIT_WIDTH,
> EFI_ACPI_PM2_CNT_BLK_BIT_OFFSET,
> - EFI_ACPI_5_0_BYTE,
> + EFI_ACPI_6_3_BYTE,
> EFI_ACPI_PM2_CNT_BLK_ADDRESS
> },
> {
> @@ -313,7 +316,7 @@ EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE
> Fadt = {
> EFI_ACPI_PM_TMR_BLK_ADDRESS_SPACE_ID,
> EFI_ACPI_PM_TMR_BLK_BIT_WIDTH,
> EFI_ACPI_PM_TMR_BLK_BIT_OFFSET,
> - EFI_ACPI_5_0_DWORD,
> + EFI_ACPI_6_3_DWORD,
> EFI_ACPI_PM_TMR_BLK_ADDRESS
> },
> {
> @@ -323,7 +326,7 @@ EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE
> Fadt = {
> EFI_ACPI_GPE0_BLK_ADDRESS_SPACE_ID,
> EFI_ACPI_GPE0_BLK_BIT_WIDTH,
> EFI_ACPI_GPE0_BLK_BIT_OFFSET,
> - EFI_ACPI_5_0_BYTE,
> + EFI_ACPI_6_3_BYTE,
> EFI_ACPI_GPE0_BLK_ADDRESS
> },
> {
> @@ -333,7 +336,7 @@ EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE
> Fadt = {
> EFI_ACPI_GPE1_BLK_ADDRESS_SPACE_ID,
> EFI_ACPI_GPE1_BLK_BIT_WIDTH,
> EFI_ACPI_GPE1_BLK_BIT_OFFSET,
> - EFI_ACPI_5_0_BYTE,
> + EFI_ACPI_6_3_BYTE,
> EFI_ACPI_GPE1_BLK_ADDRESS
> },
> {
> @@ -355,5 +358,10 @@ EFI_ACPI_5_0_FIXED_ACPI_DESCRIPTION_TABLE
> Fadt = {
> 0,
> 0,
> 0
> - }
> + },
> +
> + //
> + // Hypervisor Vendor Identity
> + //
> + 0x0000000000000000,
> };
> --
> 2.28.0.windows.1
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2021-10-02 1:14 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-09-24 18:22 [edk2-platforms][PATCH v2 1/1] MinPlatformPkg/AcpiTables: Update structures for ACPI 6.3 Michael Kubacki
2021-10-02 1:13 ` Nate DeSimone
2021-10-02 1:14 ` Nate DeSimone
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox