mirror of
https://github.com/reactos/reactos.git
synced 2024-11-20 14:30:57 +00:00
[SETUPAPI]
- Implement CM_Get_Device_Interface_AliasA, CM_Get_Device_Interface_AliasW and CM_Get_Device_Interface_Alias_ExW. - Add a stub for CM_Get_Device_Interface_Alias_ExA. - Implement the obsolete functions CM_Query_Remove_SubTree[_Ex] and CM_Remove_SubTree[_Ex]. svn path=/trunk/; revision=50820
This commit is contained in:
parent
634966f644
commit
d0515abbea
2 changed files with 163 additions and 8 deletions
|
@ -2284,6 +2284,109 @@ CONFIGRET WINAPI CM_Get_Device_ID_Size_Ex(
|
|||
}
|
||||
|
||||
|
||||
/***********************************************************************
|
||||
* CM_Get_Device_Interface_AliasA [SETUPAPI.@]
|
||||
*/
|
||||
CONFIGRET WINAPI CM_Get_Device_Interface_AliasA(
|
||||
LPCSTR pszDeviceInterface, LPGUID AliasInterfaceGuid,
|
||||
LPSTR pszAliasDeviceInterface, PULONG pulLength, ULONG ulFlags)
|
||||
{
|
||||
TRACE("%p %p %p %p %lu\n", pszDeviceInterface, AliasInterfaceGuid,
|
||||
pszAliasDeviceInterface, pulLength, ulFlags);
|
||||
|
||||
return CM_Get_Device_Interface_Alias_ExA(pszDeviceInterface,
|
||||
AliasInterfaceGuid, pszAliasDeviceInterface, pulLength,
|
||||
ulFlags, NULL);
|
||||
}
|
||||
|
||||
|
||||
/***********************************************************************
|
||||
* CM_Get_Device_Interface_AliasW [SETUPAPI.@]
|
||||
*/
|
||||
CONFIGRET WINAPI CM_Get_Device_Interface_AliasW(
|
||||
LPCWSTR pszDeviceInterface, LPGUID AliasInterfaceGuid,
|
||||
LPWSTR pszAliasDeviceInterface, PULONG pulLength, ULONG ulFlags)
|
||||
{
|
||||
TRACE("%p %p %p %p %lu\n", pszDeviceInterface, AliasInterfaceGuid,
|
||||
pszAliasDeviceInterface, pulLength, ulFlags);
|
||||
|
||||
return CM_Get_Device_Interface_Alias_ExW(pszDeviceInterface,
|
||||
AliasInterfaceGuid, pszAliasDeviceInterface, pulLength,
|
||||
ulFlags, NULL);
|
||||
}
|
||||
|
||||
|
||||
/***********************************************************************
|
||||
* CM_Get_Device_Interface_Alias_ExA [SETUPAPI.@]
|
||||
*/
|
||||
CONFIGRET WINAPI CM_Get_Device_Interface_Alias_ExA(
|
||||
LPCSTR pszDeviceInterface, LPGUID AliasInterfaceGuid, LPSTR pszAliasDeviceInterface,
|
||||
PULONG pulLength, ULONG ulFlags, HMACHINE hMachine)
|
||||
{
|
||||
FIXME("%p %p %p %p %lu %lx\n", pszDeviceInterface, AliasInterfaceGuid,
|
||||
pszAliasDeviceInterface, pulLength, ulFlags, hMachine);
|
||||
|
||||
return CR_CALL_NOT_IMPLEMENTED;
|
||||
}
|
||||
|
||||
|
||||
/***********************************************************************
|
||||
* CM_Get_Device_Interface_Alias_ExW [SETUPAPI.@]
|
||||
*/
|
||||
CONFIGRET WINAPI CM_Get_Device_Interface_Alias_ExW(
|
||||
LPCWSTR pszDeviceInterface, LPGUID AliasInterfaceGuid, LPWSTR pszAliasDeviceInterface,
|
||||
PULONG pulLength, ULONG ulFlags, HMACHINE hMachine)
|
||||
{
|
||||
RPC_BINDING_HANDLE BindingHandle = NULL;
|
||||
ULONG ulTransferLength;
|
||||
CONFIGRET ret = CR_SUCCESS;
|
||||
|
||||
TRACE("%p %p %p %p %lu %lx\n", pszDeviceInterface, AliasInterfaceGuid,
|
||||
pszAliasDeviceInterface, pulLength, ulFlags, hMachine);
|
||||
|
||||
if (pszDeviceInterface == NULL ||
|
||||
AliasInterfaceGuid == NULL ||
|
||||
pszAliasDeviceInterface == NULL ||
|
||||
pulLength == NULL)
|
||||
return CR_INVALID_POINTER;
|
||||
|
||||
if (ulFlags != 0)
|
||||
return CR_INVALID_FLAG;
|
||||
|
||||
if (hMachine != NULL)
|
||||
{
|
||||
BindingHandle = ((PMACHINE_INFO)hMachine)->BindingHandle;
|
||||
if (BindingHandle == NULL)
|
||||
return CR_FAILURE;
|
||||
}
|
||||
else
|
||||
{
|
||||
if (!PnpGetLocalHandles(&BindingHandle, NULL))
|
||||
return CR_FAILURE;
|
||||
}
|
||||
|
||||
ulTransferLength = *pulLength;
|
||||
|
||||
RpcTryExcept
|
||||
{
|
||||
ret = PNP_GetInterfaceDeviceAlias(BindingHandle,
|
||||
(LPWSTR)pszDeviceInterface,
|
||||
AliasInterfaceGuid,
|
||||
pszAliasDeviceInterface,
|
||||
pulLength,
|
||||
&ulTransferLength,
|
||||
0);
|
||||
}
|
||||
RpcExcept(EXCEPTION_EXECUTE_HANDLER)
|
||||
{
|
||||
ret = RpcStatusToCmStatus(RpcExceptionCode());
|
||||
}
|
||||
RpcEndExcept;
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
||||
/***********************************************************************
|
||||
* CM_Get_First_Log_Conf [SETUPAPI.@]
|
||||
*/
|
||||
|
@ -3534,6 +3637,32 @@ CONFIGRET WINAPI CM_Open_DevNode_Key_Ex(
|
|||
}
|
||||
|
||||
|
||||
/***********************************************************************
|
||||
* CM_Query_Remove_SubTree [SETUPAPI.@]
|
||||
*
|
||||
* This function is obsolete in Windows XP and above.
|
||||
*/
|
||||
CONFIGRET WINAPI CM_Query_Remove_SubTree(
|
||||
DEVINST dnAncestor, ULONG ulFlags)
|
||||
{
|
||||
TRACE("%lx %lx\n", dnAncestor, ulFlags);
|
||||
return CR_CALL_NOT_IMPLEMENTED;
|
||||
}
|
||||
|
||||
|
||||
/***********************************************************************
|
||||
* CM_Query_Remove_SubTree_Ex [SETUPAPI.@]
|
||||
*
|
||||
* This function is obsolete in Windows XP and above.
|
||||
*/
|
||||
CONFIGRET WINAPI CM_Query_Remove_SubTree_Ex(
|
||||
DEVINST dnAncestor, ULONG ulFlags, HMACHINE hMachine)
|
||||
{
|
||||
TRACE("%lx %lx %lx\n", dnAncestor, ulFlags, hMachine);
|
||||
return CR_CALL_NOT_IMPLEMENTED;
|
||||
}
|
||||
|
||||
|
||||
/***********************************************************************
|
||||
* CM_Reenumerate_DevNode [SETUPAPI.@]
|
||||
*/
|
||||
|
@ -3603,6 +3732,32 @@ CM_Reenumerate_DevNode_Ex(
|
|||
}
|
||||
|
||||
|
||||
/***********************************************************************
|
||||
* CM_Remove_SubTree [SETUPAPI.@]
|
||||
*
|
||||
* This function is obsolete in Windows XP and above.
|
||||
*/
|
||||
CONFIGRET WINAPI CM_Remove_SubTree(
|
||||
DEVINST dnAncestor, ULONG ulFlags)
|
||||
{
|
||||
TRACE("%lx %lx\n", dnAncestor, ulFlags);
|
||||
return CR_CALL_NOT_IMPLEMENTED;
|
||||
}
|
||||
|
||||
|
||||
/***********************************************************************
|
||||
* CM_Remove_SubTree_Ex [SETUPAPI.@]
|
||||
*
|
||||
* This function is obsolete in Windows XP and above.
|
||||
*/
|
||||
CONFIGRET WINAPI CM_Remove_SubTree_Ex(
|
||||
DEVINST dnAncestor, ULONG ulFlags, HMACHINE hMachine)
|
||||
{
|
||||
TRACE("%lx %lx %lx\n", dnAncestor, ulFlags, hMachine);
|
||||
return CR_CALL_NOT_IMPLEMENTED;
|
||||
}
|
||||
|
||||
|
||||
/***********************************************************************
|
||||
* CM_Request_Eject_PC [SETUPAPI.@]
|
||||
*/
|
||||
|
|
|
@ -90,10 +90,10 @@
|
|||
@ stdcall CM_Get_Device_ID_List_Size_ExW(ptr wstr long long)
|
||||
@ stdcall CM_Get_Device_ID_Size(ptr long long)
|
||||
@ stdcall CM_Get_Device_ID_Size_Ex(ptr long long long)
|
||||
@ stub CM_Get_Device_Interface_AliasA
|
||||
@ stub CM_Get_Device_Interface_AliasW
|
||||
@ stub CM_Get_Device_Interface_Alias_ExA
|
||||
@ stub CM_Get_Device_Interface_Alias_ExW
|
||||
@ stdcall CM_Get_Device_Interface_AliasA(str ptr str ptr long)
|
||||
@ stdcall CM_Get_Device_Interface_AliasW(wstr ptr wstr ptr long)
|
||||
@ stdcall CM_Get_Device_Interface_Alias_ExA(str ptr str ptr long long)
|
||||
@ stdcall CM_Get_Device_Interface_Alias_ExW(wstr ptr wstr ptr long long)
|
||||
@ stub CM_Get_Device_Interface_ListA
|
||||
@ stub CM_Get_Device_Interface_ListW
|
||||
@ stub CM_Get_Device_Interface_List_ExA
|
||||
|
@ -163,8 +163,8 @@
|
|||
@ stub CM_Query_Arbitrator_Free_Data_Ex
|
||||
@ stub CM_Query_Arbitrator_Free_Size
|
||||
@ stub CM_Query_Arbitrator_Free_Size_Ex
|
||||
@ stub CM_Query_Remove_SubTree
|
||||
@ stub CM_Query_Remove_SubTree_Ex
|
||||
@ stdcall CM_Query_Remove_SubTree(long long)
|
||||
@ stdcall CM_Query_Remove_SubTree_Ex(long long long)
|
||||
@ stub CM_Query_Resource_Conflict_List
|
||||
@ stdcall CM_Reenumerate_DevNode(long long)
|
||||
@ stdcall CM_Reenumerate_DevNode_Ex(long long long)
|
||||
|
@ -174,8 +174,8 @@
|
|||
@ stub CM_Register_Device_InterfaceW
|
||||
@ stub CM_Register_Device_Interface_ExA
|
||||
@ stub CM_Register_Device_Interface_ExW
|
||||
@ stub CM_Remove_SubTree
|
||||
@ stub CM_Remove_SubTree_Ex
|
||||
@ stdcall CM_Remove_SubTree(long long)
|
||||
@ stdcall CM_Remove_SubTree_Ex(long long long)
|
||||
@ stub CM_Request_Device_EjectA
|
||||
@ stub CM_Request_Device_EjectW
|
||||
@ stub CM_Request_Device_Eject_ExA
|
||||
|
|
Loading…
Reference in a new issue