VerifierMmMapIoSpace

VOID *__stdcall VerifierMmMapIoSpace(
        ULONG_PTR PhysicalAddress,
        ULONG_PTR NumberOfBytes,
        _MEMORY_CACHING_TYPE CacheType){
  UINT64 v4; 
  _LARGE_INTEGER v5; 
  unsigned __int8 CurrentIrql; 
  UINT64 v8; 
  VOID *v9; 
  VOID *v10; 
  UINT64 v11; 
  VOID *retaddr; 

  v4 = *(_QWORD *)&NumberOfBytes;
  v5 = *(_LARGE_INTEGER *)&PhysicalAddress;
  CurrentIrql = KeGetCurrentIrql();
  if( CurrentIrql > 2u && (MmVerifierData & 1) != 0 )
    VerifierBugCheckIfAppropriate(0xC4ui64, 0x73u, CurrentIrql, v5.anonymous_0.LowPart, NumberOfBytes, v11);
  if( (MmVerifierData & 1) != 0 )
    MmCheckMapIoSpace(v5.anonymous_0.LowPart, v4);
  if( VfFaultsInjectResourceFailure(0i64) == 1 )
    return 0i64;
  if( (MmVerifierData & 0x2000000) != 0 )
  {
    v8 = 4i64;
    if( CacheType != MmCached )
    {
      v8 = 516i64;
      if( CacheType == MmWriteCombined )
        v8 = 1028i64;
    }
    v9 = MmMapIoSpaceEx(v5, v4, v8);
  }
  else
  {
    v9 = (VOID *)((__int64(__fastcall *)(_QWORD, _QWORD, _QWORD))pXdvMmMapIoSpace)(
                   (_LARGE_INTEGER)v5.QuadPart,
                   v4,
                   (unsigned int)CacheType);
  }
  v10 = v9;
  VfAllocPoolNotification(v9, v4);
  if( v10 )
  {
    if( (MmVerifierData & 0x1000) != 0 )
      ViTargetAddToCounter(retaddr, 0xD0ui64, 0xD8ui64, v4);
  }
  return v10;
}

Referenced by:

No references.