Author: hpoussin
Date: Mon Apr 14 05:48:38 2008
New Revision: 32948
URL:
http://svn.reactos.org/svn/reactos?rev=32948&view=rev
Log:
Make plug-and-play RPC interface more compatible with MS Windows
Modified:
trunk/reactos/base/services/umpnpmgr/umpnpmgr.c
trunk/reactos/dll/win32/setupapi/cfgmgr.c
trunk/reactos/include/reactos/idl/pnp.idl
Modified: trunk/reactos/base/services/umpnpmgr/umpnpmgr.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/services/umpnpmgr/ump…
==============================================================================
--- trunk/reactos/base/services/umpnpmgr/umpnpmgr.c [iso-8859-1] (original)
+++ trunk/reactos/base/services/umpnpmgr/umpnpmgr.c [iso-8859-1] Mon Apr 14 05:48:38 2008
@@ -35,6 +35,7 @@
#include <umpnpmgr/sysguid.h>
#include <wdmguid.h>
#include <cfgmgr32.h>
+#include <regstr.h>
#include <rpc.h>
#include <rpcdce.h>
@@ -158,37 +159,57 @@
}
+/* Function 0 */
+DWORD PNP_Function0(
+ handle_t hBinding)
+{
+ UNREFERENCED_PARAMETER(hBinding);
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
+}
+
+
+/* Function 1 */
+DWORD PNP_Function1(
+ handle_t hBinding)
+{
+ UNREFERENCED_PARAMETER(hBinding);
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
+}
+
+
/* Function 2 */
-CONFIGRET
-PNP_GetVersion(handle_t BindingHandle,
- unsigned short *Version)
-{
- UNREFERENCED_PARAMETER(BindingHandle);
-
- *Version = 0x0400;
+DWORD PNP_GetVersion(
+ handle_t hBinding,
+ WORD *pVersion)
+{
+ UNREFERENCED_PARAMETER(hBinding);
+
+ *pVersion = 0x0400;
return CR_SUCCESS;
}
/* Function 3 */
-CONFIGRET
-PNP_GetGlobalState(handle_t BindingHandle,
- unsigned long *State,
- unsigned long Flags)
-{
- UNREFERENCED_PARAMETER(BindingHandle);
- UNREFERENCED_PARAMETER(Flags);
-
- *State = CM_GLOBAL_STATE_CAN_DO_UI | CM_GLOBAL_STATE_SERVICES_AVAILABLE;
+DWORD PNP_GetGlobalState(
+ handle_t hBinding,
+ DWORD *pulState,
+ DWORD ulFlags)
+{
+ UNREFERENCED_PARAMETER(hBinding);
+ UNREFERENCED_PARAMETER(ulFlags);
+
+ *pulState = CM_GLOBAL_STATE_CAN_DO_UI | CM_GLOBAL_STATE_SERVICES_AVAILABLE;
return CR_SUCCESS;
}
/* Function 4 */
-CONFIGRET
-PNP_InitDetection(handle_t BindingHandle)
-{
- UNREFERENCED_PARAMETER(BindingHandle);
+DWORD PNP_InitDetection(
+ handle_t hBinding)
+{
+ UNREFERENCED_PARAMETER(hBinding);
DPRINT("PNP_InitDetection() called\n");
return CR_SUCCESS;
@@ -196,14 +217,15 @@
/* Function 5 */
-CONFIGRET
-PNP_ReportLogOn(handle_t BindingHandle,
- BOOL Admin,
- DWORD ProcessId)
+DWORD PNP_ReportLogOn(
+ handle_t hBinding,
+ BOOL Admin,
+ DWORD ProcessId)
{
HANDLE hProcess;
- UNREFERENCED_PARAMETER(BindingHandle);
+ UNREFERENCED_PARAMETER(hBinding);
+ UNREFERENCED_PARAMETER(Admin);
DPRINT("PNP_ReportLogOn(%u, %u) called\n", Admin, ProcessId);
@@ -237,21 +259,22 @@
/* Function 6 */
-CONFIGRET
-PNP_ValidateDeviceInstance(handle_t BindingHandle,
- wchar_t *DeviceInstance,
- DWORD Flags)
+DWORD PNP_ValidateDeviceInstance(
+ handle_t hBinding,
+ LPWSTR pDeviceID,
+ DWORD ulFlags)
{
CONFIGRET ret = CR_SUCCESS;
HKEY hDeviceKey = NULL;
- UNREFERENCED_PARAMETER(BindingHandle);
+ UNREFERENCED_PARAMETER(hBinding);
+ UNREFERENCED_PARAMETER(ulFlags);
DPRINT("PNP_ValidateDeviceInstance(%S %lx) called\n",
- DeviceInstance, Flags);
+ pDeviceID, ulFlags);
if (RegOpenKeyExW(hEnumKey,
- DeviceInstance,
+ pDeviceID,
0,
KEY_READ,
&hDeviceKey))
@@ -274,24 +297,24 @@
/* Function 7 */
-CONFIGRET
-PNP_GetRootDeviceInstance(handle_t BindingHandle,
- wchar_t *DeviceInstance,
- DWORD Length)
+DWORD PNP_GetRootDeviceInstance(
+ handle_t hBinding,
+ LPWSTR pDeviceID,
+ PNP_RPC_STRING_LEN ulLength)
{
CONFIGRET ret = CR_SUCCESS;
- UNREFERENCED_PARAMETER(BindingHandle);
+ UNREFERENCED_PARAMETER(hBinding);
DPRINT("PNP_GetRootDeviceInstance() called\n");
- if (Length < lstrlenW(szRootDeviceId) + 1)
+ if (ulLength < lstrlenW(szRootDeviceId) + 1)
{
ret = CR_BUFFER_SMALL;
goto Done;
}
- lstrcpyW(DeviceInstance,
+ lstrcpyW(pDeviceID,
szRootDeviceId);
Done:
@@ -302,32 +325,32 @@
/* Function 8 */
-CONFIGRET
-PNP_GetRelatedDeviceInstance(handle_t BindingHandle,
- DWORD Relationship,
- wchar_t *DeviceId,
- wchar_t *RelatedDeviceId,
- DWORD Length,
- DWORD Flags)
+DWORD PNP_GetRelatedDeviceInstance(
+ handle_t hBinding,
+ DWORD ulRelationship,
+ LPWSTR pDeviceID,
+ LPWSTR pRelatedDeviceId,
+ PNP_RPC_STRING_LEN *pulLength,
+ DWORD ulFlags)
{
PLUGPLAY_CONTROL_RELATED_DEVICE_DATA PlugPlayData;
CONFIGRET ret = CR_SUCCESS;
NTSTATUS Status;
- UNREFERENCED_PARAMETER(BindingHandle);
- UNREFERENCED_PARAMETER(Flags);
+ UNREFERENCED_PARAMETER(hBinding);
+ UNREFERENCED_PARAMETER(ulFlags);
DPRINT("PNP_GetRelatedDeviceInstance() called\n");
- DPRINT(" Relationship %ld\n", Relationship);
- DPRINT(" DeviceId %S\n", DeviceId);
+ DPRINT(" Relationship %ld\n", ulRelationship);
+ DPRINT(" DeviceId %S\n", pDeviceID);
RtlInitUnicodeString(&PlugPlayData.TargetDeviceInstance,
- DeviceId);
-
- PlugPlayData.Relation = Relationship;
-
- PlugPlayData.RelatedDeviceInstanceLength = Length;
- PlugPlayData.RelatedDeviceInstance = RelatedDeviceId;
+ pDeviceID);
+
+ PlugPlayData.Relation = ulRelationship;
+
+ PlugPlayData.RelatedDeviceInstanceLength = *pulLength;
+ PlugPlayData.RelatedDeviceInstance = pRelatedDeviceId;
Status = NtPlugPlayControl(PlugPlayControlGetRelatedDevice,
(PVOID)&PlugPlayData,
@@ -348,31 +371,31 @@
/* Function 9 */
-CONFIGRET
-PNP_EnumerateSubKeys(handle_t BindingHandle,
- DWORD Branch,
- DWORD Index,
- wchar_t *Buffer,
- DWORD Length,
- DWORD *RequiredLength,
- DWORD Flags)
+DWORD PNP_EnumerateSubKeys(
+ handle_t hBinding,
+ DWORD ulBranch,
+ DWORD ulIndex,
+ LPWSTR Buffer,
+ PNP_RPC_STRING_LEN ulLength,
+ PNP_RPC_STRING_LEN *pulRequiredLen,
+ DWORD ulFlags)
{
CONFIGRET ret = CR_SUCCESS;
HKEY hKey;
DWORD dwError;
- UNREFERENCED_PARAMETER(BindingHandle);
- UNREFERENCED_PARAMETER(Flags);
+ UNREFERENCED_PARAMETER(hBinding);
+ UNREFERENCED_PARAMETER(ulFlags);
DPRINT("PNP_EnumerateSubKeys() called\n");
- switch (Branch)
- {
- case PNP_BRANCH_ENUM:
+ switch (ulBranch)
+ {
+ case PNP_ENUMERATOR_SUBKEYS:
hKey = hEnumKey;
break;
- case PNP_BRANCH_CLASS:
+ case PNP_CLASS_SUBKEYS:
hKey = hClassKey;
break;
@@ -380,11 +403,11 @@
return CR_FAILURE;
}
- *RequiredLength = Length;
+ *pulRequiredLen = ulLength;
dwError = RegEnumKeyExW(hKey,
- Index,
+ ulIndex,
Buffer,
- RequiredLength,
+ pulRequiredLen,
NULL,
NULL,
NULL,
@@ -395,7 +418,7 @@
}
else
{
- (*RequiredLength)++;
+ (*pulRequiredLen)++;
}
DPRINT("PNP_EnumerateSubKeys() done (returns %lx)\n", ret);
@@ -404,51 +427,56 @@
}
+/* Function 10 */
+DWORD PNP_GetDeviceList(
+ handle_t hBinding,
+ LPWSTR pszFilter,
+ LPWSTR Buffer,
+ PNP_RPC_STRING_LEN *pulLength,
+ DWORD ulFlags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
+}
+
+
/* Function 11 */
-CONFIGRET
-PNP_GetDeviceListSize(handle_t BindingHandle,
- wchar_t *Filter,
- unsigned long *Length,
- DWORD Flags)
-{
- UNREFERENCED_PARAMETER(BindingHandle);
- UNREFERENCED_PARAMETER(Filter);
- UNREFERENCED_PARAMETER(Flags);
-
- DPRINT("PNP_GetDeviceListSize() called\n");
-
- /* FIXME */
- *Length = 2;
-
- return CR_SUCCESS;
+DWORD PNP_GetDeviceListSize(
+ handle_t hBinding,
+ LPWSTR pszFilter,
+ PNP_RPC_BUFFER_SIZE *pulLen,
+ DWORD ulFlags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
}
/* Function 12 */
-CONFIGRET
-PNP_GetDepth(handle_t BindingHandle,
- wchar_t *DeviceInstance,
- unsigned long *Depth,
- DWORD Flags)
+DWORD PNP_GetDepth(
+ handle_t hBinding,
+ LPWSTR pszDeviceID,
+ DWORD *pulDepth,
+ DWORD ulFlags)
{
PLUGPLAY_CONTROL_DEPTH_DATA PlugPlayData;
CONFIGRET ret = CR_SUCCESS;
NTSTATUS Status;
- UNREFERENCED_PARAMETER(BindingHandle);
- UNREFERENCED_PARAMETER(Flags);
+ UNREFERENCED_PARAMETER(hBinding);
+ UNREFERENCED_PARAMETER(ulFlags);
DPRINT("PNP_GetDepth() called\n");
RtlInitUnicodeString(&PlugPlayData.DeviceInstance,
- DeviceInstance);
+ pszDeviceID);
Status = NtPlugPlayControl(PlugPlayControlGetDeviceDepth,
(PVOID)&PlugPlayData,
sizeof(PLUGPLAY_CONTROL_DEPTH_DATA));
if (NT_SUCCESS(Status))
{
- *Depth = PlugPlayData.Depth;
+ *pulDepth = PlugPlayData.Depth;
}
else
{
@@ -462,15 +490,15 @@
/* Function 13 */
-CONFIGRET
-PNP_GetDeviceRegProp(handle_t BindingHandle,
- wchar_t *DeviceInstance,
- DWORD Property,
- DWORD *DataType,
- char *Buffer,
- DWORD *TransferLen,
- DWORD *Length,
- DWORD Flags)
+DWORD PNP_GetDeviceRegProp(
+ handle_t hBinding,
+ LPWSTR pDeviceID,
+ DWORD ulProperty,
+ DWORD *pulRegDataType,
+ BYTE *Buffer,
+ PNP_PROP_SIZE *pulTransferLen,
+ PNP_PROP_SIZE *pulLength,
+ DWORD ulFlags)
{
PLUGPLAY_CONTROL_PROPERTY_DATA PlugPlayData;
CONFIGRET ret = CR_SUCCESS;
@@ -478,12 +506,12 @@
HKEY hKey = 0;
NTSTATUS Status;
- UNREFERENCED_PARAMETER(BindingHandle);
- UNREFERENCED_PARAMETER(Flags);
+ UNREFERENCED_PARAMETER(hBinding);
+ UNREFERENCED_PARAMETER(ulFlags);
DPRINT("PNP_GetDeviceRegProp() called\n");
- switch (Property)
+ switch (ulProperty)
{
case CM_DRP_DEVICEDESC:
lpValueName = L"DeviceDesc";
@@ -575,7 +603,7 @@
{
/* Retrieve information from the Registry */
if (RegOpenKeyExW(hEnumKey,
- DeviceInstance,
+ pDeviceID,
0,
KEY_ALL_ACCESS,
&hKey))
@@ -584,9 +612,9 @@
if (RegQueryValueExW(hKey,
lpValueName,
NULL,
- DataType,
- (LPBYTE)Buffer,
- Length))
+ pulRegDataType,
+ Buffer,
+ pulLength))
ret = CR_REGISTRY_ERROR;
/* FIXME: Check buffer size */
@@ -597,11 +625,11 @@
{
/* Retrieve information from the Device Node */
RtlInitUnicodeString(&PlugPlayData.DeviceInstance,
- DeviceInstance);
+ pDeviceID);
PlugPlayData.Buffer = Buffer;
- PlugPlayData.BufferSize = *TransferLen;
-
- switch (Property)
+ PlugPlayData.BufferSize = *pulTransferLen;
+
+ switch (ulProperty)
{
#if 0
case CM_DRP_PHYSICAL_DEVICE_OBJECT_NAME:
@@ -638,7 +666,7 @@
sizeof(PLUGPLAY_CONTROL_PROPERTY_DATA));
if (NT_SUCCESS(Status))
{
- *Length = PlugPlayData.BufferSize;
+ *pulLength = PlugPlayData.BufferSize;
}
else
{
@@ -653,30 +681,30 @@
/* Function 14 */
-CONFIGRET
-PNP_SetDeviceRegProp(handle_t BindingHandle,
- wchar_t *DeviceId,
- unsigned long Property,
- unsigned long DataType,
- char *Buffer,
- unsigned long Length,
- unsigned long Flags)
+DWORD PNP_SetDeviceRegProp(
+ handle_t hBinding,
+ LPWSTR pDeviceId,
+ DWORD ulProperty,
+ DWORD ulDataType,
+ BYTE *Buffer,
+ PNP_PROP_SIZE ulLength,
+ DWORD ulFlags)
{
CONFIGRET ret = CR_SUCCESS;
LPWSTR lpValueName = NULL;
HKEY hKey = 0;
- UNREFERENCED_PARAMETER(BindingHandle);
- UNREFERENCED_PARAMETER(Flags);
+ UNREFERENCED_PARAMETER(hBinding);
+ UNREFERENCED_PARAMETER(ulFlags);
DPRINT("PNP_SetDeviceRegProp() called\n");
- DPRINT("DeviceId: %S\n", DeviceId);
- DPRINT("Property: %lu\n", Property);
- DPRINT("DataType: %lu\n", DataType);
- DPRINT("Length: %lu\n", Length);
-
- switch (Property)
+ DPRINT("DeviceId: %S\n", pDeviceId);
+ DPRINT("Property: %lu\n", ulProperty);
+ DPRINT("DataType: %lu\n", ulDataType);
+ DPRINT("Length: %lu\n", ulLength);
+
+ switch (ulProperty)
{
case CM_DRP_DEVICEDESC:
lpValueName = L"DeviceDesc";
@@ -737,13 +765,13 @@
DPRINT("Value name: %S\n", lpValueName);
if (RegOpenKeyExW(hEnumKey,
- DeviceId,
+ pDeviceId,
0,
- KEY_ALL_ACCESS,
+ KEY_ALL_ACCESS, /* FIXME: so much? */
&hKey))
return CR_INVALID_DEVNODE;
- if (Length == 0)
+ if (ulLength == 0)
{
if (RegDeleteValueW(hKey,
lpValueName))
@@ -754,9 +782,9 @@
if (RegSetValueExW(hKey,
lpValueName,
0,
- DataType,
- (const BYTE*)Buffer,
- Length))
+ ulDataType,
+ Buffer,
+ ulLength))
ret = CR_REGISTRY_ERROR;
}
@@ -769,87 +797,56 @@
/* Function 15 */
-CONFIGRET
-PNP_GetClassInstance(handle_t BindingHandle,
- wchar_t *DeviceId, /* in */
- wchar_t *Buffer, /* out */
- unsigned long Length)
-{
- CONFIGRET ret = CR_SUCCESS;
-
- UNREFERENCED_PARAMETER(BindingHandle);
- UNREFERENCED_PARAMETER(DeviceId);
- UNREFERENCED_PARAMETER(Buffer);
- UNREFERENCED_PARAMETER(Length);
-
- DPRINT("PNP_Get_Class_Instance() called\n");
-
- DPRINT("PNP_Get_Class_Instance() done (returns %lx)\n", ret);
-
- return ret;
+DWORD PNP_GetClassInstance(
+ handle_t hBinding,
+ LPWSTR pDeviceId,
+ LPWSTR pszClassInstance,
+ PNP_RPC_STRING_LEN ulLength)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
}
/* Function 16 */
-CONFIGRET
-PNP_CreateKey(handle_t BindingHandle,
- wchar_t *SubKey,
- unsigned long samDesired,
- unsigned long Flags)
-{
- CONFIGRET ret = CR_SUCCESS;
-
- UNREFERENCED_PARAMETER(BindingHandle);
- UNREFERENCED_PARAMETER(SubKey);
- UNREFERENCED_PARAMETER(samDesired);
- UNREFERENCED_PARAMETER(Flags);
-
- DPRINT("PNP_CreateKey() called\n");
-
- DPRINT("PNP_CreateKey() done (returns %lx)\n", ret);
-
- return ret;
+DWORD PNP_CreateKey(
+ handle_t hBinding,
+ LPWSTR pszSubKey,
+ DWORD samDesired,
+ DWORD ulFlags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
}
/* Function 17 */
-CONFIGRET
-PNP_DeleteRegistryKey(handle_t BindingHandle,
- wchar_t *DeviceId,
- wchar_t *ParentKey,
- wchar_t *ChildKey,
- unsigned long Flags)
-{
- CONFIGRET ret = CR_SUCCESS;
-
- UNREFERENCED_PARAMETER(BindingHandle);
- UNREFERENCED_PARAMETER(DeviceId);
- UNREFERENCED_PARAMETER(ParentKey);
- UNREFERENCED_PARAMETER(ChildKey);
- UNREFERENCED_PARAMETER(Flags);
-
- DPRINT("PNP_DeleteRegistryKey() called\n");
-
- DPRINT("PNP_DeleteRegistryKey() done (returns %lx)\n", ret);
-
- return ret;
+DWORD PNP_DeleteRegistryKey(
+ handle_t hBinding,
+ LPWSTR pszDeviceID,
+ LPWSTR pszParentKey,
+ LPWSTR pszChildKey,
+ DWORD ulFlags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
}
/* Function 18 */
-#if 0
-CONFIGRET
-PNP_GetClassCount(handle_t BindingHandle,
- unsigned long *ClassCount,
- unsigned long Flags)
-{
- HANDLE hKey = NULL;
+DWORD PNP_GetClassCount(
+ handle_t hBinding,
+ DWORD *pulClassCount,
+ DWORD ulFlags)
+{
+ HKEY hKey;
DWORD dwError;
- UNREFERENCED_PARAMETER(BindingHandle);
+ UNREFERENCED_PARAMETER(hBinding);
+ UNREFERENCED_PARAMETER(ulFlags);
dwError = RegOpenKeyExW(HKEY_LOCAL_MACHINE,
- pszRegPathClass,
+ REGSTR_PATH_CLASS,
0,
KEY_QUERY_VALUE,
&hKey);
@@ -860,7 +857,7 @@
NULL,
NULL,
NULL,
- &ClassCount,
+ pulClassCount,
NULL,
NULL,
NULL,
@@ -874,31 +871,30 @@
return CR_SUCCESS;
}
-#endif
/* Function 19 */
-CONFIGRET
-PNP_GetClassName(handle_t BindingHandle,
- wchar_t *ClassGuid,
- wchar_t *Buffer,
- unsigned long *Length,
- unsigned long Flags)
+DWORD PNP_GetClassName(
+ handle_t hBinding,
+ LPWSTR pszClassGuid,
+ LPWSTR Buffer,
+ PNP_RPC_STRING_LEN *pulLength,
+ DWORD ulFlags)
{
WCHAR szKeyName[MAX_PATH];
CONFIGRET ret = CR_SUCCESS;
- HKEY hKey = NULL;
+ HKEY hKey;
DWORD dwSize;
- UNREFERENCED_PARAMETER(BindingHandle);
- UNREFERENCED_PARAMETER(Flags);
+ UNREFERENCED_PARAMETER(hBinding);
+ UNREFERENCED_PARAMETER(ulFlags);
DPRINT("PNP_GetClassName() called\n");
lstrcpyW(szKeyName, L"System\\CurrentControlSet\\Control\\Class");
lstrcatW(szKeyName, L"\\");
- if(lstrlenW(ClassGuid) < sizeof(szKeyName)/sizeof(WCHAR)-lstrlenW(szKeyName))
- lstrcatW(szKeyName, ClassGuid);
+ if(lstrlenW(pszClassGuid) < sizeof(szKeyName)/sizeof(WCHAR)-lstrlenW(szKeyName))
+ lstrcatW(szKeyName, pszClassGuid);
else return CR_INVALID_DATA;
if (RegOpenKeyExW(HKEY_LOCAL_MACHINE,
@@ -908,7 +904,7 @@
&hKey))
return CR_REGISTRY_ERROR;
- dwSize = *Length * sizeof(WCHAR);
+ dwSize = *pulLength * sizeof(WCHAR);
if (RegQueryValueExW(hKey,
L"Class",
NULL,
@@ -916,12 +912,12 @@
(LPBYTE)Buffer,
&dwSize))
{
- *Length = 0;
+ *pulLength = 0;
ret = CR_REGISTRY_ERROR;
}
else
{
- *Length = dwSize / sizeof(WCHAR);
+ *pulLength = dwSize / sizeof(WCHAR);
}
RegCloseKey(hKey);
@@ -933,25 +929,25 @@
/* Function 20 */
-CONFIGRET
-PNP_DeleteClassKey(handle_t BindingHandle,
- wchar_t *ClassGuid,
- unsigned long Flags)
+DWORD PNP_DeleteClassKey(
+ handle_t hBinding,
+ LPWSTR pszClassGuid,
+ DWORD ulFlags)
{
CONFIGRET ret = CR_SUCCESS;
- UNREFERENCED_PARAMETER(BindingHandle);
-
- DPRINT("PNP_GetClassName(%S, %lx) called\n", ClassGuid, Flags);
-
- if (Flags & CM_DELETE_CLASS_SUBKEYS)
- {
- if (RegDeleteTreeW(hClassKey, ClassGuid) != ERROR_SUCCESS)
+ UNREFERENCED_PARAMETER(hBinding);
+
+ DPRINT("PNP_GetClassName(%S, %lx) called\n", pszClassGuid, ulFlags);
+
+ if (ulFlags & CM_DELETE_CLASS_SUBKEYS)
+ {
+ if (RegDeleteTreeW(hClassKey, pszClassGuid) != ERROR_SUCCESS)
ret = CR_REGISTRY_ERROR;
}
else
{
- if (RegDeleteKeyW(hClassKey, ClassGuid) != ERROR_SUCCESS)
+ if (RegDeleteKeyW(hClassKey, pszClassGuid) != ERROR_SUCCESS)
ret = CR_REGISTRY_ERROR;
}
@@ -961,81 +957,161 @@
}
+/* Function 21 */
+DWORD PNP_GetInterfaceDeviceAlias(
+ handle_t hBinding,
+ LPWSTR pszInterfaceDevice,
+ GUID *AliasInterfaceGuid,
+ LPWSTR pszAliasInterfaceDevice,
+ PNP_RPC_STRING_LEN *pulLength,
+ PNP_RPC_STRING_LEN *pulTransferLen,
+ DWORD ulFlags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
+}
+
+
+/* Function 22 */
+DWORD PNP_GetInterfaceDeviceList(
+ handle_t hBinding,
+ GUID *InterfaceGuid,
+ LPWSTR pszDeviceID,
+ BYTE *Buffer,
+ PNP_RPC_BUFFER_SIZE *pulLength,
+ DWORD ulFlags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
+}
+
+
+/* Function 23 */
+DWORD PNP_GetInterfaceDeviceListSize(
+ handle_t hBinding,
+ PNP_RPC_BUFFER_SIZE *pulLen,
+ GUID *InterfaceGuid,
+ LPWSTR pszDeviceID,
+ DWORD ulFlags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
+}
+
+
+/* Function 24 */
+DWORD PNP_RegisterDeviceClassAssociation(
+ handle_t hBinding,
+ LPWSTR pszDeviceID,
+ GUID *InterfaceGuid,
+ LPWSTR pszReference,
+ LPWSTR pszSymLink,
+ PNP_RPC_STRING_LEN *pulLength,
+ PNP_RPC_STRING_LEN *pulTransferLen,
+ DWORD ulFlags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
+}
+
+
+/* Function 25 */
+DWORD PNP_UnregisterDeviceClassAssociation(
+ handle_t hBinding,
+ LPWSTR pszInterfaceDevice,
+ DWORD ulFlags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
+}
+
+
+/* Function 26 */
+DWORD PNP_GetClassRegProp(
+ handle_t hBinding,
+ LPWSTR pszClassGuid,
+ DWORD ulProperty,
+ DWORD *pulRegDataType,
+ BYTE *Buffer,
+ PNP_RPC_STRING_LEN *pulTransferLen,
+ PNP_RPC_STRING_LEN *pulLength,
+ DWORD ulFlags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
+}
+
+
+/* Function 27 */
+DWORD PNP_SetClassRegProp(
+ handle_t hBinding,
+ LPWSTR *pszClassGuid,
+ DWORD ulProperty,
+ DWORD ulDataType,
+ BYTE *Buffer,
+ PNP_PROP_SIZE ulLength,
+ DWORD ulFlags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
+}
+
+
/* Function 28 */
-CONFIGRET
-PNP_CreateDevInst(handle_t BindingHandle,
- wchar_t *DeviceId, /* [in, out, string, size_is(Length)] */
- wchar_t *ParentDeviceId, /* [in, string] */
- unsigned long Length, /* [in] */
- unsigned long Flags) /* [in] */
-{
- CONFIGRET ret = CR_CALL_NOT_IMPLEMENTED;
-
- UNREFERENCED_PARAMETER(BindingHandle);
- UNREFERENCED_PARAMETER(DeviceId);
- UNREFERENCED_PARAMETER(ParentDeviceId);
- UNREFERENCED_PARAMETER(Length);
- UNREFERENCED_PARAMETER(Flags);
-
- DPRINT1("PNP_CreateDevInst() called\n");
-
- DPRINT1("PNP_CreateDevInst() done (returns %lx)\n", ret);
-
- return ret;
+DWORD PNP_CreateDevInst(
+ handle_t hBinding,
+ LPWSTR pszDeviceID,
+ LPWSTR pszParentDeviceID,
+ PNP_RPC_STRING_LEN ulLength,
+ DWORD ulFlags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
}
/* Function 29 */
-CONFIGRET
-PNP_DeviceInstanceAction(handle_t BindingHandle,
- unsigned long MajorAction,
- unsigned long MinorAction,
- wchar_t *DeviceInstance1,
- wchar_t *DeviceInstance2)
+#define PNP_DEVINST_SETUP 0x3
+#define PNP_DEVINST_ENABLE 0x4
+#define PNP_DEVINST_REENUMERATE 0x7
+DWORD PNP_DeviceInstanceAction(
+ handle_t hBinding,
+ DWORD ulMajorAction,
+ DWORD ulMinorAction,
+ LPWSTR pszDeviceInstance1,
+ LPWSTR pszDeviceInstance2)
{
CONFIGRET ret = CR_SUCCESS;
- UNREFERENCED_PARAMETER(BindingHandle);
- UNREFERENCED_PARAMETER(MinorAction);
- UNREFERENCED_PARAMETER(DeviceInstance1);
- UNREFERENCED_PARAMETER(DeviceInstance2);
+ UNREFERENCED_PARAMETER(hBinding);
+ UNREFERENCED_PARAMETER(ulMinorAction);
+ UNREFERENCED_PARAMETER(pszDeviceInstance1);
+ UNREFERENCED_PARAMETER(pszDeviceInstance2);
DPRINT("PNP_DeviceInstanceAction() called\n");
- switch (MajorAction)
- {
- case 2:
- DPRINT("Move device instance\n");
- /* FIXME */
- ret = CR_CALL_NOT_IMPLEMENTED;
- break;
-
- case 3:
+ switch (ulMajorAction)
+ {
+ case PNP_DEVINST_SETUP:
DPRINT("Setup device instance\n");
/* FIXME */
ret = CR_CALL_NOT_IMPLEMENTED;
break;
- case 4:
+ case PNP_DEVINST_ENABLE:
DPRINT("Enable device instance\n");
/* FIXME */
ret = CR_CALL_NOT_IMPLEMENTED;
break;
- case 5:
- DPRINT("Disable device instance\n");
- /* FIXME */
- ret = CR_CALL_NOT_IMPLEMENTED;
- break;
-
- case 7:
+ case PNP_DEVINST_REENUMERATE:
DPRINT("Reenumerate device instance\n");
/* FIXME */
ret = CR_CALL_NOT_IMPLEMENTED;
break;
default:
- DPRINT1("Unknown function %lu\n", MajorAction);
+ DPRINT1("Unknown function %lu\n", ulMajorAction);
ret = CR_CALL_NOT_IMPLEMENTED;
}
@@ -1046,24 +1122,24 @@
/* Function 30 */
-CONFIGRET
-PNP_GetDeviceStatus(handle_t BindingHandle,
- wchar_t *DeviceInstance,
- unsigned long *pStatus,
- unsigned long *pProblem,
- DWORD Flags)
+DWORD PNP_GetDeviceStatus(
+ handle_t hBinding,
+ LPWSTR pDeviceID,
+ DWORD *pulStatus,
+ DWORD *pulProblem,
+ DWORD ulFlags)
{
PLUGPLAY_CONTROL_STATUS_DATA PlugPlayData;
CONFIGRET ret = CR_SUCCESS;
NTSTATUS Status;
- UNREFERENCED_PARAMETER(BindingHandle);
- UNREFERENCED_PARAMETER(Flags);
+ UNREFERENCED_PARAMETER(hBinding);
+ UNREFERENCED_PARAMETER(ulFlags);
DPRINT("PNP_GetDeviceStatus() called\n");
RtlInitUnicodeString(&PlugPlayData.DeviceInstance,
- DeviceInstance);
+ pDeviceID);
PlugPlayData.Operation = 0; /* Get status */
Status = NtPlugPlayControl(PlugPlayControlDeviceStatus,
@@ -1071,8 +1147,8 @@
sizeof(PLUGPLAY_CONTROL_STATUS_DATA));
if (NT_SUCCESS(Status))
{
- *pStatus = PlugPlayData.DeviceStatus;
- *pProblem = PlugPlayData.DeviceProblem;
+ *pulStatus = PlugPlayData.DeviceStatus;
+ *pulProblem = PlugPlayData.DeviceProblem;
}
else
{
@@ -1086,48 +1162,38 @@
/* Function 31 */
-CONFIGRET
-PNP_SetDeviceProblem(handle_t BindingHandle,
- wchar_t *DeviceInstance,
- unsigned long Problem,
- DWORD Flags)
-{
- CONFIGRET ret = CR_SUCCESS;
-
- UNREFERENCED_PARAMETER(BindingHandle);
- UNREFERENCED_PARAMETER(DeviceInstance);
- UNREFERENCED_PARAMETER(Problem);
- UNREFERENCED_PARAMETER(Flags);
-
- DPRINT1("PNP_SetDeviceProblem() called\n");
-
- /* FIXME */
-
- DPRINT1("PNP_SetDeviceProblem() done (returns %lx)\n", ret);
-
- return ret;
-}
-
+DWORD PNP_SetDeviceProblem(
+ handle_t hBinding,
+ LPWSTR pDeviceID,
+ DWORD ulProblem,
+ DWORD ulFlags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
+}
+
+
+/* Function 32 */
+DWORD PNP_DisableDevInst(
+ handle_t hBinding,
+ LPWSTR pDeviceID,
+ PPNP_VETO_TYPE pVetoType,
+ LPWSTR pszVetoName,
+ DWORD ulNameLength,
+ DWORD ulFlags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
+}
/* Function 33 */
-CONFIGRET
-PNP_UninstallDevInst(handle_t BindingHandle,
- wchar_t *DeviceInstance,
- DWORD Flags)
-{
- CONFIGRET ret = CR_SUCCESS;
-
- UNREFERENCED_PARAMETER(BindingHandle);
- UNREFERENCED_PARAMETER(DeviceInstance);
- UNREFERENCED_PARAMETER(Flags);
-
- DPRINT1("PNP_UninstallDevInst() called\n");
-
- /* FIXME */
-
- DPRINT1("PNP_UninstallDevInst() done (returns %lx)\n", ret);
-
- return ret;
+DWORD PNP_UninstallDevInst(
+ handle_t hBinding,
+ LPWSTR pDeviceID,
+ DWORD ulFlags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
}
@@ -1174,11 +1240,11 @@
/* Function 34 */
-CONFIGRET
-PNP_AddID(handle_t BindingHandle,
- wchar_t *DeviceInstance,
- wchar_t *DeviceId,
- DWORD Flags)
+DWORD PNP_AddID(
+ handle_t hBinding,
+ LPWSTR pszDeviceID,
+ LPWSTR pszID,
+ DWORD ulFlags)
{
CONFIGRET ret = CR_SUCCESS;
HKEY hDeviceKey;
@@ -1186,15 +1252,15 @@
DWORD dwDeviceIdListSize;
WCHAR szDeviceIdList[512];
- UNREFERENCED_PARAMETER(BindingHandle);
+ UNREFERENCED_PARAMETER(hBinding);
DPRINT("PNP_AddID() called\n");
- DPRINT(" DeviceInstance: %S\n", DeviceInstance);
- DPRINT(" DeviceId: %S\n", DeviceId);
- DPRINT(" Flags: %lx\n", Flags);
+ DPRINT(" DeviceInstance: %S\n", pszDeviceID);
+ DPRINT(" DeviceId: %S\n", pszID);
+ DPRINT(" Flags: %lx\n", ulFlags);
if (RegOpenKeyExW(hEnumKey,
- DeviceInstance,
+ pszDeviceID,
0,
KEY_QUERY_VALUE | KEY_SET_VALUE,
&hDeviceKey) != ERROR_SUCCESS)
@@ -1203,7 +1269,7 @@
return CR_INVALID_DEVNODE;
}
- pszSubKey = (Flags & CM_ADD_ID_COMPATIBLE) ? L"CompatibleIDs" :
L"HardwareID";
+ pszSubKey = (ulFlags & CM_ADD_ID_COMPATIBLE) ? L"CompatibleIDs" :
L"HardwareID";
dwDeviceIdListSize = 512 * sizeof(WCHAR);
if (RegQueryValueExW(hDeviceKey,
@@ -1219,7 +1285,7 @@
}
/* Check whether the device ID is already in use */
- if (CheckForDeviceId(szDeviceIdList, DeviceId))
+ if (CheckForDeviceId(szDeviceIdList, pszDeviceID))
{
DPRINT("Device ID was found in the ID string!\n");
ret = CR_SUCCESS;
@@ -1227,7 +1293,7 @@
}
/* Append the Device ID */
- AppendDeviceId(szDeviceIdList, &dwDeviceIdListSize, DeviceId);
+ AppendDeviceId(szDeviceIdList, &dwDeviceIdListSize, pszID);
if (RegSetValueExW(hDeviceKey,
pszSubKey,
@@ -1249,9 +1315,47 @@
}
+/* Function 35 */
+DWORD PNP_RegisterDriver(
+ handle_t hBinding,
+ LPWSTR pszDeviceID,
+ DWORD ulFlags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
+}
+
+
+/* Function 36 */
+DWORD PNP_QueryRemove(
+ handle_t hBinding,
+ LPWSTR pszDeviceID,
+ PPNP_VETO_TYPE pVetoType,
+ LPWSTR pszVetoName,
+ DWORD ulNameLength,
+ DWORD ulFlags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
+}
+
+
+/* Function 37 */
+DWORD PNP_RequestDeviceEject(
+ handle_t hBinding,
+ LPWSTR pszDeviceID,
+ PPNP_VETO_TYPE pVetoType,
+ LPWSTR pszVetoName,
+ DWORD ulNameLength,
+ DWORD ulFlags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
+}
+
/* Function 38 */
CONFIGRET
-PNP_IsDockStationPresent(handle_t BindingHandle,
+PNP_IsDockStationPresent(handle_t hBinding,
BOOL *Present)
{
HKEY hKey;
@@ -1260,7 +1364,7 @@
DWORD dwSize;
CONFIGRET ret = CR_SUCCESS;
- UNREFERENCED_PARAMETER(BindingHandle);
+ UNREFERENCED_PARAMETER(hBinding);
DPRINT1("PNP_IsDockStationPresent() called\n");
@@ -1303,189 +1407,397 @@
/* Function 39 */
-CONFIGRET
-PNP_RequestEjectPC(handle_t BindingHandle)
-{
- CONFIGRET ret = CR_SUCCESS;
-
- UNREFERENCED_PARAMETER(BindingHandle);
-
- DPRINT1("PNP_RequestEjectPC() called\n");
-
- ret = CR_FAILURE; /* FIXME */
-
- DPRINT1("PNP_RequestEjectPC() done (returns %lx)\n", ret);
-
- return ret;
+DWORD PNP_RequestEjectPC(
+ handle_t hBinding)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
}
/* Function 40 */
-CONFIGRET
-PNP_HwProfFlags(handle_t BindingHandle,
- DWORD Action,
- wchar_t *DeviceId,
- DWORD ProfileId,
- DWORD *Value, // out
- DWORD Flags)
-{
- CONFIGRET ret = CR_SUCCESS;
-
- UNREFERENCED_PARAMETER(BindingHandle);
- UNREFERENCED_PARAMETER(Action);
- UNREFERENCED_PARAMETER(DeviceId);
- UNREFERENCED_PARAMETER(ProfileId);
- UNREFERENCED_PARAMETER(Value);
- UNREFERENCED_PARAMETER(Flags);
-
- DPRINT1("PNP_HwProfFlags() called\n");
-
- ret = CR_CALL_NOT_IMPLEMENTED; /* FIXME */
-
- DPRINT1("PNP_HwProfFlags() done (returns %lx)\n", ret);
-
- return ret;
+DWORD PNP_HwProfFlags(
+ handle_t hBinding,
+ DWORD ulAction,
+ LPWSTR pDeviceID,
+ DWORD ulConfig,
+ DWORD *pulValue,
+ PPNP_VETO_TYPE pVetoType,
+ LPWSTR pszVetoName,
+ DWORD ulNameLength,
+ DWORD ulFlags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
+}
+
+
+/* Function 41 */
+DWORD PNP_GetHwProfInfo(
+ handle_t hBinding,
+ DWORD ulIndex,
+ HWPROFILEINFO *pHWProfileInfo,
+ DWORD ulProfileInfoSize,
+ DWORD ulFlags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
}
/* Function 42 */
-CONFIGRET
-PNP_AddEmptyLogConf(handle_t BindingHandle,
- wchar_t *DeviceInstance,
- unsigned long ulPriority,
- unsigned long *pulLogConfTag,
- unsigned long ulFlags)
-{
- CONFIGRET ret = CR_SUCCESS;
-
- UNREFERENCED_PARAMETER(BindingHandle);
- UNREFERENCED_PARAMETER(DeviceInstance);
- UNREFERENCED_PARAMETER(ulPriority);
- UNREFERENCED_PARAMETER(ulFlags);
-
- DPRINT1("PNP_AddEmptyLogConf() called\n");
-
- *pulLogConfTag = 0; /* FIXME */
-
- DPRINT1("PNP_AddEmptyLogConf() done (returns %lx)\n", ret);
-
- return ret;
+DWORD PNP_AddEmptyLogConf(
+ handle_t hBinding,
+ LPWSTR pDeviceID,
+ DWORD ulPriority,
+ DWORD *pulLogConfTag,
+ DWORD ulFlags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
}
/* Function 43 */
-CONFIGRET
-PNP_FreeLogConf(handle_t BindingHandle,
- wchar_t *DeviceInstance,
- unsigned long ulType,
- unsigned long ulLogConfTag,
- unsigned long ulFlags)
-{
- CONFIGRET ret = CR_SUCCESS;
-
- UNREFERENCED_PARAMETER(BindingHandle);
- UNREFERENCED_PARAMETER(DeviceInstance);
- UNREFERENCED_PARAMETER(ulType);
- UNREFERENCED_PARAMETER(ulLogConfTag);
- UNREFERENCED_PARAMETER(ulFlags);
-
- DPRINT1("PNP_FreeLogConf() called\n");
-
-
- DPRINT1("PNP_FreeLogConf() done (returns %lx)\n", ret);
-
- return ret;
+DWORD PNP_FreeLogConf(
+ handle_t hBinding,
+ LPWSTR pDeviceID,
+ DWORD ulLogConfType,
+ DWORD ulLogConfTag,
+ DWORD ulFlags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
}
/* Function 44 */
-CONFIGRET
-PNP_GetFirstLogConf(handle_t BindingHandle,
- wchar_t *DeviceInstance,
- unsigned long ulPriority,
- unsigned long *pulLogConfTag,
- unsigned long ulFlags)
-{
- CONFIGRET ret = CR_SUCCESS;
-
- UNREFERENCED_PARAMETER(BindingHandle);
- UNREFERENCED_PARAMETER(DeviceInstance);
- UNREFERENCED_PARAMETER(ulPriority);
- UNREFERENCED_PARAMETER(ulFlags);
-
- DPRINT1("PNP_GetFirstLogConf() called\n");
-
- *pulLogConfTag = 0; /* FIXME */
-
- DPRINT1("PNP_GetFirstLogConf() done (returns %lx)\n", ret);
-
- return ret;
+DWORD PNP_GetFirstLogConf(
+ handle_t hBinding,
+ LPWSTR pDeviceID,
+ DWORD ulLogConfType,
+ DWORD *pulLogConfTag,
+ DWORD ulFlags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
}
/* Function 45 */
-CONFIGRET
-PNP_GetNextLogConf(handle_t BindingHandle,
- wchar_t *DeviceInstance,
- unsigned long ulLogConfType,
- unsigned long ulCurrentTag,
- unsigned long *pulNextTag,
- unsigned long ulFlags)
-{
- CONFIGRET ret = CR_SUCCESS;
-
- UNREFERENCED_PARAMETER(BindingHandle);
- UNREFERENCED_PARAMETER(DeviceInstance);
- UNREFERENCED_PARAMETER(ulLogConfType);
- UNREFERENCED_PARAMETER(ulCurrentTag);
- UNREFERENCED_PARAMETER(ulFlags);
-
- DPRINT1("PNP_GetNextLogConf() called\n");
-
- *pulNextTag = 0; /* FIXME */
-
- DPRINT1("PNP_GetNextLogConf() done (returns %lx)\n", ret);
-
- return ret;
+DWORD PNP_GetNextLogConf(
+ handle_t hBinding,
+ LPWSTR pDeviceID,
+ DWORD ulLogConfType,
+ DWORD ulCurrentTag,
+ DWORD *pulNextTag,
+ DWORD ulFlags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
}
/* Function 46 */
-CONFIGRET
-PNP_GetLogConfPriority(handle_t BindingHandle,
- wchar_t *DeviceInstance,
- unsigned long ulLogConfType,
- unsigned long ulCurrentTag,
- unsigned long *pPriority,
- unsigned long ulFlags)
-{
- CONFIGRET ret = CR_SUCCESS;
-
- UNREFERENCED_PARAMETER(BindingHandle);
- UNREFERENCED_PARAMETER(DeviceInstance);
- UNREFERENCED_PARAMETER(ulLogConfType);
- UNREFERENCED_PARAMETER(ulCurrentTag);
- UNREFERENCED_PARAMETER(ulFlags);
-
- DPRINT1("PNP_GetLogConfPriority() called\n");
-
- *pPriority = 0; /* FIXME */
-
- DPRINT1("PNP_GetLogConfPriority() done (returns %lx)\n", ret);
-
- return ret;
+DWORD PNP_GetLogConfPriority(
+ handle_t hBinding,
+ LPWSTR pDeviceID,
+ DWORD ulType,
+ DWORD ulTag,
+ DWORD *pPriority,
+ DWORD ulFlags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
+}
+
+
+/* Function 47 */
+DWORD PNP_AddResDes(
+ handle_t hBinding,
+ LPWSTR pDeviceID,
+ DWORD ulLogConfTag,
+ DWORD ulLogConfType,
+ RESOURCEID ResourceID,
+ DWORD *pulResourceTag,
+ BYTE *ResourceData,
+ PNP_RPC_BUFFER_SIZE ResourceLen,
+ DWORD ulFlags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
+}
+
+
+/* Function 48 */
+DWORD PNP_FreeResDes(
+ handle_t hBinding,
+ LPWSTR pDeviceID,
+ DWORD ulLogConfTag,
+ DWORD ulLogConfType,
+ RESOURCEID ResourceID,
+ DWORD ulResourceTag,
+ DWORD *pulPreviousResType,
+ DWORD *pulPreviousResTag,
+ DWORD ulFlags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
+}
+
+
+/* Function 49 */
+DWORD PNP_GetNextResDes(
+ handle_t hBinding,
+ LPWSTR pDeviceID,
+ DWORD ulLogConfTag,
+ DWORD ulLogConfType,
+ RESOURCEID ResourceID,
+ DWORD ulResourceTag,
+ DWORD *pulNextResType,
+ DWORD *pulNextResTag,
+ DWORD ulFlags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
+}
+
+
+/* Function 50 */
+DWORD PNP_GetResDesData(
+ handle_t hBinding,
+ LPWSTR pDeviceID,
+ DWORD ulLogConfTag,
+ DWORD ulLogConfType,
+ RESOURCEID ResourceID,
+ DWORD ulResourceTag,
+ BYTE *Buffer,
+ PNP_RPC_BUFFER_SIZE BufferLen,
+ DWORD ulFlags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
+}
+
+
+/* Function 51 */
+DWORD PNP_GetResDesDataSize(
+ handle_t hBinding,
+ LPWSTR pDeviceID,
+ DWORD ulLogConfTag,
+ DWORD ulLogConfType,
+ RESOURCEID ResourceID,
+ DWORD ulResourceTag,
+ DWORD *pulSize,
+ DWORD ulFlags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
+}
+
+
+/* Function 52 */
+DWORD PNP_ModifyResDes(
+ handle_t hBinding,
+ LPWSTR pDeviceID,
+ DWORD ulLogConfTag,
+ DWORD ulLogConfType,
+ RESOURCEID CurrentResourceID,
+ RESOURCEID NewResourceID,
+ DWORD ulResourceTag,
+ BYTE *ResourceData,
+ PNP_RPC_BUFFER_SIZE ResourceLen,
+ DWORD ulFlags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
+}
+
+
+/* Function 53 */
+DWORD PNP_DetectResourceConflict(
+ handle_t hBinding,
+ LPWSTR pDeviceID,
+ RESOURCEID ResourceID,
+ BYTE *ResourceData,
+ PNP_RPC_BUFFER_SIZE ResourceLen,
+ BOOL *pbConflictDetected,
+ DWORD ulFlags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
+}
+
+
+/* Function 54 */
+DWORD PNP_QueryResConfList(
+ handle_t hBinding,
+ LPWSTR pDeviceID,
+ RESOURCEID ResourceID,
+ BYTE *ResourceData,
+ PNP_RPC_BUFFER_SIZE ResourceLen,
+ BYTE *Buffer,
+ PNP_RPC_BUFFER_SIZE BufferLen,
+ DWORD ulFlags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
+}
+
+
+/* Function 55 */
+DWORD PNP_Function55(
+ handle_t hBinding)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
+}
+
+
+/* Function 56 */
+DWORD PNP_Function56(
+ handle_t hBinding)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
+}
+
+
+/* Function 57 */
+DWORD PNP_Function57(
+ handle_t hBinding)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
}
/* Function 58 */
CONFIGRET
-PNP_RunDetection(handle_t BindingHandle,
- unsigned long Flags)
-{
- UNREFERENCED_PARAMETER(BindingHandle);
- UNREFERENCED_PARAMETER(Flags);
-
- DPRINT("PNP_RunDetection() called\n");
+PNP_RunDetection(
+ handle_t BindingHandle,
+ DWORD ulFlags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
+}
+
+
+/* Function 59 */
+DWORD PNP_Function59(
+ handle_t hBinding)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
+}
+
+
+/* Function 60 */
+DWORD PNP_Function60(
+ handle_t hBinding)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
+}
+
+
+/* Function 61 */
+DWORD PNP_GetCustomDevProp(
+ handle_t hBinding,
+ LPWSTR pDeviceID,
+ LPWSTR CustomPropName,
+ DWORD *pulRegDataType,
+ BYTE *Buffer,
+ PNP_RPC_STRING_LEN *pulTransferLen,
+ PNP_RPC_STRING_LEN *pulLength,
+ DWORD ulFlags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
+}
+
+
+/* Function 62 */
+DWORD PNP_GetVersionInternal(
+ handle_t hBinding,
+ WORD *pwVersion)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
+}
+
+
+/* Function 63 */
+DWORD PNP_GetBlockedDriverInfo(
+ handle_t hBinding,
+ BYTE *Buffer,
+ PNP_RPC_BUFFER_SIZE *pulTransferLen,
+ PNP_RPC_BUFFER_SIZE *pulLength,
+ DWORD ulFlags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
+}
+
+
+/* Function 64 */
+DWORD PNP_GetServerSideDeviceInstallFlags(
+ handle_t hBinding,
+ DWORD *pulSSDIFlags,
+ DWORD ulFlags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
+}
+
+
+/* Function 65 */
+DWORD PNP_GetObjectPropKeys(
+ handle_t hBinding,
+ LPWSTR ObjectName,
+ DWORD ObjectType,
+ LPWSTR PropertyCultureName,
+ PNP_PROP_COUNT *PropertyCount,
+ PNP_PROP_COUNT *TransferLen,
+ DEVPROPKEY *PropertyKeys,
+ DWORD Flags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
+}
+
+
+/* Function 66 */
+DWORD PNP_GetObjectProp(
+ handle_t hBinding,
+ LPWSTR ObjectName,
+ DWORD ObjectType,
+ LPWSTR PropertyCultureName,
+ const DEVPROPKEY *PropertyKey,
+ DEVPROPTYPE *PropertyType,
+ PNP_PROP_SIZE *PropertySize,
+ PNP_PROP_SIZE *TransferLen,
+ BYTE *PropertyBuffer,
+ DWORD Flags)
+{
+ UNIMPLEMENTED;
+ return CR_CALL_NOT_IMPLEMENTED;
+}
+
+
+/* Function 67 */
+DWORD PNP_SetObjectProp(
+ handle_t hBinding,
+ LPWSTR ObjectName,
+ DWORD ObjectType,
+ LPWSTR PropertyCultureName,
+ const DEVPROPKEY *PropertyKey,
+ DEVPROPTYPE PropertyType,
+ PNP_PROP_SIZE PropertySize,
+ BYTE *PropertyBuffer,
+ DWORD Flags)
+{
+ UNIMPLEMENTED;
return CR_CALL_NOT_IMPLEMENTED;
}
Modified: trunk/reactos/dll/win32/setupapi/cfgmgr.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/setupapi/cfgmgr.…
==============================================================================
--- trunk/reactos/dll/win32/setupapi/cfgmgr.c [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/setupapi/cfgmgr.c [iso-8859-1] Mon Apr 14 05:48:38 2008
@@ -810,7 +810,7 @@
}
ret = PNP_EnumerateSubKeys(BindingHandle,
- PNP_BRANCH_CLASS,
+ PNP_CLASS_SUBKEYS,
ulClassIndex,
szBuffer,
MAX_GUID_STRING_LEN,
@@ -933,7 +933,7 @@
}
return PNP_EnumerateSubKeys(BindingHandle,
- PNP_BRANCH_ENUM,
+ PNP_ENUMERATOR_SUBKEYS,
ulEnumIndex,
Buffer,
*pulLength,
@@ -1042,7 +1042,7 @@
RPC_BINDING_HANDLE BindingHandle = NULL;
HSTRING_TABLE StringTable = NULL;
LPWSTR lpDevInst;
- DWORD dwIndex;
+ DWORD dwIndex, dwLength = MAX_DEVICE_ID_LEN;
CONFIGRET ret;
TRACE("%p %lx %lx %lx\n", pdnDevInst, dnDevInst, ulFlags, hMachine);
@@ -1079,10 +1079,10 @@
return CR_INVALID_DEVNODE;
ret = PNP_GetRelatedDeviceInstance(BindingHandle,
- PNP_DEVICE_CHILD,
+ PNP_GET_CHILD_DEVICE_INSTANCE,
lpDevInst,
szRelatedDevInst,
- MAX_DEVICE_ID_LEN,
+ &dwLength,
0);
if (ret != CR_SUCCESS)
return ret;
@@ -2181,8 +2181,8 @@
return CR_FAILURE;
}
- return PNP_HwProfFlags(BindingHandle, PNP_GET_HW_PROFILE_FLAGS, szDevInstName,
- ulHardwareProfile, pulValue, 0);
+ return PNP_HwProfFlags(BindingHandle, PNP_GET_HWPROFFLAGS, szDevInstName,
+ ulHardwareProfile, pulValue, NULL, NULL, 0, 0);
}
@@ -2356,7 +2356,7 @@
RPC_BINDING_HANDLE BindingHandle = NULL;
HSTRING_TABLE StringTable = NULL;
LPWSTR lpDevInst;
- DWORD dwIndex;
+ DWORD dwIndex, dwLength = MAX_DEVICE_ID_LEN;
CONFIGRET ret;
TRACE("%p %lx %lx %lx\n", pdnDevInst, dnDevInst, ulFlags, hMachine);
@@ -2393,10 +2393,10 @@
return CR_INVALID_DEVNODE;
ret = PNP_GetRelatedDeviceInstance(BindingHandle,
- PNP_DEVICE_PARENT,
+ PNP_GET_PARENT_DEVICE_INSTANCE,
lpDevInst,
szRelatedDevInst,
- MAX_DEVICE_ID_LEN,
+ &dwLength,
0);
if (ret != CR_SUCCESS)
return ret;
@@ -2434,7 +2434,7 @@
RPC_BINDING_HANDLE BindingHandle = NULL;
HSTRING_TABLE StringTable = NULL;
LPWSTR lpDevInst;
- DWORD dwIndex;
+ DWORD dwIndex, dwLength = MAX_DEVICE_ID_LEN;
CONFIGRET ret;
TRACE("%p %lx %lx %lx\n", pdnDevInst, dnDevInst, ulFlags, hMachine);
@@ -2471,10 +2471,10 @@
return CR_INVALID_DEVNODE;
ret = PNP_GetRelatedDeviceInstance(BindingHandle,
- PNP_DEVICE_SIBLING,
+ PNP_GET_SIBLING_DEVICE_INSTANCE,
lpDevInst,
szRelatedDevInst,
- MAX_DEVICE_ID_LEN,
+ &dwLength,
0);
if (ret != CR_SUCCESS)
return ret;
@@ -3407,7 +3407,7 @@
lpDevInst,
ulProperty,
ulType,
- (char *)Buffer,
+ (BYTE *)Buffer,
ulLength,
ulFlags);
}
@@ -3502,8 +3502,8 @@
return CR_FAILURE;
}
- return PNP_HwProfFlags(BindingHandle, PNP_SET_HW_PROFILE_FLAGS, szDevInstName,
- ulConfig, &ulValue, 0);
+ return PNP_HwProfFlags(BindingHandle, PNP_SET_HWPROFFLAGS, szDevInstName,
+ ulConfig, &ulValue, NULL, NULL, 0, 0);
}
Modified: trunk/reactos/include/reactos/idl/pnp.idl
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/reactos/idl/pnp.id…
==============================================================================
--- trunk/reactos/include/reactos/idl/pnp.idl [iso-8859-1] (original)
+++ trunk/reactos/include/reactos/idl/pnp.idl [iso-8859-1] Mon Apr 14 05:48:38 2008
@@ -4,7 +4,243 @@
#include "include/reactos/idl/wtypes.idl"
-#define CONFIGRET unsigned long
+const unsigned long PNP_MAX_STRING_LEN = 32767;
+const unsigned long PNP_MAX_DEVICE_ID_LEN = 200;
+const unsigned long PNP_MAX_GUID_STRING_LEN = 39;
+const unsigned long PNP_MAX_DEVINTERFACE_LEN = PNP_MAX_STRING_LEN;
+const unsigned long PNP_MAX_CULTURE_NAME_LEN = 85;
+const unsigned long PNP_MAX_CM_PATH = 360;
+const unsigned long PNP_MAX_PROP_SIZE = 65534;
+const unsigned long PNP_MAX_PROP_COUNT = 32767;
+const unsigned long PNP_MAX_BUFFER_SIZE = 16000000;
+
+typedef unsigned long RESOURCEID;
+typedef unsigned long DEVPROPTYPE;
+typedef [range(0, PNP_MAX_PROP_SIZE)] unsigned long PNP_PROP_SIZE, *PPNP_PROP_SIZE;
+typedef [range(0, PNP_MAX_PROP_COUNT)] unsigned long PNP_PROP_COUNT, *PPNP_PROP_COUNT;
+typedef [range(0, PNP_MAX_STRING_LEN)] unsigned long PNP_RPC_STRING_LEN,
*PPNP_RPC_STRING_LEN;
+typedef [range(0, PNP_MAX_BUFFER_SIZE)] unsigned long PNP_RPC_BUFFER_SIZE,
*PPNP_RPC_BUFFER_SIZE;
+
+cpp_quote("#ifndef _CFG_INCLUDED_")
+
+typedef enum _PNP_VETO_TYPE {
+ PNP_VetoTypeUnknown = 0,
+ PNP_VetoLegacyDevice = 1,
+ PNP_VetoPendingClose = 2,
+ PNP_VetoWindowsApp = 3,
+ PNP_VetoWindowsService = 4,
+ PNP_VetoOutstandingOpen = 5,
+ PNP_VetoDevice = 6,
+ PNP_VetoDriver = 7,
+ PNP_VetoIllegalDeviceRequest = 8,
+ PNP_VetoInsufficientPower = 9,
+ PNP_VetoNonDisableable = 10,
+ PNP_VetoLegacyDriver = 11,
+ PNP_VetoInsufficientRights = 12,
+} *PPNP_VETO_TYPE;
+
+cpp_quote("#endif")
+
+cpp_quote("#if 0")
+
+typedef struct _BUSNUMBER_DES {
+ DWORD BUSD_Count;
+ DWORD BUSD_Type;
+ DWORD BUSD_Flags;
+ DWORD BUSD_Alloc_Base;
+ DWORD BUSD_Alloc_End;
+} BUSNUMBER_DES, *PBUSNUMBER_DES;
+
+typedef struct _BUSNUMBER_RANGE {
+ DWORD BUSR_Min;
+ DWORD BUSR_Max;
+ DWORD BUSR_nBusNumbers;
+ DWORD BUSR_Flags;
+} BUSNUMBER_RANGE, *PBUSNUMBER_RANGE;
+
+typedef struct _BUSNUMBER_RESOURCE {
+ BUSNUMBER_DES BusNumber_Header;
+ BUSNUMBER_RANGE BusNumber_Data[1];
+} BUSNUMBER_RESOURCE, *PBUSNUMBER_RESOURCE;
+
+typedef struct _CS_DES {
+ DWORD CSD_SignatureLength;
+ DWORD CSD_LegacyDataOffset;
+ DWORD CSD_LegacyDataSize;
+ DWORD CSD_Flags;
+ GUID CSD_ClassGuid;
+ BYTE CSD_Signature[1];
+} CS_DES, *PCS_DES;
+
+typedef struct _CS_RESOURCE {
+ CS_DES CS_Header;
+} CS_RESOURCE, *PCS_RESOURCE;
+
+typedef struct _DEVPRIVATE_DES {
+ DWORD PD_Count;
+ DWORD PD_Type;
+ DWORD PD_Data1;
+ DWORD PD_Data2;
+ DWORD PD_Data3;
+ DWORD PD_Flags;
+} DEVPRIVATE_DES, *PDEVPRIVATE_DES;
+
+typedef struct _DEVPRIVATE_RANGE {
+ DWORD PR_Data1;
+ DWORD PR_Data2;
+ DWORD PR_Data3;
+} DEVPRIVATE_RANGE, *PDEVPRIVATE_RANGE;
+
+typedef struct _DEVPRIVATE_RESOURCE {
+ DEVPRIVATE_DES PRV_Header;
+ DEVPRIVATE_RANGE PRV_Data[1];
+} DEVPRIVATE_RESOURCE, *PDEVPRIVATE_RESOURCE;
+
+typedef struct _DMA_DES {
+ DWORD DD_Count;
+ DWORD DD_Type;
+ DWORD DD_Flags;
+ unsigned long DD_Alloc_Chan;
+} DMA_DES, *PDMA_DES;
+
+typedef struct _DMA_RANGE {
+ DWORD DR_Min;
+ DWORD DR_Max;
+ DWORD DR_Flags;
+} DMA_RANGE, *PDMA_RANGE;
+
+typedef struct _DMA_RESOURCE {
+ DMA_DES DMA_Header;
+ DMA_RANGE DMA_Data[1];
+} DMA_RESOURCE, *PDMA_RESOURCE;
+
+typedef struct _IO_DES {
+ DWORD IOD_Count;
+ DWORD IOD_Type;
+ unsigned __int64 IOD_AllocBase;
+ unsigned __int64 IOD_AllocEnd;
+ DWORD IOD_DesFlags;
+} IO_DES, *PIO_DES;
+
+typedef struct _IO_RANGE {
+ unsigned __int64 IOR_Align;
+ DWORD IOR_nPorts;
+ unsigned __int64 IOR_Min;
+ unsigned __int64 IOR_Max;
+ DWORD IOR_RangeFlags;
+ unsigned __int64 IOR_Alias;
+} IO_RANGE, *PIO_RANGE;
+
+typedef struct _IO_RESOURCE {
+ IO_DES IO_Header;
+ IO_RANGE IO_Data[1];
+} IO_RESOURCE, *PIO_RESOURCE;
+
+typedef struct _IRQ_DES {
+ DWORD IRQD_Count;
+ DWORD IRQD_Type;
+ DWORD IRQD_Flags;
+ DWORD IRQD_Alloc_Num;
+ DWORD IRQD_Affinity;
+} IRQ_DES, *PIRQ_DES;
+
+typedef struct _IRQ_RANGE {
+ DWORD IRQR_Min;
+ DWORD IRQR_Max;
+ DWORD IRQR_Flags;
+} IRQ_RANGE, *PIRQ_RANGE;
+
+typedef struct _IRQ_RESOURCE {
+ IRQ_DES IO_Header;
+ IRQ_RANGE IO_Data[1];
+} IRQ_RESOURCE, *PIRQ_RESOURCE;
+
+typedef struct _MEM_DES {
+ DWORD MD_Count;
+ DWORD MD_Type;
+ unsigned __int64 MD_Alloc_Base;
+ unsigned __int64 MD_Alloc_End;
+ DWORD MD_Flags;
+ DWORD Reserved;
+} MEM_DES, *PMEM_DES;
+
+typedef struct _MEM_RANGE {
+ __int64 MR_Align;
+ DWORD MR_nBytes;
+ __int64 MR_Min;
+ __int64 MR_Max;
+ DWORD MR_Flags;
+ DWORD MR_Reserved;
+} MEM_RANGE, *PMEM_RANGE;
+
+typedef struct _MEM_RESOURCE {
+ MEM_DES MEM_Header;
+ MEM_RANGE MEM_Data[1];
+} MEM_RESOURCE, *PMEM_RESOURCE;
+
+typedef struct _MFCARD_DES {
+ DWORD PMF_Count;
+ DWORD PMF_Type;
+ DWORD PMF_Flags;
+ BYTE PMF_ConfigOptions;
+ BYTE PMF_IoResourceIndex;
+ BYTE PMF_Reserved[2];
+ DWORD PMF_ConfigRegisterBase;
+} MFCARD_DES, *PMFCARD_DES;
+
+typedef struct _MFCARD_RESOURCE {
+ MFCARD_DES MfCard_Header;
+} MFCARD_RESOURCE, *PMFCARD_RESOURCE;
+
+typedef struct _PCCARD_DES {
+ DWORD PCD_Count;
+ DWORD PCD_Type;
+ DWORD PCD_Flags;
+ BYTE PCD_ConfigIndex;
+ BYTE PCD_Reserved[3];
+ DWORD PCD_MemoryCardBase1;
+ DWORD PCD_MemoryCardBase2;
+} PCCARD_DES, *PPCCARD_DES;
+
+typedef struct _PCCARD_RESOURCE {
+ PCCARD_DES PcCard_Header;
+} PCCARD_RESOURCE, *PPCARD_RESOURCE;
+
+cpp_quote("#endif")
+
+typedef struct _PNP_CONFLICT_ENTRY {
+ DWORD DeviceInstance;
+ DWORD DeviceFlags;
+ DWORD ResourceType;
+ __int64 ResourceStart;
+ __int64 ResourceEnd;
+ DWORD ResourceFlags;
+} PNP_CONFLICT_ENTRY, *PPNP_CONFLICT_ENTRY;
+
+typedef struct _PNP_CONFLICT_LIST {
+ DWORD Reserved1;
+ DWORD Reserved2;
+ DWORD ConflictsCounted;
+ DWORD ConflictsListed;
+ DWORD RequiredBufferSize;
+ PNP_CONFLICT_ENTRY ConflictEntry[1];
+} PNP_CONFLICT_LIST, *PPNP_CONFLICT_LIST;
+
+typedef struct _PNP_CONFLICT_STRINGS {
+ DWORD NullDeviceInstance;
+ WCHAR DeviceInstanceStrings[1];
+} PNP_CONFLICT_STRINGS, *PPNP_CONFLICT_STRINGS;
+
+typedef struct _DEVPROPKEY {
+ GUID fmtid;
+ DWORD pid;
+} DEVPROPKEY;
+
+typedef struct _HWPROFILEINFO {
+ DWORD HWPI_ulHWProfile;
+ WCHAR HWPI_szFriendlyName[80];
+ DWORD HWPI_dwFlags;
+} HWPROFILEINFO;
[
uuid (809F4e40-A03D-11CE-8F69-08003E30051B),
@@ -17,222 +253,556 @@
interface pnp
{
/* Function 0 */
-// CONFIGRET PNP_Unknown0(handle_t BindingHandle);
+ DWORD PNP_Function0(
+ [in] handle_t hBinding); /* FIXME */
/* Function 1 */
-// CONFIGRET PNP_Unknown1(handle_t BindingHandle);
+ DWORD PNP_Function1(
+ [in] handle_t hBinding); /* FIXME */
/* Function 2 */
- CONFIGRET PNP_GetVersion(handle_t BindingHandle,
- [out] WORD *Version);
+ DWORD PNP_GetVersion(
+ [in] handle_t hBinding,
+ [out] WORD *pVersion);
/* Function 3 */
- CONFIGRET PNP_GetGlobalState(handle_t BindingHandle,
- [out] unsigned long *State,
- [in] unsigned long Flags);
+ DWORD PNP_GetGlobalState(
+ [in] handle_t hBinding,
+ [out] DWORD *pulState,
+ [in] DWORD ulFlags);
/* Function 4 */
- CONFIGRET PNP_InitDetection(handle_t BindingHandle);
+ DWORD PNP_InitDetection(
+ [in] handle_t hBinding);
/* Function 5 */
- CONFIGRET PNP_ReportLogOn(handle_t BindingHandle,
- [in] BOOL Admin,
- [in] DWORD ProcessId);
+ DWORD PNP_ReportLogOn(
+ [in] handle_t hBinding,
+ [in] BOOL Admin,
+ [in] DWORD ProcessId);
/* Function 6 */
- CONFIGRET PNP_ValidateDeviceInstance(handle_t BindingHandle,
- [in, string] wchar_t *DeviceInstance,
- [in] DWORD Flags);
+ DWORD PNP_ValidateDeviceInstance(
+ [in] handle_t hBinding,
+ [in, string, ref, range(0, PNP_MAX_DEVICE_ID_LEN)] LPWSTR pDeviceID,
+ [in] DWORD ulFlags);
/* Function 7 */
- CONFIGRET PNP_GetRootDeviceInstance(handle_t BindingHandle,
- [out, string, size_is(Length)] wchar_t
*DeviceInstance,
- [in] DWORD Length);
+ DWORD PNP_GetRootDeviceInstance(
+ [in] handle_t hBinding,
+ [out, string, size_is(ulLength)] LPWSTR pDeviceID,
+ [in] PNP_RPC_STRING_LEN ulLength);
/* Function 8 */
- cpp_quote("#define PNP_DEVICE_PARENT 1")
- cpp_quote("#define PNP_DEVICE_CHILD 2")
- cpp_quote("#define PNP_DEVICE_SIBLING 3")
- CONFIGRET PNP_GetRelatedDeviceInstance(handle_t BindingHandle,
- [in] DWORD Relationship,
- [in, string] wchar_t *DeviceId,
- [out, string, size_is(Length)] wchar_t
*RelatedDeviceId,
- [in] DWORD Length,
- [in] DWORD Flags);
+ cpp_quote("#define PNP_GET_PARENT_DEVICE_INSTANCE 0x1");
+ cpp_quote("#define PNP_GET_CHILD_DEVICE_INSTANCE 0x2");
+ cpp_quote("#define PNP_GET_SIBLING_DEVICE_INSTANCE 0x3");
+ DWORD PNP_GetRelatedDeviceInstance(
+ [in] handle_t hBinding,
+ [in] DWORD ulRelationship,
+ [in, string, ref, range(0, PNP_MAX_DEVICE_ID_LEN)] LPWSTR pDeviceID,
+ [out, string, size_is(*pulLength)] LPWSTR pRelatedDeviceId,
+ [in, out] PNP_RPC_STRING_LEN *pulLength,
+ [in] DWORD ulFlags);
/* Function 9 */
- cpp_quote("#define PNP_BRANCH_ENUM 1")
- cpp_quote("#define PNP_BRANCH_CLASS 2")
- CONFIGRET PNP_EnumerateSubKeys(handle_t BindingHandle,
- [in] DWORD Branch,
- [in] DWORD Index,
- [out, string, size_is(Length)] wchar_t *Buffer,
- [in] DWORD Length,
- [out] DWORD *RequiredLength,
- [in] DWORD Flags);
+ cpp_quote("#define PNP_ENUMERATOR_SUBKEYS 0x1");
+ cpp_quote("#define PNP_CLASS_SUBKEYS 0x2");
+ DWORD PNP_EnumerateSubKeys(
+ [in] handle_t hBinding,
+ [in] DWORD ulBranch,
+ [in] DWORD ulIndex,
+ [out, string, size_is(ulLength)] LPWSTR Buffer,
+ [in] PNP_RPC_STRING_LEN ulLength,
+ [out] PNP_RPC_STRING_LEN *pulRequiredLen,
+ [in] DWORD ulFlags);
/* Function 10 */
-// CONFIGRET PNP_GetDeviceList(handle_t BindingHandle,
-// [in, unique, string] wchar_t *Filter,
-// [out, string, size_is(*Length)] unsigned char *Buffer
-// [in, out] unsigned long *Length,
-// [in] DWORD Flags);
+ DWORD PNP_GetDeviceList(
+ [in] handle_t hBinding,
+ [in, string, unique, range(0, PNP_MAX_STRING_LEN)] LPWSTR pszFilter,
+ [out, size_is(*pulLength), length_is(*pulLength)] LPWSTR Buffer,
+ [in, out] PNP_RPC_STRING_LEN *pulLength,
+ [in] DWORD ulFlags);
/* Function 11 */
- CONFIGRET PNP_GetDeviceListSize(handle_t BindingHandle,
- [in, unique, string] wchar_t *Filter,
- [out] unsigned long *Length,
- [in] DWORD Flags);
+ DWORD PNP_GetDeviceListSize(
+ [in] handle_t hBinding,
+ [in, string, unique, range(0, PNP_MAX_STRING_LEN)] LPWSTR pszFilter,
+ [out] PNP_RPC_BUFFER_SIZE *pulLen,
+ [in] DWORD ulFlags);
/* Function 12 */
- CONFIGRET PNP_GetDepth(handle_t BindingHandle,
- [in, string] wchar_t *DeviceInstance,
- [out] unsigned long *Depth,
- [in] DWORD Flags);
+ DWORD PNP_GetDepth(
+ [in] handle_t hBinding,
+ [in, string, ref, range(0, PNP_MAX_DEVICE_ID_LEN)] LPWSTR pszDeviceID,
+ [out] DWORD *pulDepth,
+ [in] DWORD ulFlags);
/* Function 13 */
- CONFIGRET PNP_GetDeviceRegProp(handle_t BindingHandle,
- [in, string] wchar_t *DeviceInstance,
- [in] DWORD Property,
- [in, out] DWORD *DataType,
- [out, size_is(*TransferLen)] char *Buffer,
- [in, out] DWORD *TransferLen,
- [in, out] DWORD *Length,
- [in] DWORD Flags);
+ DWORD PNP_GetDeviceRegProp(
+ [in] handle_t hBinding,
+ [in, string, ref, range(0, PNP_MAX_DEVICE_ID_LEN)] LPWSTR pDeviceID,
+ [in] DWORD ulProperty,
+ [in, out] DWORD *pulRegDataType,
+ [out, size_is(*pulTransferLen), length_is(*pulTransferLen)] BYTE *Buffer,
+ [in, out] PNP_PROP_SIZE *pulTransferLen,
+ [in, out] PNP_PROP_SIZE *pulLength,
+ [in] DWORD ulFlags);
/* Function 14 */
- CONFIGRET PNP_SetDeviceRegProp(handle_t BindingHandle,
- [in, string] wchar_t *DeviceId,
- [in] unsigned long Property,
- [in] unsigned long DataType,
- [in, size_is(Length)] char *Buffer,
- [in] unsigned long Length,
- [in] unsigned long Flags);
+ DWORD PNP_SetDeviceRegProp(
+ [in] handle_t hBinding,
+ [in, string, ref, range(0, PNP_MAX_DEVICE_ID_LEN)] LPWSTR pDeviceId,
+ [in] DWORD ulProperty,
+ [in] DWORD ulDataType,
+ [in, size_is(ulLength)] BYTE *Buffer,
+ [in] PNP_PROP_SIZE ulLength,
+ [in] DWORD ulFlags);
/* Function 15 */
- CONFIGRET PNP_GetClassInstance(handle_t BindingHandle,
- [in, string] wchar_t *DeviceId,
- [out, string, size_is(Length)] wchar_t *Buffer,
- [in] unsigned long Length);
+ DWORD PNP_GetClassInstance(
+ [in] handle_t hBinding,
+ [in, string, ref, range(0, PNP_MAX_DEVICE_ID_LEN)] LPWSTR pDeviceId,
+ [out, string, size_is(ulLength)] LPWSTR pszClassInstance,
+ [in] PNP_RPC_STRING_LEN ulLength);
/* Function 16 */
- CONFIGRET PNP_CreateKey(handle_t BindingHandle,
- [in, string] wchar_t *SubKey,
- [in] unsigned long DesiredAccess,
- [in] unsigned long Flags);
+ DWORD PNP_CreateKey(
+ [in] handle_t hBinding,
+ [in, string, ref, range(0, PNP_MAX_CM_PATH)] LPWSTR pszSubKey,
+ [in] DWORD samDesired,
+ [in] DWORD ulFlags);
/* Function 17 */
- CONFIGRET PNP_DeleteRegistryKey(handle_t BindingHandle,
- [in, string] wchar_t *DeviceId,
- [in, string] wchar_t *ParentKey,
- [in, string] wchar_t *ChildKey,
- [in] unsigned long Flags);
+ DWORD PNP_DeleteRegistryKey(
+ [in] handle_t hBinding,
+ [in, string, ref, range(0, PNP_MAX_DEVICE_ID_LEN)] LPWSTR pszDeviceID,
+ [in, string, ref, range(0, PNP_MAX_CM_PATH)] LPWSTR pszParentKey,
+ [in, string, ref, range(0, PNP_MAX_CM_PATH)] LPWSTR pszChildKey,
+ [in] DWORD ulFlags);
+
+ /* Function 18 */
+ DWORD PNP_GetClassCount(
+ [in] handle_t hBinding,
+ [out] DWORD *pulClassCount,
+ [in] DWORD ulFlags);
/* Function 19 */
- CONFIGRET PNP_GetClassName(handle_t BindingHandle,
- [in, string] wchar_t *ClassGuid,
- [out, string, size_is(*Length)] wchar_t *Buffer,
- [in, out] unsigned long *Length,
- [in] unsigned long Flags);
+ DWORD PNP_GetClassName(
+ [in] handle_t hBinding,
+ [in, string, ref, range(0, PNP_MAX_GUID_STRING_LEN)] LPWSTR pszClassGuid,
+ [out, string, size_is(*pulLength)] LPWSTR Buffer,
+ [in, out] PNP_RPC_STRING_LEN *pulLength,
+ [in] DWORD ulFlags);
/* Function 20 */
- CONFIGRET PNP_DeleteClassKey(handle_t BindingHandle,
- [in, string] wchar_t *ClassGuid,
- [in] unsigned long Flags);
+ DWORD PNP_DeleteClassKey(
+ [in] handle_t hBinding,
+ [in, string, ref, range(0, PNP_MAX_GUID_STRING_LEN)] LPWSTR pszClassGuid,
+ [in] DWORD ulFlags);
+
+ /* Function 21 */
+ DWORD PNP_GetInterfaceDeviceAlias(
+ [in] handle_t hBinding,
+ [in, string, ref, range(0, PNP_MAX_DEVINTERFACE_LEN)] LPWSTR pszInterfaceDevice,
+ [in] GUID *AliasInterfaceGuid,
+ [out, string, size_is(*pulTransferLen)] LPWSTR pszAliasInterfaceDevice,
+ [in, out] PNP_RPC_STRING_LEN *pulLength,
+ [in, out] PNP_RPC_STRING_LEN *pulTransferLen,
+ [in] DWORD ulFlags);
+
+ /* Function 22 */
+ DWORD PNP_GetInterfaceDeviceList(
+ [in] handle_t hBinding,
+ [in] GUID *InterfaceGuid,
+ [in, string, unique, range(0, PNP_MAX_DEVICE_ID_LEN)] LPWSTR pszDeviceID,
+ [out, size_is(*pulLength), length_is(*pulLength)] BYTE *Buffer,
+ [in, out] PNP_RPC_BUFFER_SIZE *pulLength,
+ [in] DWORD ulFlags);
+
+ /* Function 23 */
+ DWORD PNP_GetInterfaceDeviceListSize(
+ [in] handle_t hBinding,
+ [out] PNP_RPC_BUFFER_SIZE *pulLen,
+ [in] GUID *InterfaceGuid,
+ [in, string, unique, range(0, PNP_MAX_DEVICE_ID_LEN)] LPWSTR pszDeviceID,
+ [in] DWORD ulFlags);
+
+ /* Function 24 */
+ DWORD PNP_RegisterDeviceClassAssociation(
+ [in] handle_t hBinding,
+ [in, string, unique, range(0, PNP_MAX_DEVICE_ID_LEN)] LPWSTR pszDeviceID,
+ [in] GUID *InterfaceGuid,
+ [in, string, unique, range(0, PNP_MAX_STRING_LEN)] LPWSTR pszReference,
+ [out, string, size_is(*pulTransferLen)] LPWSTR pszSymLink,
+ [in, out] PNP_RPC_STRING_LEN *pulLength,
+ [in, out] PNP_RPC_STRING_LEN *pulTransferLen,
+ [in] DWORD ulFlags);
+
+ /* Function 25 */
+ DWORD PNP_UnregisterDeviceClassAssociation(
+ [in] handle_t hBinding,
+ [in, string, unique, range(0, PNP_MAX_DEVINTERFACE_LEN)] LPWSTR
pszInterfaceDevice,
+ [in] DWORD ulFlags);
+
+ /* Function 26 */
+ DWORD PNP_GetClassRegProp(
+ [in] handle_t hBinding,
+ [in, string, ref, range(0, PNP_MAX_GUID_STRING_LEN)] LPWSTR pszClassGuid,
+ [in] DWORD ulProperty,
+ [in, out] DWORD *pulRegDataType,
+ [out, size_is(*pulTransferLen), length_is(*pulTransferLen)] BYTE *Buffer,
+ [in, out] PNP_RPC_STRING_LEN *pulTransferLen,
+ [in, out] PNP_RPC_STRING_LEN *pulLength,
+ [in] DWORD ulFlags);
+
+ /* Function 27 */
+ DWORD PNP_SetClassRegProp(
+ [in] handle_t hBinding,
+ [in, string, ref, range(0, PNP_MAX_GUID_STRING_LEN)] LPWSTR *pszClassGuid,
+ [in] DWORD ulProperty,
+ [in] DWORD ulDataType,
+ [in, size_is(ulLength)] BYTE *Buffer,
+ [in] PNP_PROP_SIZE ulLength,
+ [in] DWORD ulFlags);
/* Function 28 */
- CONFIGRET PNP_CreateDevInst(handle_t BindingHandle,
- [in, out, string, size_is(Length)] wchar_t *DeviceId,
- [in, string] wchar_t *ParentDeviceId,
- [in] unsigned long Length,
- [in] unsigned long Flags);
+ DWORD PNP_CreateDevInst(
+ [in] handle_t hBinding,
+ [in, out, string, size_is(ulLength)] LPWSTR pszDeviceID,
+ [in, string, ref, range(0, PNP_MAX_DEVICE_ID_LEN)] LPWSTR pszParentDeviceID,
+ [in] PNP_RPC_STRING_LEN ulLength,
+ [in] DWORD ulFlags);
/* Function 29 */
- CONFIGRET PNP_DeviceInstanceAction(handle_t BindingHandle,
- [in] unsigned long MajorAction,
- [in] unsigned long MinorAction,
- [in, unique, string] wchar_t *DeviceInstance1,
- [in, unique, string] wchar_t *DeviceInstance2);
+ DWORD PNP_DeviceInstanceAction(
+ [in] handle_t hBinding,
+ [in] DWORD ulMajorAction,
+ [in] DWORD ulMinorAction,
+ [in, string, unique, range(0, PNP_MAX_DEVICE_ID_LEN)] LPWSTR pszDeviceInstance1,
+ [in, string, unique, range(0, PNP_MAX_DEVICE_ID_LEN)] LPWSTR
pszDeviceInstance2);
/* Function 30 */
- CONFIGRET PNP_GetDeviceStatus(handle_t BindingHandle,
- [in, string] wchar_t *DeviceInstance,
- [out] unsigned long *Status,
- [out] unsigned long *Problem,
- [in] DWORD Flags);
+ DWORD PNP_GetDeviceStatus(
+ [in] handle_t hBinding,
+ [in, string, unique, range(0, PNP_MAX_DEVICE_ID_LEN)] LPWSTR pDeviceID,
+ [out] DWORD *pulStatus,
+ [out] DWORD *pulProblem,
+ [in] DWORD ulFlags);
/* Function 31 */
- CONFIGRET PNP_SetDeviceProblem(handle_t BindingHandle,
- [in, string] wchar_t *DeviceInstance,
- [in] unsigned long Problem,
- [in] DWORD Flags);
+ DWORD PNP_SetDeviceProblem(
+ [in] handle_t hBinding,
+ [in, string, unique, range(0, PNP_MAX_DEVICE_ID_LEN)] LPWSTR pDeviceID,
+ [in] DWORD ulProblem,
+ [in] DWORD ulFlags);
+
+ /* Function 32 */
+ DWORD PNP_DisableDevInst(
+ [in] handle_t hBinding,
+ [in, string, unique, range(0, PNP_MAX_DEVICE_ID_LEN)] LPWSTR pDeviceID,
+ [in, out, unique] PPNP_VETO_TYPE pVetoType,
+ [in, out, string, unique, size_is(ulNameLength), range(0, PNP_MAX_STRING_LEN)]
LPWSTR pszVetoName,
+ /* FIXME: should be [in, out, string, unique, max_is(ulNameLength), range(0,
PNP_MAX_STRING_LEN)] LPWSTR pszVetoName, */
+ [in] DWORD ulNameLength,
+ [in] DWORD ulFlags);
/* Function 33 */
- CONFIGRET PNP_UninstallDevInst(handle_t BindingHandle,
- [in, string] wchar_t *DeviceInstance,
- [in] DWORD Flags);
+ DWORD PNP_UninstallDevInst(
+ [in] handle_t hBinding,
+ [in, string, unique, range(0, PNP_MAX_DEVICE_ID_LEN)] LPWSTR pDeviceID,
+ [in] DWORD ulFlags);
/* Function 34 */
- CONFIGRET PNP_AddID(handle_t BindingHandle,
- [in, string, unique] wchar_t *DeviceInstance,
- [in, string] wchar_t *DeviceId,
- [in] DWORD Flags);
+ DWORD PNP_AddID(
+ [in] handle_t hBinding,
+ [in, string, unique, range(0, PNP_MAX_DEVICE_ID_LEN)] LPWSTR pszDeviceID,
+ [in, string, ref, range(0, PNP_MAX_DEVICE_ID_LEN)] LPWSTR pszID,
+ [in] DWORD ulFlags);
+
+ /* Function 35 */
+ DWORD PNP_RegisterDriver(
+ [in] handle_t hBinding,
+ [in, string, ref, range(0, PNP_MAX_DEVICE_ID_LEN)] LPWSTR pszDeviceID,
+ [in] DWORD ulFlags);
+
+ /* Function 36 */
+ DWORD PNP_QueryRemove(
+ [in] handle_t hBinding,
+ [in, string, ref, range(0, PNP_MAX_DEVICE_ID_LEN)] LPWSTR pszDeviceID,
+ [in, out, unique] PPNP_VETO_TYPE pVetoType,
+ [in, out, string, unique, size_is(ulNameLength), range(0, PNP_MAX_STRING_LEN)]
LPWSTR pszVetoName,
+ /* FIXME: should be [in, out, string, unique, max_is(ulNameLength), range(0,
PNP_MAX_STRING_LEN)] LPWSTR pszVetoName, */
+ [in] DWORD ulNameLength,
+ [in] DWORD ulFlags);
+
+ /* Function 37 */
+ DWORD PNP_RequestDeviceEject(
+ [in] handle_t hBinding,
+ [in, string, ref, range(0, PNP_MAX_DEVICE_ID_LEN)] LPWSTR pszDeviceID,
+ [in, out, unique] PPNP_VETO_TYPE pVetoType,
+ [in, out, string, unique, size_is(ulNameLength), range(0, PNP_MAX_STRING_LEN)]
LPWSTR pszVetoName,
+ /* FIXME: should be [in, out, string, unique, max_is(ulNameLength), range(0,
PNP_MAX_STRING_LEN)] LPWSTR pszVetoName, */
+ [in] DWORD ulNameLength,
+ [in] DWORD ulFlags);
/* Function 38 */
- CONFIGRET PNP_IsDockStationPresent(handle_t BindingHandle,
- [out]PBOOL Present);
+ DWORD PNP_IsDockStationPresent(
+ [in] handle_t hBinding,
+ [in, out, unique] BOOL *Present);
/* Function 39 */
- CONFIGRET PNP_RequestEjectPC(handle_t BindingHandle);
+ DWORD PNP_RequestEjectPC(
+ [in] handle_t hBinding);
/* Function 40 */
- cpp_quote("#define PNP_SET_HW_PROFILE_FLAGS 0")
- cpp_quote("#define PNP_GET_HW_PROFILE_FLAGS 1")
- CONFIGRET PNP_HwProfFlags(handle_t BindingHandle,
- [in] DWORD Action,
- [in, string] wchar_t *DeviceId,
- [in] DWORD ProfileId,
- [in, out] DWORD *Value,
- [in] DWORD Flags);
+ cpp_quote("#define PNP_GET_HWPROFFLAGS 0x1");
+ cpp_quote("#define PNP_SET_HWPROFFLAGS 0x2");
+ DWORD PNP_HwProfFlags(
+ [in] handle_t hBinding,
+ [in] DWORD ulAction,
+ [in, string, ref, range(0, PNP_MAX_DEVICE_ID_LEN)] LPWSTR pDeviceID,
+ [in] DWORD ulConfig,
+ [in, out] DWORD *pulValue,
+ [in, out, unique] PPNP_VETO_TYPE pVetoType,
+ [in, out, string, unique, size_is(ulNameLength), range(0, PNP_MAX_STRING_LEN)]
LPWSTR pszVetoName,
+ /* FIXME: should be [in, out, string, unique, max_is(ulNameLength), range(0,
PNP_MAX_STRING_LEN)] LPWSTR pszVetoName, */
+ [in] DWORD ulNameLength,
+ [in] DWORD ulFlags);
+
+ /* Function 41 */
+ DWORD PNP_GetHwProfInfo(
+ [in] handle_t hBinding,
+ [in] DWORD ulIndex,
+ [in, out, ref] HWPROFILEINFO *pHWProfileInfo,
+ [in, range(0, 168)] DWORD ulProfileInfoSize,
+ /* FIXME: should be [in, range(0, sizeof(HWPROFILEINFO))] DWORD
ulProfileInfoSize, */
+ [in] DWORD ulFlags);
/* Function 42 */
- CONFIGRET PNP_AddEmptyLogConf(handle_t BindingHandle,
- [in, string] wchar_t *DeviceInstance,
- [in] ULONG ulPriority,
- [out] ULONG *pulLogConfTag,
- [in] ULONG ulFlags);
+ DWORD PNP_AddEmptyLogConf(
+ [in] handle_t hBinding,
+ [in, string, ref, range(0, PNP_MAX_DEVICE_ID_LEN)] LPWSTR pDeviceID,
+ [in] DWORD ulPriority,
+ [out] DWORD *pulLogConfTag,
+ [in] DWORD ulFlags);
/* Function 43 */
- CONFIGRET PNP_FreeLogConf(handle_t BindingHandle,
- [in, string] wchar_t *DeviceInstance,
- [in] ULONG ulType,
- [in] ULONG ulLogConfTag,
- [in] ULONG ulFlags);
+ DWORD PNP_FreeLogConf(
+ [in] handle_t hBinding,
+ [in, string, ref, range(0, PNP_MAX_DEVICE_ID_LEN)] LPWSTR pDeviceID,
+ [in] DWORD ulLogConfType,
+ [in] DWORD ulLogConfTag,
+ [in] DWORD ulFlags);
/* Function 44 */
- CONFIGRET PNP_GetFirstLogConf(handle_t BindingHandle,
- [in, string] wchar_t *DeviceInstance,
- [in] ULONG ulPriority,
- [out] ULONG *pulLogConfTag,
- [in] ULONG ulFlags);
+ DWORD PNP_GetFirstLogConf(
+ [in] handle_t hBinding,
+ [in, string, ref, range(0, PNP_MAX_DEVICE_ID_LEN)] LPWSTR pDeviceID,
+ [in] DWORD ulLogConfType,
+ [out] DWORD *pulLogConfTag,
+ [in] DWORD ulFlags);
/* Function 45 */
- CONFIGRET PNP_GetNextLogConf(handle_t BindingHandle,
- [in, string] wchar_t *DeviceInstance,
- [in] ULONG ulLogConfType,
- [in] ULONG ulCurrentTag,
- [out] ULONG *pulNextTag,
- [in] ULONG ulFlags);
+ DWORD PNP_GetNextLogConf(
+ [in] handle_t hBinding,
+ [in, string, ref, range(0, PNP_MAX_DEVICE_ID_LEN)] LPWSTR pDeviceID,
+ [in] DWORD ulLogConfType,
+ [in] DWORD ulCurrentTag,
+ [out] DWORD *pulNextTag,
+ [in] DWORD ulFlags);
/* Function 46 */
- CONFIGRET PNP_GetLogConfPriority(handle_t BindingHandle,
- [in, string] wchar_t *DeviceInstance,
- [in] ULONG ulLogConfType,
- [in] ULONG ulCurrentTag,
- [out] ULONG *pPriority,
- [in] ULONG ulFlags);
+ DWORD PNP_GetLogConfPriority(
+ [in] handle_t hBinding,
+ [in, string, ref, range(0, PNP_MAX_DEVICE_ID_LEN)] LPWSTR pDeviceID,
+ [in] DWORD ulType,
+ [in] DWORD ulTag,
+ [out] DWORD *pPriority,
+ [in] DWORD ulFlags);
+
+ /* Function 47 */
+ DWORD PNP_AddResDes(
+ [in] handle_t hBinding,
+ [in, string, ref, range(0, PNP_MAX_DEVICE_ID_LEN)] LPWSTR pDeviceID,
+ [in] DWORD ulLogConfTag,
+ [in] DWORD ulLogConfType,
+ [in] RESOURCEID ResourceID,
+ [out] DWORD *pulResourceTag,
+ [in, size_is(ResourceLen)] BYTE *ResourceData,
+ [in] PNP_RPC_BUFFER_SIZE ResourceLen,
+ [in] DWORD ulFlags);
+
+ /* Function 48 */
+ DWORD PNP_FreeResDes(
+ [in] handle_t hBinding,
+ [in, string, ref, range(0, PNP_MAX_DEVICE_ID_LEN)] LPWSTR pDeviceID,
+ [in] DWORD ulLogConfTag,
+ [in] DWORD ulLogConfType,
+ [in] RESOURCEID ResourceID,
+ [in] DWORD ulResourceTag,
+ [out] DWORD *pulPreviousResType,
+ [out] DWORD *pulPreviousResTag,
+ [in] DWORD ulFlags);
+
+ /* Function 49 */
+ DWORD PNP_GetNextResDes(
+ [in] handle_t hBinding,
+ [in, string, ref, range(0, PNP_MAX_DEVICE_ID_LEN)] LPWSTR pDeviceID,
+ [in] DWORD ulLogConfTag,
+ [in] DWORD ulLogConfType,
+ [in] RESOURCEID ResourceID,
+ [in] DWORD ulResourceTag,
+ [out] DWORD *pulNextResType,
+ [out] DWORD *pulNextResTag,
+ [in] DWORD ulFlags);
+
+ /* Function 50 */
+ DWORD PNP_GetResDesData(
+ [in] handle_t hBinding,
+ [in, string, ref, range(0, PNP_MAX_DEVICE_ID_LEN)] LPWSTR pDeviceID,
+ [in] DWORD ulLogConfTag,
+ [in] DWORD ulLogConfType,
+ [in] RESOURCEID ResourceID,
+ [in] DWORD ulResourceTag,
+ [out, size_is(BufferLen)] BYTE *Buffer,
+ [in] PNP_RPC_BUFFER_SIZE BufferLen,
+ [in] DWORD ulFlags);
+
+ /* Function 51 */
+ DWORD PNP_GetResDesDataSize(
+ [in] handle_t hBinding,
+ [in, string, ref, range(0, PNP_MAX_DEVICE_ID_LEN)] LPWSTR pDeviceID,
+ [in] DWORD ulLogConfTag,
+ [in] DWORD ulLogConfType,
+ [in] RESOURCEID ResourceID,
+ [in] DWORD ulResourceTag,
+ [out] DWORD *pulSize,
+ [in] DWORD ulFlags);
+
+ /* Function 52 */
+ DWORD PNP_ModifyResDes(
+ [in] handle_t hBinding,
+ [in, string, ref, range(0, PNP_MAX_DEVICE_ID_LEN)] LPWSTR pDeviceID,
+ [in] DWORD ulLogConfTag,
+ [in] DWORD ulLogConfType,
+ [in] RESOURCEID CurrentResourceID,
+ [in] RESOURCEID NewResourceID,
+ [in] DWORD ulResourceTag,
+ [in, size_is(ResourceLen)] BYTE *ResourceData,
+ [in] PNP_RPC_BUFFER_SIZE ResourceLen,
+ [in] DWORD ulFlags);
+
+ /* Function 53 */
+ DWORD PNP_DetectResourceConflict(
+ [in] handle_t hBinding,
+ [in, string, ref, range(0, PNP_MAX_DEVICE_ID_LEN)] LPWSTR pDeviceID,
+ [in] RESOURCEID ResourceID,
+ [in, size_is(ResourceLen)] BYTE *ResourceData,
+ [in] PNP_RPC_BUFFER_SIZE ResourceLen,
+ [out] BOOL *pbConflictDetected,
+ [in] DWORD ulFlags);
+
+ /* Function 54 */
+ DWORD PNP_QueryResConfList(
+ [in] handle_t hBinding,
+ [in, string, ref, range(0, PNP_MAX_DEVICE_ID_LEN)] LPWSTR pDeviceID,
+ [in] RESOURCEID ResourceID,
+ [in, size_is(ResourceLen)] BYTE *ResourceData,
+ [in] PNP_RPC_BUFFER_SIZE ResourceLen,
+ [out, size_is(BufferLen)] BYTE *Buffer,
+ [in] PNP_RPC_BUFFER_SIZE BufferLen,
+ [in] DWORD ulFlags);
+
+ /* Function 55 */
+ DWORD PNP_Function55(
+ [in] handle_t hBinding);
+
+ /* Function 56 */
+ DWORD PNP_Function56(
+ [in] handle_t hBinding);
+
+ /* Function 57 */
+ DWORD PNP_Function57(
+ [in] handle_t hBinding);
/* Function 58 */
- CONFIGRET PNP_RunDetection(handle_t BindingHandle,
- [in] unsigned long Flags);
+ DWORD PNP_RunDetection(
+ [in] handle_t hBinding,
+ [in] DWORD ulFlags);
+
+ /* Function 59 */
+ DWORD PNP_Function59(
+ [in] handle_t hBinding);
+
+ /* Function 60 */
+ DWORD PNP_Function60(
+ [in] handle_t hBinding);
+
+ /* Function 61 */
+ DWORD PNP_GetCustomDevProp(
+ [in] handle_t hBinding,
+ [in, string, ref, range(0, PNP_MAX_DEVICE_ID_LEN)] LPWSTR pDeviceID,
+ [in, string, ref, range(0, PNP_MAX_STRING_LEN)] LPWSTR CustomPropName,
+ [out] DWORD *pulRegDataType,
+ [out, size_is(*pulLength), length_is(*pulTransferLen)] BYTE *Buffer,
+ [out] PNP_RPC_STRING_LEN *pulTransferLen,
+ [in, out] PNP_RPC_STRING_LEN *pulLength,
+ [in] DWORD ulFlags);
+
+ /* Function 62 */
+ DWORD PNP_GetVersionInternal(
+ [in] handle_t hBinding,
+ [in, out] WORD *pwVersion);
+
+ /* Function 63 */
+ DWORD PNP_GetBlockedDriverInfo(
+ [in] handle_t hBinding,
+ [out, size_is(*pulLength), length_is(*pulTransferLen)] BYTE *Buffer,
+ [out] PNP_RPC_BUFFER_SIZE *pulTransferLen,
+ [in, out] PNP_RPC_BUFFER_SIZE *pulLength,
+ [in] DWORD ulFlags);
+
+ /* Function 64 */
+ DWORD PNP_GetServerSideDeviceInstallFlags(
+ [in] handle_t hBinding,
+ [out] DWORD *pulSSDIFlags,
+ [in] DWORD ulFlags);
+
+ /* Function 65 */
+ DWORD PNP_GetObjectPropKeys(
+ [in] handle_t hBinding,
+ [in, string, ref, range(0, PNP_MAX_STRING_LEN)] LPWSTR ObjectName,
+ [in] DWORD ObjectType,
+ [in, string, unique, range(0, PNP_MAX_CULTURE_NAME_LEN)] LPWSTR
PropertyCultureName,
+ [in, out] PNP_PROP_COUNT *PropertyCount,
+ [out] PNP_PROP_COUNT *TransferLen,
+ [out, size_is(*PropertyCount), length_is(*TransferLen)] DEVPROPKEY
*PropertyKeys,
+ [in] DWORD Flags);
+
+ /* Function 66 */
+ DWORD PNP_GetObjectProp(
+ [in] handle_t hBinding,
+ [in, string, ref, range(0, PNP_MAX_STRING_LEN)] LPWSTR ObjectName,
+ [in] DWORD ObjectType,
+ [in, string, unique, range(0, PNP_MAX_CULTURE_NAME_LEN)] LPWSTR
PropertyCultureName,
+ [in] const DEVPROPKEY *PropertyKey,
+ [out] DEVPROPTYPE *PropertyType,
+ [in, out] PNP_PROP_SIZE *PropertySize,
+ [out] PNP_PROP_SIZE *TransferLen,
+ [out, size_is(*PropertySize), length_is(*TransferLen)] BYTE *PropertyBuffer,
+ [in] DWORD Flags);
+
+ /* Function 67 */
+ DWORD PNP_SetObjectProp(
+ [in] handle_t hBinding,
+ [in, string, ref, range(0, PNP_MAX_STRING_LEN)] LPWSTR ObjectName,
+ [in] DWORD ObjectType,
+ [in, string, unique, range(0, PNP_MAX_CULTURE_NAME_LEN)] LPWSTR
PropertyCultureName,
+ [in] const DEVPROPKEY *PropertyKey,
+ [in] DEVPROPTYPE PropertyType,
+ [in] PNP_PROP_SIZE PropertySize,
+ [in, unique, size_is(PropertySize)] BYTE *PropertyBuffer,
+ [in] DWORD Flags);
}