summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Platform/ARM/SgiPkg/Drivers/PlatformDxe/PlatformDxe.c19
-rw-r--r--Platform/ARM/SgiPkg/Drivers/PlatformDxe/PlatformDxe.inf5
2 files changed, 22 insertions, 2 deletions
diff --git a/Platform/ARM/SgiPkg/Drivers/PlatformDxe/PlatformDxe.c b/Platform/ARM/SgiPkg/Drivers/PlatformDxe/PlatformDxe.c
index 2f72e715..675a10d3 100644
--- a/Platform/ARM/SgiPkg/Drivers/PlatformDxe/PlatformDxe.c
+++ b/Platform/ARM/SgiPkg/Drivers/PlatformDxe/PlatformDxe.c
@@ -9,6 +9,10 @@
#include <Library/AcpiLib.h>
#include <Library/DebugLib.h>
#include <Library/HobLib.h>
+#include <Library/UefiBootServicesTableLib.h>
+
+#include <Protocol/Apei.h>
+
#include <SgiPlatform.h>
VOID
@@ -23,6 +27,7 @@ ArmSgiPkgEntryPoint (
IN EFI_SYSTEM_TABLE *SystemTable
)
{
+ EFI_APEI_PROTOCOL *ApeiProtocol;
EFI_STATUS Status;
Status = LocateAndInstallAcpiFromFv (&gArmSgiAcpiTablesGuid);
@@ -31,7 +36,19 @@ ArmSgiPkgEntryPoint (
return Status;
}
+ // Update ACPI table with available Error Source information
+ // Continue booting if MM is not enabled.
+ Status = gBS->LocateProtocol (&gEfiApeiProtocolGuid, NULL, (VOID **) &ApeiProtocol);
+ if (!EFI_ERROR (Status)) {
+ Status = ApeiProtocol->UpdateApei (ApeiProtocol, EFI_ACPI_6_1_HARDWARE_ERROR_SOURCE_TABLE_SIGNATURE);
+ if (EFI_ERROR (Status)) {
+ DEBUG ((DEBUG_INFO, "PlatformDxe: Failed to update \n"));
+ }
+ } else {
+ DEBUG ((DEBUG_INFO, "PlatformDxe: Failed to locate APEI protocol\n"));
+ }
+
InitVirtioDevices ();
- return Status;
+ return EFI_SUCCESS;
}
diff --git a/Platform/ARM/SgiPkg/Drivers/PlatformDxe/PlatformDxe.inf b/Platform/ARM/SgiPkg/Drivers/PlatformDxe/PlatformDxe.inf
index 9d89314a..dda4c31f 100644
--- a/Platform/ARM/SgiPkg/Drivers/PlatformDxe/PlatformDxe.inf
+++ b/Platform/ARM/SgiPkg/Drivers/PlatformDxe/PlatformDxe.inf
@@ -32,6 +32,9 @@
gArmSgiPlatformIdDescriptorGuid
gArmSgiAcpiTablesGuid
+[Protocols]
+ gEfiApeiProtocolGuid
+
[FeaturePcd]
gArmSgiTokenSpaceGuid.PcdVirtioBlkSupported
gArmSgiTokenSpaceGuid.PcdVirtioNetSupported
@@ -43,4 +46,4 @@
gArmSgiTokenSpaceGuid.PcdVirtioNetSize
[Depex]
- TRUE
+ gEfiApeiProtocolGuid