summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRobert Phelps <robert@ami.com>2022-12-22 04:28:06 +0800
committermergify[bot] <37929162+mergify[bot]@users.noreply.github.com>2023-02-15 12:34:20 +0000
commit38da9606f77842cdcdc231210c0369a6180c51a0 (patch)
tree414f20a1e89cd20852cdd4792238dd66e8a8fc96
parent419c0aafa62d069a45aba4563c368a5e56c2cbb6 (diff)
downloadedk2-38da9606f77842cdcdc231210c0369a6180c51a0.tar.gz
edk2-38da9606f77842cdcdc231210c0369a6180c51a0.tar.bz2
edk2-38da9606f77842cdcdc231210c0369a6180c51a0.zip
MdePkg: Added Call for AfterReadyToBoot Event
In the function EfiSignalEventReadyToBoot, Code was added to also create, signal, and close the AfterReadyToBoot event. Cc: Michael D Kinney <michael.d.kinney@intel.com> Cc: Liming Gao <gaoliming@byosoft.com.cn> Cc: Zhiguang Liu <zhiguang.liu@intel.com> Signed-off-by: Robert Phelps <robert@ami.com> Reviewed-by: Liming Gao <gaoliming@byosoft.com.cn>
-rw-r--r--MdePkg/Library/UefiLib/UefiLib.inf1
-rw-r--r--MdePkg/Library/UefiLib/UefiNotTiano.c14
2 files changed, 15 insertions, 0 deletions
diff --git a/MdePkg/Library/UefiLib/UefiLib.inf b/MdePkg/Library/UefiLib/UefiLib.inf
index 01ed92092d..3aced47d2e 100644
--- a/MdePkg/Library/UefiLib/UefiLib.inf
+++ b/MdePkg/Library/UefiLib/UefiLib.inf
@@ -56,6 +56,7 @@
[Guids]
gEfiEventReadyToBootGuid ## SOMETIMES_CONSUMES ## Event
+ gEfiEventAfterReadyToBootGuid ## SOMETIMES_CONSUMES ## Event
gEfiEventLegacyBootGuid ## SOMETIMES_CONSUMES ## Event
gEfiGlobalVariableGuid ## SOMETIMES_CONSUMES ## Variable
gEfiAcpi20TableGuid ## SOMETIMES_CONSUMES ## SystemTable
diff --git a/MdePkg/Library/UefiLib/UefiNotTiano.c b/MdePkg/Library/UefiLib/UefiNotTiano.c
index d84e91fd01..8c8d9b29f8 100644
--- a/MdePkg/Library/UefiLib/UefiNotTiano.c
+++ b/MdePkg/Library/UefiLib/UefiNotTiano.c
@@ -222,12 +222,26 @@ EfiSignalEventReadyToBoot (
{
EFI_STATUS Status;
EFI_EVENT ReadyToBootEvent;
+ EFI_EVENT AfterReadyToBootEvent;
Status = EfiCreateEventReadyToBoot (&ReadyToBootEvent);
if (!EFI_ERROR (Status)) {
gBS->SignalEvent (ReadyToBootEvent);
gBS->CloseEvent (ReadyToBootEvent);
}
+
+ Status = gBS->CreateEventEx (
+ EVT_NOTIFY_SIGNAL,
+ TPL_CALLBACK,
+ EfiEventEmptyFunction,
+ NULL,
+ &gEfiEventAfterReadyToBootGuid,
+ &AfterReadyToBootEvent
+ );
+ if (!EFI_ERROR (Status)) {
+ gBS->SignalEvent (AfterReadyToBootEvent);
+ gBS->CloseEvent (AfterReadyToBootEvent);
+ }
}
/**