PnpDispatchInterfaceClass

__int64 __fastcall PnpDispatchInterfaceClass(__int64 a1, const WCHAR *a2, __int64 a3, int a4, __int64 a5){
  __int64(__fastcall *v5)(__int64, __int64, int); 
  __int128 *v6; 
  int v7; 
  __int64 v8; 
  int v9; 
  int v10; 
  int v11; 
  int v12; 
  int v13; 
  int v14; 
  unsigned int InterfaceClassMappedProperty; 
  __int128 v17; 
  v5 = 0i64;
  v6 = 0i64;
  v17 = 0i64;
  v7 = a4 - 1;
  if( v7 )
  {
    v8 = (unsigned int)(v7 - 1);
    if( (_DWORD)v8 )
    {
      v9 = v8 - 1;
      if( v9 )
      {
        v10 = v9 - 1;
        if( v10 )
        {
          v11 = v10 - 1;
          if( v11 )
          {
            v12 = v11 - 1;
            if( v12 )
            {
              v13 = v12 - 1;
              if( v13 )
              {
                v14 = v13 - 1;
                if( v14 )
                {
                  if( v14 == 1 )
                    InterfaceClassMappedProperty = CmSetInterfaceClassMappedProperty(
                                                     a1,
                                                     a2,
                                                     *(char **)a5,
                                                     *(_QWORD *)(a5 + 8),
                                                     *(_QWORD *)(a5 + 16),
                                                     *(_DWORD *)(a5 + 24),
                                                     *(_QWORD *)(a5 + 32),
                                                     *(_DWORD *)(a5 + 40));
                  else
                    InterfaceClassMappedProperty = -1073741811;
                }
                else
                {
                  InterfaceClassMappedProperty = CmGetInterfaceClassMappedProperty(
                                                   a1,
                                                   a2,
                                                   *(char **)a5,
                                                   *(_QWORD *)(a5 + 8),
                                                   *(_QWORD *)(a5 + 16),
                                                   *(int **)(a5 + 24),
                                                   *(_QWORD *)(a5 + 32),
                                                   *(_DWORD *)(a5 + 40),
                                                   *(_DWORD **)(a5 + 48));
                }
              }
              else
              {
                InterfaceClassMappedProperty = CmGetInterfaceClassMappedPropertyLocales(
                                                 a1,
                                                 (__int64)a2,
                                                 0i64,
                                                 *(_QWORD *)(a5 + 8),
                                                 *(_WORD **)(a5 + 16),
                                                 *(_DWORD *)(a5 + 24),
                                                 *(_DWORD **)(a5 + 32));
              }
            }
            else
            {
              InterfaceClassMappedProperty = CmGetInterfaceClassMappedPropertyKeys(
                                               a1,
                                               a2,
                                               *(char **)a5,
                                               0,
                                               *(_QWORD *)(a5 + 24),
                                               *(_DWORD *)(a5 + 32),
                                               *(unsigned int **)(a5 + 40));
            }
          }
          else
          {
            if( *(_QWORD *)a5 )
            {
              *(_QWORD *)&v17 = *(_QWORD *)a5;
              v5 = PnpCmMatchCallbackRoutine;
              v6 = &v17;
              *((_QWORD *)&v17 + 1) = *(_QWORD *)(a5 + 8);
            }
            InterfaceClassMappedProperty = CmGetMatchingCommonClassList(
                                             a1,
                                             4u,
                                             (__int64)v5,
                                             (__int64)v6,
                                             *(_QWORD *)(a5 + 16),
                                             *(_DWORD *)(a5 + 24),
                                             *(_QWORD *)(a5 + 32),
                                             *(_DWORD *)(a5 + 40) & 0xFFFF0000);
          }
        }
        else
        {
          InterfaceClassMappedProperty = CmDeleteInterfaceClass(a1, a2, *(_DWORD *)a5 & 0xFFFF0000);
        }
      }
      else
      {
        InterfaceClassMappedProperty = CmCreateInterfaceClass(
                                         a1,
                                         a2,
                                         *(_DWORD *)a5,
                                         (HANDLE *)(a5 + 8),
                                         (_BYTE *)(a5 + 16),
                                         *(_DWORD *)(a5 + 20) & 0xFFFF0000);
      }
    }
    else
    {
      InterfaceClassMappedProperty = CmOpenInterfaceClassRegKey(
                                       a1,
                                       a2,
                                       0i64,
                                       v8,
                                       *(_DWORD *)a5,
                                       *(_BYTE *)(a5 + 4),
                                       *(_QWORD *)(a5 + 8),
                                       (_DWORD *)(a5 + 16));
    }
  }
  else
  {
    InterfaceClassMappedProperty = CmValidateInstallerClassName(a1, a2);
  }
  return PnpMapCmStatusToDispatchStatus(InterfaceClassMappedProperty);
}

Referenced by:

No references.