From: "Min Xu" <min.m.xu@intel.com>
To: devel@edk2.groups.io
Cc: Min Xu <min.m.xu@intel.com>, Eric Dong <eric.dong@intel.com>,
Ray Ni <ray.ni@intel.com>, Brijesh Singh <brijesh.singh@amd.com>,
Erdem Aktas <erdemaktas@google.com>,
Gerd Hoffmann <kraxel@redhat.com>,
James Bottomley <jejb@linux.ibm.com>,
Jiewen Yao <jiewen.yao@intel.com>,
Tom Lendacky <thomas.lendacky@amd.com>,
Guo Dong <guo.dong@intel.com>,
Sean Rhodes <sean@starlabs.systems>,
James Lu <james.lu@intel.com>, Gua Guo <gua.guo@intel.com>,
Michael D Kinney <michael.d.kinney@intel.com>,
Liming Gao <gaoliming@byosoft.com.cn>
Subject: [PATCH V2 0/9] Rename VmgExitLib to CcExitLib
Date: Fri, 4 Nov 2022 07:19:46 +0800 [thread overview]
Message-ID: <20221103231955.1365-1-min.m.xu@intel.com> (raw)
BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=4123
VmgExitLib once was designed to provide interfaces to support #VC handler
and issue VMGEXIT instruction. After TDVF (enable TDX feature in OVMF) is
introduced, this library is updated to support #VE as well. Now the name
of VmgExitLib cannot reflect what the lib does.
This patch-set creates CcExitLib which is a simple copy of VmgExitLib
except some of the API names are renamed with a CcExitLib prefix. For
example VmgExit is renamed as CcExitLibVmgExit.
To make sure the build will not be broken by the renaming, this patch-set
first creates CcExitLib (Patch #1/2). Then VmgExitLib is replaced by
CcExitLib in UefiCpuPkg/UefiPayloadPkg/OvmfPkg (Patch #3/4/5/6). After
that VmgExitLib is deleted (Patch #7/8). At last Maintainers.txt
is updated (Patch #9).
Code: https://github.com/mxu9/edk2/tree/CcExitLib.v2
v2 changes:
- Patch #3 is added to import CcExitLib in OvmfPkg's *.dsc. This is to
prevent the building from being broken in the following patches.
Cc: Eric Dong <eric.dong@intel.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Brijesh Singh <brijesh.singh@amd.com>
Cc: Erdem Aktas <erdemaktas@google.com>
Cc: Gerd Hoffmann <kraxel@redhat.com>
Cc: James Bottomley <jejb@linux.ibm.com>
Cc: Jiewen Yao <jiewen.yao@intel.com>
Cc: Tom Lendacky <thomas.lendacky@amd.com>
Cc: Guo Dong <guo.dong@intel.com>
Cc: Sean Rhodes <sean@starlabs.systems>
Cc: James Lu <james.lu@intel.com>
Cc: Gua Guo <gua.guo@intel.com>
Cc: Michael D Kinney <michael.d.kinney@intel.com>
Cc: Liming Gao <gaoliming@byosoft.com.cn>
Signed-off-by: Min Xu <min.m.xu@intel.com>
Min M Xu (9):
UefiCpuPkg: Add CcExitLib
OvmfPkg: Implement CcExitLib
OvmfPkg: Add CcExitLib in *.dsc
UefiCpuPkg: Use CcExitLib instead of VmgExitLib
UefiPayloadPkg: Use CcExitLib instead of VmgExitLib
OvmfPkg: Use CcExitLib instead of VmgExitLib
OvmfPkg: Delete VmgExitLib
UefiCpuPkg: Delete VmgExitLib
Maintainers: Update the VmgExitLib to CcExitLib
Maintainers.txt | 2 +-
OvmfPkg/AmdSev/AmdSevX64.dsc | 4 +-
OvmfPkg/Bhyve/BhyveX64.dsc | 2 +-
OvmfPkg/CloudHv/CloudHvX64.dsc | 6 +-
OvmfPkg/IntelTdx/IntelTdxX64.dsc | 4 +-
.../DxeMemEncryptSevLib.inf | 2 +-
.../PeiMemEncryptSevLib.inf | 2 +-
.../SecMemEncryptSevLib.inf | 2 +-
.../X64/SnpPageStateChangeInternal.c | 10 +-
.../VmgExitLib.c => CcExitLib/CcExitLib.c} | 23 +--
.../CcExitLib.inf} | 19 +--
.../CcExitTd.h} | 6 +-
.../CcExitVcHandler.c} | 133 +++++++++---------
.../CcExitVcHandler.h} | 10 +-
.../CcExitVeHandler.c} | 8 +-
.../PeiDxeCcExitVcHandler.c} | 12 +-
.../SecCcExitLib.inf} | 16 +--
.../SecCcExitVcHandler.c} | 12 +-
.../X64/TdVmcallCpuid.nasm | 4 +-
OvmfPkg/Microvm/MicrovmX64.dsc | 4 +-
OvmfPkg/OvmfPkgIa32.dsc | 4 +-
OvmfPkg/OvmfPkgIa32X64.dsc | 4 +-
OvmfPkg/OvmfPkgX64.dsc | 6 +-
OvmfPkg/OvmfXen.dsc | 2 +-
OvmfPkg/PlatformPei/AmdSev.c | 10 +-
OvmfPkg/PlatformPei/PlatformPei.inf | 2 +-
.../FvbServicesRuntimeDxe.inf | 2 +-
.../QemuFlashDxe.c | 10 +-
.../Library/{VmgExitLib.h => CcExitLib.h} | 29 ++--
.../CcExitLibNull.c} | 47 +++++--
.../CcExitLibNull.inf} | 14 +-
.../Library/CcExitLibNull/CcExitLibNull.uni | 14 ++
.../DxeCpuExceptionHandlerLib.inf | 2 +-
.../PeiCpuExceptionHandlerLib.inf | 2 +-
.../PeiDxeSmmCpuException.c | 6 +-
.../SecPeiCpuException.c | 6 +-
.../SecPeiCpuExceptionHandlerLib.inf | 2 +-
.../SmmCpuExceptionHandlerLib.inf | 2 +-
.../Xcode5SecPeiCpuExceptionHandlerLib.inf | 2 +-
UefiCpuPkg/Library/MpInitLib/AmdSev.c | 10 +-
UefiCpuPkg/Library/MpInitLib/DxeMpInitLib.inf | 2 +-
UefiCpuPkg/Library/MpInitLib/DxeMpLib.c | 8 +-
UefiCpuPkg/Library/MpInitLib/MpLib.c | 2 +-
UefiCpuPkg/Library/MpInitLib/PeiMpInitLib.inf | 2 +-
UefiCpuPkg/Library/MpInitLib/X64/AmdSev.c | 10 +-
.../Library/VmgExitLibNull/VmTdExitNull.c | 38 -----
.../Library/VmgExitLibNull/VmgExitLibNull.uni | 15 --
UefiCpuPkg/UefiCpuPkg.dec | 4 +-
UefiCpuPkg/UefiCpuPkg.dsc | 4 +-
UefiPayloadPkg/UefiPayloadPkg.dsc | 2 +-
50 files changed, 269 insertions(+), 275 deletions(-)
rename OvmfPkg/Library/{VmgExitLib/VmgExitLib.c => CcExitLib/CcExitLib.c} (89%)
rename OvmfPkg/Library/{VmgExitLib/VmgExitLib.inf => CcExitLib/CcExitLib.inf} (60%)
rename OvmfPkg/Library/{VmgExitLib/VmTdExitHandler.h => CcExitLib/CcExitTd.h} (84%)
rename OvmfPkg/Library/{VmgExitLib/VmgExitVcHandler.c => CcExitLib/CcExitVcHandler.c} (90%)
rename OvmfPkg/Library/{VmgExitLib/VmgExitVcHandler.h => CcExitLib/CcExitVcHandler.h} (85%)
rename OvmfPkg/Library/{VmgExitLib/VmTdExitVeHandler.c => CcExitLib/CcExitVeHandler.c} (94%)
rename OvmfPkg/Library/{VmgExitLib/PeiDxeVmgExitVcHandler.c => CcExitLib/PeiDxeCcExitVcHandler.c} (87%)
rename OvmfPkg/Library/{VmgExitLib/SecVmgExitLib.inf => CcExitLib/SecCcExitLib.inf} (73%)
rename OvmfPkg/Library/{VmgExitLib/SecVmgExitVcHandler.c => CcExitLib/SecCcExitVcHandler.c} (88%)
rename OvmfPkg/Library/{VmgExitLib => CcExitLib}/X64/TdVmcallCpuid.nasm (93%)
rename UefiCpuPkg/Include/Library/{VmgExitLib.h => CcExitLib.h} (86%)
rename UefiCpuPkg/Library/{VmgExitLibNull/VmgExitLibNull.c => CcExitLibNull/CcExitLibNull.c} (76%)
rename UefiCpuPkg/Library/{VmgExitLibNull/VmgExitLibNull.inf => CcExitLibNull/CcExitLibNull.inf} (50%)
create mode 100644 UefiCpuPkg/Library/CcExitLibNull/CcExitLibNull.uni
delete mode 100644 UefiCpuPkg/Library/VmgExitLibNull/VmTdExitNull.c
delete mode 100644 UefiCpuPkg/Library/VmgExitLibNull/VmgExitLibNull.uni
--
2.29.2.windows.2
next reply other threads:[~2022-11-03 23:20 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-11-03 23:19 Min Xu [this message]
2022-11-03 23:19 ` [PATCH V2 1/9] UefiCpuPkg: Add CcExitLib Min Xu
2022-11-04 14:34 ` [edk2-devel] " Lendacky, Thomas
2022-11-05 1:33 ` Min Xu
2022-11-03 23:19 ` [PATCH V2 2/9] OvmfPkg: Implement CcExitLib Min Xu
2022-11-03 23:19 ` [PATCH V2 3/9] OvmfPkg: Add CcExitLib in *.dsc Min Xu
2022-11-03 23:19 ` [PATCH V2 4/9] UefiCpuPkg: Use CcExitLib instead of VmgExitLib Min Xu
2022-11-03 23:19 ` [PATCH V2 5/9] UefiPayloadPkg: " Min Xu
2022-11-03 23:19 ` [PATCH V2 6/9] OvmfPkg: " Min Xu
2022-11-03 23:19 ` [PATCH V2 7/9] OvmfPkg: Delete VmgExitLib Min Xu
2022-11-03 23:19 ` [PATCH V2 8/9] UefiCpuPkg: " Min Xu
2022-11-03 23:19 ` [PATCH V2 9/9] Maintainers: Update the VmgExitLib to CcExitLib Min Xu
2022-11-04 2:04 ` [PATCH V2 0/9] Rename " Yao, Jiewen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-list from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20221103231955.1365-1-min.m.xu@intel.com \
--to=devel@edk2.groups.io \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox