diff options
author | Michael Kinney <michael.d.kinney@intel.com> | 2015-12-24 00:14:00 +0000 |
---|---|---|
committer | mdkinney <mdkinney@Edk2> | 2015-12-24 00:14:00 +0000 |
commit | 6011381199b21e906bcb87a30f58ebe70b9b7154 (patch) | |
tree | e54142fc4149bf864e36f3f4e5a157810a349eac /UefiCpuPkg/PiSmmCpuDxeSmm | |
parent | e9b3a6c926a65f568c1a736dfc6e9957cc7cf3de (diff) | |
download | edk2-platforms-6011381199b21e906bcb87a30f58ebe70b9b7154.tar.xz |
UefiCpuPkg/PiSmmCpuDxeSmm: Initialize gSmst fields on S3 resume
Update S3 resume path to initialize the fields of gSmst before
the gSmst fields are used to complete initialization in S3 resume.
Cc: Jeff Fan <jeff.fan@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Michael Kinney <michael.d.kinney@intel.com>
Reviewed-by: Jeff Fan <jeff.fan@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@19504 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'UefiCpuPkg/PiSmmCpuDxeSmm')
-rw-r--r-- | UefiCpuPkg/PiSmmCpuDxeSmm/PiSmmCpuDxeSmm.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/UefiCpuPkg/PiSmmCpuDxeSmm/PiSmmCpuDxeSmm.c b/UefiCpuPkg/PiSmmCpuDxeSmm/PiSmmCpuDxeSmm.c index 949dd4e5c1..36a0650b2f 100644 --- a/UefiCpuPkg/PiSmmCpuDxeSmm/PiSmmCpuDxeSmm.c +++ b/UefiCpuPkg/PiSmmCpuDxeSmm/PiSmmCpuDxeSmm.c @@ -1497,6 +1497,15 @@ PerformPreTasks ( //
if (mRestoreSmmConfigurationInS3) {
//
+ // Need make sure gSmst is correct because below function may use them.
+ //
+ gSmst->SmmStartupThisAp = gSmmCpuPrivate->SmmCoreEntryContext.SmmStartupThisAp;
+ gSmst->CurrentlyExecutingCpu = gSmmCpuPrivate->SmmCoreEntryContext.CurrentlyExecutingCpu;
+ gSmst->NumberOfCpus = gSmmCpuPrivate->SmmCoreEntryContext.NumberOfCpus;
+ gSmst->CpuSaveStateSize = gSmmCpuPrivate->SmmCoreEntryContext.CpuSaveStateSize;
+ gSmst->CpuSaveState = gSmmCpuPrivate->SmmCoreEntryContext.CpuSaveState;
+
+ //
// Configure SMM Code Access Check feature if available.
//
ConfigSmmCodeAccessCheck ();
|