mirror of
https://github.com/tianocore/edk2
synced 2026-08-27 00:23:19 -04:00
MdeModulePkg: : revert EndofDxeEvent TPLs to TPL_NOTIFY for FPDT
commitaa02571("MdeModulePkg: Change EndofDxeEvent TPLs to TPL_CALLBACK") changed EndOfDxeEvent TPLs from TPL_NOFIY to TPL_CALLBACK. However this commit makes a boot failure on the FVP platform when FPDT ACPI table generation is enabled: [FirmwarePerformanceDxe] Error when lock variable FirmwarePerformance, Status = Write Protected ASSERT_EFI_ERROR (Status = Write Protected) ASSERT [FirmwarePerformanceDxe] FirmwarePerformanceDxe.c(405): !(((RETURN_STATUS)(Status)) >= 0x8000000000000000ULL) Currently, EVT_NOTIFY_SIGNAL events are managed in FILO order, as new events are inserted using InsertHeadList(). The sequence is as follows: 1. DxeCore initializes DxeCorePerformanceLib, whose constructor creates an EndOfDxe event (gEfiEndOfDxeEventGroupGuid) with the ReportFpdtRecordBuffer() callback. 2. MmCommunicationDxe (in ArmPkg) creates another EndOfDxe event to notify StandaloneMm. This event is inserted ahead of the one created in (1). 3. PlatformBootManagerBeforeConsole() signals EndOfDxe, which triggers the event created in (2) first. 4. When the callback from (2) runs, StandaloneMm calls LockVariablePolicy(). 5. The callback from (1) is then invoked and attempts to update FPDT via InstallFirmwarePerformanceDataTable(). During this process, it tries to register a variable policy for the FirmwarePerformance variable. However, since the Variable Policy interface was locked in (4), the operation fails with EFI_WRITE_PROTECTED. To resolve this issue, revert EndofDxeEvent TPLs to TPL_NOTIFY for FPDT. Fixes:aa02571("MdeModulePkg: Change EndofDxeEvent TPLs to TPL_CALLBACK") Signed-off-by: Yeoreum Yun <yeoreum.yun@arm.com>
This commit is contained in:
parent
a4a7346cf4
commit
8c50e656c0
2 changed files with 2 additions and 2 deletions
|
|
@ -1540,7 +1540,7 @@ DxeCorePerformanceLibConstructor (
|
|||
//
|
||||
Status = gBS->CreateEventEx (
|
||||
EVT_NOTIFY_SIGNAL,
|
||||
TPL_CALLBACK,
|
||||
TPL_NOTIFY,
|
||||
ReportFpdtRecordBuffer,
|
||||
NULL,
|
||||
&gEfiEndOfDxeEventGroupGuid,
|
||||
|
|
|
|||
|
|
@ -686,7 +686,7 @@ FirmwarePerformanceDxeEntryPoint (
|
|||
//
|
||||
Status = gBS->CreateEventEx (
|
||||
EVT_NOTIFY_SIGNAL,
|
||||
TPL_CALLBACK,
|
||||
TPL_NOTIFY,
|
||||
FpdtEndOfDxeEventNotify,
|
||||
NULL,
|
||||
&gEfiEndOfDxeEventGroupGuid,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue