Newer
Older
AMI-Aptio-BIOS-Reversed / ServerCommonPkg / Universal / GetSec / Pei / TxtPei / LtPeiEnableMtrr.c
@Ajax Dong Ajax Dong 2 days ago 871 bytes Restructure the repo
// Decompiled: 0xffe069dc
// Function: LtPeiEnableMtrr
// Module: TxtPei.efi (TXTPEI)

unsigned __int8 __thiscall LtPeiEnableMtrr(_BYTE *this)
{
  int v2; // eax
  unsigned __int8 result; // al

  if ( !(__readmsr(0x8Bu) >> 32) ) /*0xffe069ef*/
  {
    v2 = DebugPrintProtocol(); /*0xffe06a0c*/
    if ( v2 ) /*0xffe06a13*/
      (*(void (__cdecl **)(const char *, int, const char *))(v2 + 4))( /*0xffe06a24*/
        "e:\\hs\\ServerCommonPkg\\Universal\\GetSec\\Pei\\TxtPeiLib.c",
        491,
        "McuRevision != 0");
  }
  result = *(this + 28); /*0xffe06a2a*/
  if ( result ) /*0xffe06a2f*/
  {
    CacheEnable(result << 12); /*0xffe06a37*/
    return (*(int (__cdecl **)(_DWORD, _DWORD, int))(*((_DWORD *)this + 3) + 4))( /*0xffe06a47*/
             *(_DWORD *)this,
             *((_DWORD *)this + 3),
             40000);
  }
  return result; /*0xffe06a4d*/
}