MiRetryNonPagedAllocation
VOID __fastcall MiRetryNonPagedAllocation(){
_BYTE *v0;
CHAR v1;
char v2;
union _LARGE_INTEGER *v3;
NTSTATUS i;
UINT64 v5;
UINT8 v6;
UINT8 v7;
IRP *Timeout;
struct _KLOCK_QUEUE_HANDLE LockHandle;
memset(&LockHandle, 0, sizeof(LockHandle));
if( KeGetCurrentIrql() <= 1u && (*((_DWORD *)KeGetPcr() + 3243) & 0x10001) == 0 )
{
KeAreInterruptsEnabled(v1, v0);
if( v2 )
{
if( (*((_DWORD *)KeGetCurrentThread() + 325) & 2) == 0
&& !(unsigned int)MiSufficientAvailablePages((INT64)&MiSystemPartition, 0xA0ui64) )
{
v3 = (union _LARGE_INTEGER *)&Mi30Milliseconds;
for( i = 1; ; i = KeWaitForSingleObject(&stru_140C51E28, WrFreePage, 0, 0, v3) )
{
KeAcquireInStackQueuedSpinLock(&qword_140C51E00, &LockHandle);
if( (unsigned int)MiSufficientAvailablePages((INT64)&MiSystemPartition, 0xA0ui64) )
break;
if( i == 1 )
{
if( byte_140C4C624 == 1 )
{
if( dword_140C4C620 == dword_140C51E40 )
goto LABEL_21;
byte_140C4C624 = 0;
}
}
else
{
if( i == 258 )
{
if( !byte_140C4C624 )
{
dword_140C4C620 = dword_140C51E40;
byte_140C4C624 = 1;
}
goto LABEL_21;
}
v3 = (union _LARGE_INTEGER *)&Mi10Milliseconds;
}
KeResetEvent(&stru_140C51E28, v5, v6, v7, Timeout);
KeReleaseInStackQueuedSpinLockFromDpcLevel(&LockHandle);
__writecr8(LockHandle.OldIrql);
}
if( byte_140C4C624 == 1 )
byte_140C4C624 = 0;
LABEL_21:
KeReleaseInStackQueuedSpinLockFromDpcLevel(&LockHandle);
__writecr8(LockHandle.OldIrql);
}
}
}
}Referenced by:
MiGetPoolPages