UefiCpuPkg/MpInitLib: Use AmdSvsmSnpVmsaRmpAdjust() to set/clear VMSA
BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=4654 The RMPADJUST instruction is used to change the VMSA attribute of a page, but the VMSA attribute can only be changed when running at VMPL0. To prepare for running at a less priviledged VMPL, use the AmdSvsmLib library API to perform the RMPADJUST. The AmdSvsmLib library will perform the proper operation on behalf of the caller. Cc: Gerd Hoffmann <kraxel@redhat.com> Cc: Laszlo Ersek <lersek@redhat.com> Cc: Rahul Kumar <rahul1.kumar@intel.com> Cc: Ray Ni <ray.ni@intel.com> Acked-by: Gerd Hoffmann <kraxel@redhat.com> Signed-off-by: Tom Lendacky <thomas.lendacky@amd.com> Acked-by: Ray Ni <ray.ni@intel.com>
This commit is contained in:
committed by
mergify[bot]
parent
6ced1e91ef
commit
ee89b59430
@@ -883,20 +883,6 @@ FillExchangeInfoDataSevEs (
|
||||
IN volatile MP_CPU_EXCHANGE_INFO *ExchangeInfo
|
||||
);
|
||||
|
||||
/**
|
||||
Issue RMPADJUST to adjust the VMSA attribute of an SEV-SNP page.
|
||||
|
||||
@param[in] PageAddress
|
||||
@param[in] VmsaPage
|
||||
|
||||
@return RMPADJUST return value
|
||||
**/
|
||||
UINT32
|
||||
SevSnpRmpAdjust (
|
||||
IN EFI_PHYSICAL_ADDRESS PageAddress,
|
||||
IN BOOLEAN VmsaPage
|
||||
);
|
||||
|
||||
/**
|
||||
Create an SEV-SNP AP save area (VMSA) for use in running the vCPU.
|
||||
|
||||
|
Reference in New Issue
Block a user