/* Read the workarea to determine whether SEV is enabled. If enabled, then return the SevEsWorkArea pointer.  */
STATIC SEC_SEV_ES_WORK_AREA* EFIAPI GetSevEsWorkArea(VOID)
/* Read the workarea to determine whether SEV is enabled. If enabled, then return the SevEsWorkArea pointer.  */
STATIC SEC_SEV_ES_WORK_AREA* EFIAPI GetSevEsWorkArea(VOID)
{
  OVMF_WORK_AREA  *WorkArea;
  WorkArea = (OVMF_WORK_AREA *)FixedPcdGet32 (PcdOvmfWorkAreaBase);
  if ((WorkArea == NULL) || (WorkArea->Header.GuestType != CcGuestTypeAmdSev)) {
    return NULL;
  }
  return (SEC_SEV_ES_WORK_AREA *)FixedPcdGet32 (PcdSevEsWorkAreaBase);
}