diff --git a/dlls/setupapi/setupapi.spec b/dlls/setupapi/setupapi.spec index cea6daca3f5..d633211db99 100644 --- a/dlls/setupapi/setupapi.spec +++ b/dlls/setupapi/setupapi.spec @@ -168,8 +168,8 @@ @ stub CM_Remove_SubTree_Ex @ stub CM_Remove_Unmarked_Children @ stub CM_Remove_Unmarked_Children_Ex -@ stub CM_Request_Device_EjectA -@ stub CM_Request_Device_EjectW +@ stdcall CM_Request_Device_EjectA(ptr ptr ptr long long) +@ stdcall CM_Request_Device_EjectW(ptr ptr ptr long long) @ stub CM_Request_Eject_PC @ stub CM_Reset_Children_Marks @ stub CM_Reset_Children_Marks_Ex diff --git a/dlls/setupapi/stubs.c b/dlls/setupapi/stubs.c index 4994ca4854d..4db32dd51c7 100644 --- a/dlls/setupapi/stubs.c +++ b/dlls/setupapi/stubs.c @@ -696,3 +696,21 @@ BOOL WINAPI SetupDiEnumDriverInfoW(HDEVINFO DeviceInfoSet, PSP_DEVINFO_DATA Devi SetLastError(ERROR_CALL_NOT_IMPLEMENTED); return FALSE; } + +/*********************************************************************** + * CM_Request_Device_EjectA (SETUPAPI.@) + */ +CONFIGRET WINAPI CM_Request_Device_EjectA(DEVINST dev, PPNP_VETO_TYPE type, LPSTR name, ULONG length, ULONG flags) +{ + FIXME("(0x%08x, %p, %p, %u, 0x%08x) stub\n", dev, type, name, length, flags); + return CR_SUCCESS; +} + +/*********************************************************************** + * CM_Request_Device_EjectW (SETUPAPI.@) + */ +CONFIGRET WINAPI CM_Request_Device_EjectW(DEVINST dev, PPNP_VETO_TYPE type, LPWSTR name, ULONG length, ULONG flags) +{ + FIXME("(0x%08x, %p, %p, %u, 0x%08x) stub\n", dev, type, name, length, flags); + return CR_SUCCESS; +} diff --git a/include/cfgmgr32.h b/include/cfgmgr32.h index da091153e4d..15340a60c64 100644 --- a/include/cfgmgr32.h +++ b/include/cfgmgr32.h @@ -175,6 +175,23 @@ typedef CHAR *DEVNODEID_A, *DEVINSTID_A; typedef WCHAR *DEVNODEID_W, *DEVINSTID_W; typedef ULONG REGDISPOSITION; +typedef enum _PNP_VETO_TYPE +{ + PNP_VetoTypeUnknown, + PNP_VetoLegacyDevice, + PNP_VetoPendingClose, + PNP_VetoWindowsApp, + PNP_VetoWindowsService, + PNP_VetoOutstandingOpen, + PNP_VetoDevice, + PNP_VetoDriver, + PNP_VetoIllegalDeviceRequest, + PNP_VetoInsufficientPower, + PNP_VetoNonDisableable, + PNP_VetoLegacyDriver, + PNP_VetoInsufficientRights +} PNP_VETO_TYPE, *PPNP_VETO_TYPE; + DECL_WINELIB_CFGMGR32_TYPE_AW(DEVNODEID) DECL_WINELIB_CFGMGR32_TYPE_AW(DEVINSTID) @@ -213,6 +230,9 @@ CMAPI CONFIGRET WINAPI CM_Locate_DevNodeW(PDEVINST,DEVINSTID_W,ULONG); #define CM_Locate_DevNode WINELIB_NAME_AW(CM_Locate_DevNode) CMAPI CONFIGRET WINAPI CM_Open_DevNode_Key(DEVINST dnDevInst, REGSAM access, ULONG ulHardwareProfile, REGDISPOSITION disposition, PHKEY phkDevice, ULONG ulFlags); +CMAPI CONFIGRET WINAPI CM_Request_Device_EjectA(DEVINST dev, PPNP_VETO_TYPE type, LPSTR name, ULONG length, ULONG flags); +CMAPI CONFIGRET WINAPI CM_Request_Device_EjectW(DEVINST dev, PPNP_VETO_TYPE type, LPWSTR name, ULONG length, ULONG flags); +#define CM_Request_Device_Eject WINELIB_NAME_AW(CM_Get_Device_ID_List_Ex) #ifdef __cplusplus }