HalpIommuPopulateExceptionList

NTSTATUS __stdcall HalpIommuPopulateExceptionList(){
  unsigned int *v0; 
  NTSTATUS v1; 
  PSTR MemoryInternal; 
  _QWORD *v4; 
  unsigned __int64 v5; 
  __int64 v6; 
  _QWORD *v7; 

  v0 = qword_140C49C28;
  v1 = 0;
  if( qword_140C49C28 && !qword_140C49C28[55] )
  {
    MemoryInternal = HalpMmAllocateMemoryInternal(0x20ui64, MmCached);
    v4 = MemoryInternal;
    if( MemoryInternal )
    {
      *(_OWORD *)MemoryInternal = 0i64;
      *((_OWORD *)MemoryInternal + 1) = 0i64;
      *((_DWORD *)MemoryInternal + 4) = *((unsigned __int16 *)v0 + 4);
      v5 = (unsigned __int64)*v0 << 8;
      v4[3] = v5;
      v6 = v5 | (8i64 * (v0[1] & 0x1F));
      v4[3] = v6;
      v4[3] = v6 | (v0[1] >> 5) & 7;
      v7 = qword_140C49B38;
      if( (_QWORD *)*qword_140C49B38 != &qword_140C49B30 )
        __fastfail(3u);
      *v4 = &qword_140C49B30;
      v4[1] = v7;
      *v7 = v4;
      qword_140C49B38 = v4;
    }
    else
    {
      return -1073741670;
    }
  }
  return v1;
}

Referenced by:

HalpIommuInitializeAll