MdeModulePkg PiSmmCore: Only install EndOfS3Resume during S3 resume

Otherwise, it may be triggered wrongly by other code in OS.

This patch is to use S3 entry callback to determine if it will be
during S3 resume, and check it in SmmReadyToBootHandler().

Cc: Jiewen Yao <jiewen.yao@intel.com>
Cc: Eric Dong <eric.dong@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Star Zeng <star.zeng@intel.com>
Reviewed-by: Jiewen Yao <jiewen.yao@intel.com>
This commit is contained in:
Star Zeng
2017-12-08 18:44:40 +08:00
parent a85e7127bf
commit 7b9b55b2ef
3 changed files with 77 additions and 4 deletions

View File

@@ -33,6 +33,7 @@
#include <Protocol/SmmLegacyBoot.h>
#include <Protocol/SmmReadyToBoot.h>
#include <Protocol/SmmMemoryAttribute.h>
#include <Protocol/SmmSxDispatch2.h>
#include <Guid/Apriori.h>
#include <Guid/EventGroup.h>