PopDirectedDripsUmMarkTestDevices
VOID __stdcall PopDirectedDripsUmMarkTestDevices(){
signed __int32 v0;
signed __int32 v1;
_ETHREAD *CurrentThread;
INT64 v3;
INT64 v4;
__int64 *v5;
__int64 *i;
__int64 *v7;
INT64 v8;
INT64 v9;
int Buffer[2];
__int64 v11;
INT64 v12;
_m_prefetchw(&PopDirectedDripsUmTestDeviceCount);
v0 = PopDirectedDripsUmTestDeviceCount;
do
{
v1 = v0;
v0 = _InterlockedCompareExchange(&PopDirectedDripsUmTestDeviceCount, v0, v0);
}
while( v1 != v0 );
if( v0 )
{
CurrentThread = (_ETHREAD *)KeGetCurrentThread();
--CurrentThread->Tcb.KernelApcDisable;
ExAcquirePushLockSharedEx(&PopDirectedDripsUmLock.Lock, 0i64);
v12 = PopWnfCsEnterScenarioId;
PopDirectedDripsNotify(PopDirectedDripsUmTestPermissive != 0 ? 4 : 2, &v12, v3, v4);
IoLockUnlockPnpDeviceTree(1);
v5 = (__int64 *)*(&PnpReplaceEvent + 831);
for( i = *(__int64 **)(*(&PnpReplaceEvent + 831) + 8i64); i; i = (__int64 *)i[1] )
v5 = i;
while( v5 != (__int64 *)*(&PnpReplaceEvent + 831) )
{
if( v5[10] )
{
Buffer[1] = *((unsigned __int16 *)v5 + 20) >> 1;
v11 = v5[6];
Buffer[0] = 1;
if( RtlLookupElementGenericTableAvl(&PopDirectedDripsUmTestDeviceTable, Buffer) )
PopDirectedDripsMarkCandidateDevice(v5[10]);
}
v7 = (__int64 *)*v5;
if( *v5 )
{
do
{
v5 = v7;
v7 = (__int64 *)v7[1];
}
while( v7 );
}
else
{
v5 = (__int64 *)v5[2];
}
}
IoLockUnlockPnpDeviceTree(0);
PopDirectedDripsNotify(PopDirectedDripsUmTestPermissive != 0 ? 5 : 3, &v12, v8, v9);
PopReleaseRwLock(&PopDirectedDripsUmLock);
}
}Referenced by:
PopDirectedDripsIdleResiliencyCallback