audk/MdePkg/Library
Ceping Sun 68e37f4578 MdePkg/BaseLib: Update TdVmcall to always output the value in R11
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=4572

According to section 3.2 of the [GHCI] spec, if the return status
of MapGPA is "TDG.VP.VMCALL_RETRY", TD must retry this operation
for the pages in the region starting at the GPA specified in R11.

Currently, TDVF has not handled the retry results and always clears
the R11 on unsuccessful return status. For this, the TdVmcall needs
to output the value of R11 on unsuccessful return status to handle
the retry results of MapGPA.

Reference:
[GHCI]: TDX Guest-Host-Communication Interface v1.0
https://cdrdv2.intel.com/v1/dl/getContent/726790

Cc: Liming Gao <gaoliming@byosoft.com.cn>
Cc: Michael D Kinney <michael.d.kinney@intel.com>
Cc: Erdem Aktas <erdemaktas@google.com>
Cc: James Bottomley <jejb@linux.ibm.com>
Cc: Min Xu <min.m.xu@intel.com>
Cc: Tom Lendacky <thomas.lendacky@amd.com>
Cc: Michael Roth <michael.roth@amd.com>
Acked-by: Gerd Hoffmann <kraxel@redhat.com>
Reviewed-by: Jiewen Yao <jiewen.yao@intel.com>
Reviewed-by: Liming Gao <gaoliming@byosoft.com.cn>
Signed-off-by: Ceping Sun <cepingx.sun@intel.com>
2023-11-09 17:15:39 +00:00
..
BaseArmTrngLibNull MdePkg/ArmTrngLib: Add NULL instance of Arm TRNG Library 2022-11-06 16:32:28 +00:00
BaseCacheMaintenanceLib MdePkg: Update code to be more C11 compliant by using __func__ 2023-03-17 17:55:48 +00:00
BaseCacheMaintenanceLibNull MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
BaseCpuLib MdePkg/BaseCpuLib AARCH64: Make asm files BTI compatible 2023-03-30 11:05:22 +00:00
BaseCpuLibNull MdePkg/BaseCpuLibNull: Add Null version of CpuLib for host testing 2020-07-15 05:25:21 +00:00
BaseDebugLibNull MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
BaseDebugLibSerialPort MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
BaseDebugPrintErrorLevelLib MdePkg: Replace BSD License with BSD+Patent License 2019-04-09 10:58:13 -07:00
BaseExtractGuidedSectionLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
BaseFdtLib UefiPayloadPkg: Add FIT support 2023-09-26 07:26:21 +00:00
BaseIoLibIntrinsic MdePkg/BaseIoLibIntrinsic AARCH64: Make asm files BTI compatible 2023-03-30 11:05:22 +00:00
BaseLib MdePkg/BaseLib: Update TdVmcall to always output the value in R11 2023-11-09 17:15:39 +00:00
BaseMemoryLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
BaseMemoryLibMmx MdePkg: Replace Opcode with the corresponding instructions. 2022-03-01 01:45:47 +00:00
BaseMemoryLibOptDxe MdePkg/BaseMemoryLibOptDxe AARCH64: Make asm files BTI compatible 2023-03-30 11:05:22 +00:00
BaseMemoryLibOptPei MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
BaseMemoryLibRepStr MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
BaseMemoryLibSse2 MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
BaseOrderedCollectionRedBlackTreeLib MdePkg: Update code to be more C11 compliant by using __func__ 2023-03-17 17:55:48 +00:00
BasePcdLibNull MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
BasePciCf8Lib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
BasePciExpressLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
BasePciLibCf8 MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
BasePciLibPciExpress MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
BasePciSegmentInfoLibNull MdePkg/PciSegmentInfoLib: Add missing EFIAPI to GetPciSegmentInfo() 2020-06-24 05:46:27 +00:00
BasePciSegmentLibPci MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
BasePeCoffExtraActionLibNull MdePkg: Replace BSD License with BSD+Patent License 2019-04-09 10:58:13 -07:00
BasePeCoffGetEntryPointLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
BasePeCoffLib MdePkg/BasePeCoffLib: Deal with broken debug directories 2023-05-05 08:11:22 +00:00
BasePerformanceLibNull MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
BasePostCodeLibDebug MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
BasePostCodeLibPort80 MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
BasePrintLib MdePkg: Add new status codes to PrintLib 2023-08-07 22:56:02 +00:00
BaseReportStatusCodeLibNull MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
BaseRiscVSbiLib MdePkg: BaseRiscVSbiLib: make more useful to consumers 2023-05-17 23:47:20 +00:00
BaseRngLib MdePkg/Rng: Add GetRngGuid() to RngLib 2023-09-08 09:48:55 +00:00
BaseRngLibNull MdePkg/Rng: Add GetRngGuid() to RngLib 2023-09-08 09:48:55 +00:00
BaseRngLibTimerLib MdePkg/Rng: Add GetRngGuid() to RngLib 2023-09-08 09:48:55 +00:00
BaseS3BootScriptLibNull MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
BaseS3IoLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
BaseS3PciLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
BaseS3PciSegmentLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
BaseS3SmbusLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
BaseS3StallLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
BaseSafeIntLib MdePkg/BaseSafeIntLib: Add LoongArch64 architecture for BaseSafeIntLib. 2022-10-14 02:16:33 +00:00
BaseSerialPortLibNull MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
BaseSerialPortLibRiscVSbiLib MdePkg: add SBI-based SerialPortLib for RISC-V 2023-05-17 23:47:20 +00:00
BaseSmbusLibNull MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
BaseStackCheckLib MdePkg: Remove RVCT support 2022-05-13 14:58:54 +00:00
BaseSynchronizationLib BaseSynchronizationLib: Fix LoongArch64 synchronization functions 2023-05-05 13:10:09 +00:00
BaseTimerLibNullTemplate MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
BaseUefiDecompressLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
CcProbeLibNull MdePkg: Add CcProbeLibNull 2022-04-19 01:26:08 +00:00
DxeCoreEntryPoint MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
DxeCoreHobLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
DxeExtractGuidedSectionLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
DxeHobLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
DxeHstiLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
DxeIoLibCpuIo2 MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
DxePcdLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
DxeRngLib MdePkg/DxeRngLib: Add missing GUID declaration in inf 2023-10-04 15:53:01 +00:00
DxeRuntimeDebugLibSerialPort MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
DxeRuntimePciExpressLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
DxeServicesLib MdePkg/DxeServicesLib: Add LOONGARCH64 architecture 2022-10-14 02:16:33 +00:00
DxeServicesTableLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
DxeSmbusLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
JedecJep106Lib MdePkg: Add new JedecJep106Lib to fetch JEDEC JEP106 manufacturer 2023-04-12 14:29:54 +00:00
MipiSysTLib MdePkg: Add MipiSysTLib library 2023-05-11 07:26:38 +00:00
MmServicesTableLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
MmUnblockMemoryLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
PciSegmentLibSegmentInfo MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
PeiCoreEntryPoint MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
PeiDxePostCodeLibReportStatusCode MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
PeiExtractGuidedSectionLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
PeiHobLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
PeiIoLibCpuIo MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
PeiMemoryAllocationLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
PeiMemoryLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
PeiPcdLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
PeiPciLibPciCfg2 MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
PeiPciSegmentLibPciCfg2 MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
PeiResourcePublicationLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
PeiServicesLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
PeiServicesTablePointerLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
PeiServicesTablePointerLibIdt MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
PeiSmbusLibSmbus2Ppi MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
PeimEntryPoint MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
RegisterFilterLibNull MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
SecPeiDxeTimerLibCpu MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
SmiHandlerProfileLibNull MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
SmmCpuRendezvousLibNull MdePkg: Remove "assert" from SmmCpuRendevousLibNull.c 2022-06-13 01:37:16 +00:00
SmmIoLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
SmmIoLibSmmCpuIo2 MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
SmmLibNull MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
SmmMemLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
SmmMemoryAllocationLib MdePkg: Code optimization to SMM InternalAllocateAlignedPages 2023-06-21 08:00:04 +00:00
SmmPciExpressLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
SmmPciLibPciRootBridgeIo MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
SmmPeriodicSmiLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
SmmServicesTableLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
StandaloneMmDriverEntryPoint MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
StandaloneMmServicesTableLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
TdxLib MdePkg/Library/TdxLib: Remove unnecessary comparison 2023-09-08 14:21:04 +00:00
TraceHubDebugSysTLibNull MdePkg: Add NULL library of TraceHubDebugSysTLib 2023-05-11 07:26:38 +00:00
UefiApplicationEntryPoint MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
UefiBootServicesTableLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
UefiDebugLibConOut MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
UefiDebugLibDebugPortProtocol MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
UefiDebugLibStdErr MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
UefiDevicePathLib MdePkg/UefiDevicePathLib: Fix AcpiEx print logic 2023-10-19 15:20:02 +00:00
UefiDevicePathLibDevicePathProtocol MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
UefiDriverEntryPoint MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
UefiFileHandleLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
UefiLib MdePkg: Added Call for AfterReadyToBoot Event 2023-02-15 12:34:20 +00:00
UefiMemoryAllocationLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
UefiMemoryLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
UefiPciLibPciRootBridgeIo MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
UefiPciSegmentLibPciRootBridgeIo MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
UefiRuntimeLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
UefiRuntimeServicesTableLib MdePkg: Replace BSD License with BSD+Patent License 2019-04-09 10:58:13 -07:00
UefiScsiLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
UefiUsbLib MdePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00