summaryrefslogtreecommitdiffstats
path: root/UefiCpuPkg/PiSmmCpuDxeSmm/PiSmmCpuDxeSmm.c
diff options
context:
space:
mode:
authorJeff Fan <jeff.fan@intel.com>2016-06-29 09:00:13 +0800
committerMichael Kinney <michael.d.kinney@intel.com>2016-07-14 08:57:47 -0700
commit6c4c15fae665e4c464ab56c830efb7a6399e11dd (patch)
treec4aa9999e25872c2fe8b0da11390bad14d254e30 /UefiCpuPkg/PiSmmCpuDxeSmm/PiSmmCpuDxeSmm.c
parent8b9311b79557311e137d0ffdc7934fea3966b0d7 (diff)
downloadedk2-6c4c15fae665e4c464ab56c830efb7a6399e11dd.tar.gz
edk2-6c4c15fae665e4c464ab56c830efb7a6399e11dd.tar.bz2
edk2-6c4c15fae665e4c464ab56c830efb7a6399e11dd.zip
UefiCpuPkg/PiSmmCpuDxeSmm: Add MemoryMapped in SetProcessorRegister()
REGISTER_TYPE in UefiCpuPkg/Include/AcpiCpuData.h defines a MemoryMapped enum value. However support for the MemoryMapped enum is missing from the implementation of SetProcessorRegister(). This patch adds support for MemoryMapped type SetProcessorRegister(). One spin lock is added to avoid potential conflict when multiple processor update the same memory space. Cc: Michael Kinney <michael.d.kinney@intel.com> Cc: Feng Tian <feng.tian@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Jeff Fan <jeff.fan@intel.com> Reviewed-by: Feng Tian <feng.tian@intel.com> Reviewed-by: Michael Kinney <michael.d.kinney@intel.com> Regression-tested-by: Laszlo Ersek <lersek@redhat.com>
Diffstat (limited to 'UefiCpuPkg/PiSmmCpuDxeSmm/PiSmmCpuDxeSmm.c')
-rw-r--r--UefiCpuPkg/PiSmmCpuDxeSmm/PiSmmCpuDxeSmm.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/UefiCpuPkg/PiSmmCpuDxeSmm/PiSmmCpuDxeSmm.c b/UefiCpuPkg/PiSmmCpuDxeSmm/PiSmmCpuDxeSmm.c
index 8b3bb343ce..0858d8f4d7 100644
--- a/UefiCpuPkg/PiSmmCpuDxeSmm/PiSmmCpuDxeSmm.c
+++ b/UefiCpuPkg/PiSmmCpuDxeSmm/PiSmmCpuDxeSmm.c
@@ -485,6 +485,8 @@ SmmRestoreCpu (
DEBUG ((EFI_D_INFO, "SmmRestoreCpu()\n"));
+ InitializeSpinLock (mMemoryMappedLock);
+
//
// See if there is enough context to resume PEI Phase
//