/* During early booting, SEV-ES support code will set a flag to indicate that SEV-ES is enabled. Return the value of this flag as an indicator that SEV-ES is enabled. */
BOOLEAN SevEsIsEnabled(VOID)
/* During early booting, SEV-ES support code will set a flag to indicate that SEV-ES is enabled. Return the value of this flag as an indicator that SEV-ES is enabled. */
BOOLEAN SevEsIsEnabled(VOID)
{
  SEC_SEV_ES_WORK_AREA  *SevEsWorkArea;
  if (!IsSevGuest ()) {
    return FALSE;
  }
  SevEsWorkArea = (SEC_SEV_ES_WORK_AREA *)FixedPcdGet32 (PcdSevEsWorkAreaBase);
  return ((SevEsWorkArea->SevStatusMsrValue & BIT1) != 0);
}