diff options
author | Yao, Jiewen <jiewen.yao@intel.com> | 2019-02-22 21:30:34 +0800 |
---|---|---|
committer | Liming Gao <liming.gao@intel.com> | 2019-02-28 09:39:47 +0800 |
commit | 0aac2f777a688a146050bed47753e2dcf801d3c7 (patch) | |
tree | f8b7e0a818354fecd0a41d4fecf3be88db88b8b5 /MdePkg/Include | |
parent | 68edd7dbad77d7170ee0e1c5dbefae93ea9997b1 (diff) | |
download | edk2-0aac2f777a688a146050bed47753e2dcf801d3c7.tar.gz edk2-0aac2f777a688a146050bed47753e2dcf801d3c7.tar.bz2 edk2-0aac2f777a688a146050bed47753e2dcf801d3c7.zip |
MdePkg/BaseLib: Add Shadow Stack Support for X86.
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1521
This patch adds SSP - shadow stack pointer to JumpBuffer.
It will be used for the platform that enabled CET/ShadowStack.
We add gEfiMdePkgTokenSpaceGuid.PcdControlFlowEnforcementPropertyMask
to control the global enable/disable.
Cc: Michael D Kinney <michael.d.kinney@intel.com>
Cc: Liming Gao <liming.gao@intel.com>
Cc: Eric Dong <eric.dong@intel.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Laszlo Ersek <lersek@redhat.com>
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Yao Jiewen <jiewen.yao@intel.com>
Reviewed-by: Ray Ni <ray.ni@intel.com>
Regression-tested-by: Laszlo Ersek <lersek@redhat.com>
Diffstat (limited to 'MdePkg/Include')
-rw-r--r-- | MdePkg/Include/Library/BaseLib.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/MdePkg/Include/Library/BaseLib.h b/MdePkg/Include/Library/BaseLib.h index 9c42f82a7d..616ba2e95b 100644 --- a/MdePkg/Include/Library/BaseLib.h +++ b/MdePkg/Include/Library/BaseLib.h @@ -31,6 +31,7 @@ typedef struct { UINT32 Ebp;
UINT32 Esp;
UINT32 Eip;
+ UINT32 Ssp;
} BASE_LIBRARY_JUMP_BUFFER;
#define BASE_LIBRARY_JUMP_BUFFER_ALIGNMENT 4
@@ -54,6 +55,7 @@ typedef struct { UINT64 Rip;
UINT64 MxCsr;
UINT8 XmmBuffer[160]; ///< XMM6-XMM15.
+ UINT64 Ssp;
} BASE_LIBRARY_JUMP_BUFFER;
#define BASE_LIBRARY_JUMP_BUFFER_ALIGNMENT 8
|