summaryrefslogtreecommitdiffstats
path: root/UefiCpuPkg/UefiCpuPkg.dec
diff options
context:
space:
mode:
authorJian J Wang <jian.j.wang@intel.com>2017-12-07 20:13:30 +0800
committerStar Zeng <star.zeng@intel.com>2017-12-08 14:38:46 +0800
commitadb9f50e4bba7d785af58e6647a15175d9be4446 (patch)
tree873114cef03e86a9440e55dcf86da3601c7d7a10 /UefiCpuPkg/UefiCpuPkg.dec
parent448d014b7359b92404653a4da3c63abe4d2389a5 (diff)
downloadedk2-adb9f50e4bba7d785af58e6647a15175d9be4446.tar.gz
edk2-adb9f50e4bba7d785af58e6647a15175d9be4446.tar.bz2
edk2-adb9f50e4bba7d785af58e6647a15175d9be4446.zip
UefiCpuPkg/UefiCpuPkg.dec: Add two new PCDs for stack switch
Stack switch is required by Stack Guard feature. Following two PCDs are introduced to simplify the resource allocation for initializing stack switch. gUefiCpuPkgTokenSpaceGuid.PcdCpuStackSwitchExceptionList gUefiCpuPkgTokenSpaceGuid.PcdCpuKnownGoodStackSize PcdCpuStackSwitchExceptionList is used to specify which exception will have separate stack for its handler. For Stack Guard feature, #PF must be specified at least. PcdCpuKnownGoodStackSize is used to specify the size of knwon good stack for an exception handler. Cpu driver or other drivers should use this PCD to reserve new stack memory for exceptions specified by above PCD. Cc: Eric Dong <eric.dong@intel.com> Cc: Laszlo Ersek <lersek@redhat.com> Cc: Jiewen Yao <jiewen.yao@intel.com> Suggested-by: Ayellet Wolman <ayellet.wolman@intel.com> Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Jian J Wang <jian.j.wang@intel.com> Reviewed-by: Jeff Fan <vanjeff_919@hotmail.com> Reviewed-by: Jiewen.yao@intel.com
Diffstat (limited to 'UefiCpuPkg/UefiCpuPkg.dec')
-rw-r--r--UefiCpuPkg/UefiCpuPkg.dec12
1 files changed, 12 insertions, 0 deletions
diff --git a/UefiCpuPkg/UefiCpuPkg.dec b/UefiCpuPkg/UefiCpuPkg.dec
index 6bac23ff52..f0f786495e 100644
--- a/UefiCpuPkg/UefiCpuPkg.dec
+++ b/UefiCpuPkg/UefiCpuPkg.dec
@@ -138,6 +138,18 @@
# @Prompt Lock SMM Feature Control MSR.
gUefiCpuPkgTokenSpaceGuid.PcdCpuSmmFeatureControlMsrLock|TRUE|BOOLEAN|0x3213210B
+[PcdsFixedAtBuild]
+ ## List of exception vectors which need switching stack.
+ # This PCD will only take into effect if PcdCpuStackGuard is enabled.
+ # By default exception #DD(8), #PF(14) are supported.
+ # @Prompt Specify exception vectors which need switching stack.
+ gUefiCpuPkgTokenSpaceGuid.PcdCpuStackSwitchExceptionList|{0x08, 0x0E}|VOID*|0x30002000
+
+ ## Size of good stack for an exception.
+ # This PCD will only take into effect if PcdCpuStackGuard is enabled.
+ # @Prompt Specify size of good stack of exception which need switching stack.
+ gUefiCpuPkgTokenSpaceGuid.PcdCpuKnownGoodStackSize|2048|UINT32|0x30002001
+
[PcdsFixedAtBuild, PcdsPatchableInModule]
## This value is the CPU Local APIC base address, which aligns the address on a 4-KByte boundary.
# @Prompt Configure base address of CPU Local APIC