audk/UefiCpuPkg/Library/CpuExceptionHandlerLib
Tom Lendacky 5277540e37 UefiCpuPkg/CpuExceptionHandler: Add base support for the #VC exception
BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=2198

Add base support to handle #VC exceptions. Update the common exception
handlers to invoke the VmgExitHandleVc () function of the VmgExitLib
library when a #VC is encountered. A non-zero return code will propagate
to the targeted exception handler.

Under SEV-ES, a DR7 read or write intercept generates a #VC exception.
To avoid exception recursion, a #VC exception will not try to read and
push the actual debug registers into the EFI_SYSTEM_CONTEXT_X64 struct
and instead push zeroes. The #VC exception handler does not make use of
the debug registers from the saved context and the exception processing
exit code does not attempt to restore the debug register values.

Cc: Eric Dong <eric.dong@intel.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Eric Dong <eric.dong@intel.com>
Signed-off-by: Tom Lendacky <thomas.lendacky@amd.com>
Regression-tested-by: Laszlo Ersek <lersek@redhat.com>
2020-08-17 02:46:39 +00:00
..
Ia32 UefiCpuPkg: Correct some typos. 2020-07-28 01:43:16 +00:00
X64 UefiCpuPkg/CpuExceptionHandler: Add base support for the #VC exception 2020-08-17 02:46:39 +00:00
CpuExceptionCommon.c UefiCpuPkg/CpuExceptionHandler: Add base support for the #VC exception 2020-08-17 02:46:39 +00:00
CpuExceptionCommon.h UefiCpuPkg: Correct some typos. 2020-07-28 01:43:16 +00:00
DxeCpuExceptionHandlerLib.inf UefiCpuPkg/CpuExceptionHandler: Add base support for the #VC exception 2020-08-17 02:46:39 +00:00
DxeCpuExceptionHandlerLib.uni UefiCpuPkg: Replace BSD License with BSD+Patent License 2019-04-09 10:58:28 -07:00
DxeException.c UefiCpuPkg: Replace BSD License with BSD+Patent License 2019-04-09 10:58:28 -07:00
PeiCpuException.c UefiCpuPkg: Replace BSD License with BSD+Patent License 2019-04-09 10:58:28 -07:00
PeiCpuExceptionHandlerLib.inf UefiCpuPkg/CpuExceptionHandler: Add base support for the #VC exception 2020-08-17 02:46:39 +00:00
PeiCpuExceptionHandlerLib.uni UefiCpuPkg: Replace BSD License with BSD+Patent License 2019-04-09 10:58:28 -07:00
PeiDxeSmmCpuException.c UefiCpuPkg/CpuExceptionHandler: Add base support for the #VC exception 2020-08-17 02:46:39 +00:00
SecPeiCpuException.c UefiCpuPkg/CpuExceptionHandler: Add base support for the #VC exception 2020-08-17 02:46:39 +00:00
SecPeiCpuExceptionHandlerLib.inf UefiCpuPkg/CpuExceptionHandler: Add base support for the #VC exception 2020-08-17 02:46:39 +00:00
SecPeiCpuExceptionHandlerLib.uni UefiCpuPkg: Replace BSD License with BSD+Patent License 2019-04-09 10:58:28 -07:00
SmmCpuExceptionHandlerLib.inf UefiCpuPkg/CpuExceptionHandler: Add base support for the #VC exception 2020-08-17 02:46:39 +00:00
SmmCpuExceptionHandlerLib.uni UefiCpuPkg: Replace BSD License with BSD+Patent License 2019-04-09 10:58:28 -07:00
SmmException.c UefiCpuPkg/Smm: Fix various typos 2020-02-10 22:30:07 +00:00
Xcode5SecPeiCpuExceptionHandlerLib.inf UefiCpuPkg/CpuExceptionHandler: Add base support for the #VC exception 2020-08-17 02:46:39 +00:00
Xcode5SecPeiCpuExceptionHandlerLib.uni UefiCpuPkg/CpuExceptionHandler: Make XCODE5 changes toolchain specific 2020-05-11 19:25:33 +00:00