MdlInvariantPreProcessing1
VOID __fastcall MdlInvariantPreProcessing1(INT64 a1, INT64 rdx0, INT64 a3){
_MMPTE *v3;
__int64 v4;
__int64 v5;
__int64 v9;
__int64 v10;
char *v11;
_QWORD *MdlInfo;
UINT64 v13;
char v14;
__int64 v15;
unsigned __int64 v16;
__int64 v17;
__int64 v18;
unsigned int v19;
unsigned __int64 v20;
unsigned __int64 v21;
UINT64 v22;
UINT64 v23;
unsigned __int64 v24;
UINT64 BugCheckOnFailure;
_MMPFN **Priority;
UINT64 Prioritya;
__int128 a2;
char *v29;
int v30;
char v31;
__int16 v32;
char v33;
v4 = *(_QWORD *)(a1 + 168);
v5 = 0i64;
v32 = 0;
v33 = 0;
v9 = *(_QWORD *)(v4 + 8);
if( !*(_QWORD *)v9
&& (KeGetCurrentIrql() >= 2u || *(_DWORD *)(v9 + 40) != -1)
&& (unsigned int)MmMdlPageContentsState((_MMPFN *)v9, (_MMPTE *)2, a3, v3, BugCheckOnFailure, Priority) == 1 )
{
v10 = *(_QWORD *)(*(_QWORD *)(a1 + 168) + 8i64);
v11 = (*(_BYTE *)(v10 + 10) & 5) != 0 ? *(char **)(v10 + 24) : (char *)MmMapLockedPagesSpecifyCache(
(PMDL)v10,
0,
MmCached,
0i64,
0,
0x40000020u);
if( v11 )
{
MdlInfo = MdlInvariantFindMdlInfo(rdx0, *(_QWORD *)(*(_QWORD *)(a1 + 168) + 8i64));
if( MdlInfo )
{
v14 = *(_BYTE *)(v13 + 67);
if( v14 == *(_BYTE *)(v13 + 66) || *((_BYTE *)MdlInfo + 28) == v14 )
{
*(_OWORD *)MdlInfo = 0i64;
*((_OWORD *)MdlInfo + 1) = 0i64;
MdlInfo = 0i64;
*(_QWORD *)(*(_QWORD *)(rdx0 + 224) + 16i64) = 0i64;
v13 = *(_QWORD *)(a1 + 168);
}
}
v15 = *(_QWORD *)(v13 + 8);
if( !MdlInfo )
{
v16 = RtlpComputeCrcInternal(v11, *(unsigned int *)(v15 + 40), 0i64, (__int64)&Crc64Ctrl);
v17 = *(_QWORD *)(a1 + 168);
*((_QWORD *)&a2 + 1) = v16;
v29 = v11;
*(_QWORD *)&a2 = *(_QWORD *)(v17 + 8);
v30 = *(_DWORD *)(a2 + 40);
v31 = *(_BYTE *)(v17 + 67);
MdlInvariantInsertMdlInfo(rdx0, &a2);
return;
}
v18 = *((unsigned int *)MdlInfo + 6);
v19 = *(_DWORD *)(v15 + 40);
if( (_DWORD)v18 == v19 )
{
v21 = *(unsigned int *)(v15 + 40);
}
else
{
v20 = MdlInfo[2];
if( (unsigned __int64)v11 < v20 || (v21 = v19, (unsigned __int64)&v11[v19] > v20 + v18) )
{
v22 = v13;
LOBYTE(v5) = *(_BYTE *)a3 != 4;
v23 = v5 + 4112;
LABEL_28:
VerifierBugCheckIfAppropriate(0xC4ui64, v23, *(_QWORD *)(a3 + 40), v22, (UINT64)v11, Prioritya);
return;
}
}
if( (MmVerifierData & 0x4000) != 0 )
{
v24 = RtlpComputeCrcInternal(v11, v21, 0i64, (__int64)&Crc64Ctrl);
if( MdlInfo[1] != v24 )
{
if( *(_BYTE *)a3 == 4 )
{
v23 = 4112i64;
}
else
{
if( *(_DWORD *)(*(_QWORD *)(v4 + 184) + 8i64) != *(_DWORD *)(a3 + 8) )
{
MdlInfo[1] = v24;
return;
}
v23 = 4113i64;
}
v22 = *(_QWORD *)(a1 + 168);
goto LABEL_28;
}
}
}
}
}Referenced by:
IovpCallDriver1