20#define TD_EXTEND_BUFFER_LEN (64 + 48)
22UINT8 mExtendBuffer[TD_EXTEND_BUFFER_LEN];
52 ASSERT (Data !=
NULL);
54 ASSERT (Index < RTMR_COUNT);
57 return EFI_INVALID_PARAMETER;
64 ASSERT (((
UINTN)ExtendBuffer & 0x3f) == 0);
69 TdCallStatus =
TdCall (TDCALL_TDEXTENDRTMR, (UINT64)(
UINTN)ExtendBuffer, Index, 0, 0);
71 if (TdCallStatus == TDX_EXIT_REASON_SUCCESS) {
73 }
else if (TdCallStatus == TDX_EXIT_REASON_OPERAND_INVALID) {
74 Status = EFI_INVALID_PARAMETER;
76 Status = EFI_DEVICE_ERROR;
80 DEBUG ((DEBUG_ERROR,
"Error returned from TdExtendRtmr call - 0x%lx\n", TdCallStatus));
#define SHA384_DIGEST_SIZE
UINTN EFIAPI TdCall(IN UINT64 Leaf, IN UINT64 Arg1, IN UINT64 Arg2, IN UINT64 Arg3, IN OUT VOID *Results)
VOID *EFIAPI CopyMem(OUT VOID *DestinationBuffer, IN CONST VOID *SourceBuffer, IN UINTN Length)
VOID *EFIAPI ZeroMem(OUT VOID *Buffer, IN UINTN Length)
#define ALIGN_POINTER(Pointer, Alignment)
#define DEBUG(Expression)
EFI_STATUS EFIAPI TdExtendRtmr(IN UINT32 *Data, IN UINT32 DataLen, IN UINT8 Index)