PnpGenerateDeviceIdsHash
NTSTATUS __fastcall PnpGenerateDeviceIdsHash(__int64 a1, __int64 a2, _DWORD *a3){
NTSTATUS result;
int v4;
unsigned int v5;
WCHAR **v6;
WCHAR *v8;
__int64 v9;
_QWORD v10[2];
_UNICODE_STRING DestinationString[2];
UINT64 HashValue;
v10[0] = a1;
LODWORD(HashValue) = 0;
result = 0;
*a3 = 0;
DestinationString[0] = 0i64;
v4 = 0;
v10[1] = a2;
v5 = 0;
v6 = (WCHAR **)v10;
do
{
v8 = *v6;
if( *v6 )
{
while( *v8 )
{
result = RtlInitUnicodeStringEx(DestinationString, v8);
if( result < 0 )
return result;
result = RtlHashUnicodeString(DestinationString, 1u, 0i64, &HashValue);
if( result < 0 )
return result;
v4 += HashValue;
v9 = -1i64;
do
++v9;
while( v8[v9] );
v8 += v9 + 1;
if( !v8 )
break;
}
}
++v5;
++v6;
}
while( v5 < 2 );
*a3 = v4;
return result;
}Referenced by:
PiCreateDriverSwDeviceCallback
PiProcessNewDeviceNode
PipProcessStartPhase3