TtmpFindDeviceByToken

VOID __stdcall TtmpFindDeviceByToken(){
  int v0; 
  __int64 v1; 
  __int64 v2; 
  _QWORD *v3; 
  __int64 *v4; 
  __int64 **v5; 
  __int64 *i; 

  v4 = 0i64;
  v5 = (__int64 **)(v1 + 96);
  for( i = *v5; i != (__int64 *)v5; i = (__int64 *)*i )
  {
    if( *((_DWORD *)i + 4) == v0 && i[3] == v2 )
    {
      v4 = i;
      break;
    }
  }
  if( v3 )
    *v3 = v4;
}

Referenced by:

TtmNotifyDeviceArrival
TtmNotifyDeviceDeparture
TtmNotifyDeviceInput