ReactOS 0.4.15-dev-8061-g57b775e
fxwmiprovider.hpp
Go to the documentation of this file.
1/*++
2
3Copyright (c) Microsoft Corporation
4
5Module Name:
6
7 FxWmiDataBlock.hpp
8
9Abstract:
10
11 This module implements the WMI data block object
12
13Author:
14
15
16
17
18Environment:
19
20 Both kernel and user mode
21
22Revision History:
23
24
25--*/
26
27#ifndef _FXWMIPROVIDER_H_
28#define _FXWMIPROVIDER_H_
29
30
32
34
36 PFX_DRIVER_GLOBALS FxDriverGlobals
37 ) :
38 FxCallback(FxDriverGlobals),
40 {
41 }
42
44 {
45 }
46
50 __in WDFDEVICE Device,
51 __in WDFWMIPROVIDER WmiProvider,
54 )
55 {
57
59
60 if (m_Method != NULL) {
64 }
65 else {
67 }
68
69 return status;
70 }
71};
72
74
76
77public:
79 __in PFX_DRIVER_GLOBALS FxDriverGlobals,
82 );
83
85
86 static
89 _Create(
90 __in PFX_DRIVER_GLOBALS CallersGlobals,
91 __in WDFDEVICE Device,
94 __out WDFWMIPROVIDER* WmiProvider,
96 );
97
100 VOID
101 )
102 {
103 return m_Parent->GetDevice();
104 }
105
106 GUID*
108 VOID
109 )
110 {
111 return &m_Guid;
112 }
113
114 ULONG
116 VOID
117 )
118 {
119 return m_Flags;
120 }
121
122 ULONG
124 VOID
125 )
126 {
128 }
129
130 ULONG
132 VOID
133 );
134
135 BOOLEAN
137 VOID
138 )
139 {
141 }
142
143 BOOLEAN
146 )
147 {
148 switch (Control) {
151 default: ASSERT(FALSE); return FALSE;
152 }
153 }
154
157 VOID
158 )
159 {
160 return m_TracingHandle;
161 }
162
163 VOID
165 __in ULONGLONG TracingHandle
166 )
167 {
168 m_TracingHandle = TracingHandle;
169 }
170
171 WDFWMIPROVIDER
173 VOID
174 )
175 {
176 return (WDFWMIPROVIDER) GetObjectHandle();
177 }
178
179 BOOLEAN
181 VOID
182 )
183 {
185 }
186
192 );
193
198 __in BOOLEAN NoErrorIfPresent = FALSE
199 );
200
201 VOID
204 );
205
206 ULONG
209 );
210
216 );
217
223 );
224
225 // begin FxObject overrides
226 virtual
227 BOOLEAN
228 Dispose(
229 VOID
230 );
231 // end FxObject overrides
232
233protected:
237 };
238
243 __in BOOLEAN NoErrorIfPresent,
246 );
247
248protected:
249 //
250 // List entry used by FxWmiIrpHandler to hold the list of WMI providers
251 //
253
255
257
259
261
262
263
264
265
267
269
270 union {
271 //
272 // Set with values from WDF_WMI_PROVIDER_FLAGS
273 //
275
276 //
277 // Not used by the code, but by the debug extension
278 //
279 struct {
284 };
285
287
289
291
293};
294
295#endif // _FXWMIPROVIDER_H_
unsigned char BOOLEAN
LONG NTSTATUS
Definition: precomp.h:26
@ Update
Definition: registry.c:565
void __inline CallbackStart(VOID)
Definition: fxcallback.hpp:64
void __inline CallbackEnd(VOID)
Definition: fxcallback.hpp:74
__inline CfxDevice * GetDevice(VOID)
Definition: fxpackage.hpp:46
LIST_ENTRY m_InstanceListHead
FxWmiIrpHandler * m_Parent
friend FxWmiIrpHandler
struct FxWmiProvider::@4826::@4828 m_FlagsByName
ULONGLONG m_TracingHandle
GUID * GetGUID(VOID)
ULONG m_MinInstanceBufferSize
static _Must_inspect_result_ NTSTATUS _Create(__in PFX_DRIVER_GLOBALS CallersGlobals, __in WDFDEVICE Device, __in_opt PWDF_OBJECT_ATTRIBUTES ProviderAttributes, __in PWDF_WMI_PROVIDER_CONFIG WmiProviderConfig, __out WDFWMIPROVIDER *WmiProvider, __out FxWmiProvider **Provider)
BOOLEAN m_EventControlEnabled
LIST_ENTRY m_ListEntry
_Must_inspect_result_ FxWmiInstance * GetInstanceReferencedLocked(__in ULONG Index, __in PVOID Tag)
BOOLEAN m_RemoveGuid
FxWmiProviderFunctionControlCallback m_FunctionControl
ULONG GetFlags(VOID)
ULONG GetInstanceIndex(__in FxWmiInstance *Instance)
_Must_inspect_result_ NTSTATUS FunctionControl(__in WDF_WMI_PROVIDER_CONTROL Control, __in BOOLEAN Enable)
BOOLEAN m_DataBlockControlEnabled
CfxDevice * GetDevice(VOID)
ULONGLONG GetTracingHandle(VOID)
WDFWMIPROVIDER GetHandle(VOID)
BOOLEAN IsFunctionControlSupported(VOID)
VOID SetTracingHandle(__in ULONGLONG TracingHandle)
virtual BOOLEAN Dispose(VOID)
_Must_inspect_result_ NTSTATUS AddInstanceLocked(__in FxWmiInstance *Instance, __in BOOLEAN NoErrorIfPresent, __out PBOOLEAN Update, __in AddInstanceAction Action=AddInstanceToTail)
BOOLEAN IsEnabled(__in WDF_WMI_PROVIDER_CONTROL Control)
ULONG GetRegistrationFlagsLocked(VOID)
BOOLEAN IsEventOnly(VOID)
_Must_inspect_result_ FxWmiInstance * GetInstanceReferenced(__in ULONG Index, __in PVOID Tag)
ULONG GetMinInstanceBufferSize(VOID)
#define __in
Definition: dbghelp.h:35
#define __in_opt
Definition: dbghelp.h:38
#define __out
Definition: dbghelp.h:62
#define NULL
Definition: types.h:112
#define FALSE
Definition: types.h:117
return pObject GetObjectHandle()
#define FLAG_TO_BOOL(_Flags, _FlagMask)
Definition: fxobject.hpp:125
@ RemoveInstance
Definition: fxpkgpnp.hpp:430
@ AddInstance
Definition: fxpkgpnp.hpp:429
#define ASSERT(a)
Definition: mode.c:44
#define _Must_inspect_result_
Definition: ms_sal.h:558
#define UNREFERENCED_PARAMETER(P)
Definition: ntbasedef.h:317
_In_ ULONGLONG _In_ ULONGLONG _In_ BOOLEAN Enable
Definition: ntddpcm.h:142
#define STATUS_SUCCESS
Definition: shellext.h:65
PFN_WDF_WMI_PROVIDER_FUNCTION_CONTROL m_Method
FxWmiProviderFunctionControlCallback(PFX_DRIVER_GLOBALS FxDriverGlobals)
_Must_inspect_result_ NTSTATUS Invoke(__in WDFDEVICE Device, __in WDFWMIPROVIDER WmiProvider, __in WDF_WMI_PROVIDER_CONTROL Control, __in BOOLEAN Enable)
Definition: typedefs.h:120
Definition: ps.c:97
unsigned char * PBOOLEAN
Definition: typedefs.h:53
uint32_t ULONG
Definition: typedefs.h:59
uint64_t ULONGLONG
Definition: typedefs.h:67
_Must_inspect_result_ _In_ WDFDEVICE Device
Definition: wdfchildlist.h:474
_Must_inspect_result_ _In_ WDFDEVICE _In_ PWDF_CHILD_LIST_CONFIG Config
Definition: wdfchildlist.h:476
_In_ WDFCOLLECTION _In_ ULONG Index
_Must_inspect_result_ _In_ WDFDEVICE _In_ BOOLEAN _In_opt_ PVOID Tag
Definition: wdfdevice.h:4065
_In_ WDFIOTARGET _In_ _Strict_type_match_ WDF_IO_TARGET_SENT_IO_ACTION Action
Definition: wdfiotarget.h:510
_In_ WDF_WMI_PROVIDER_CONTROL Control
Definition: wdfwmi.h:166
@ WdfWmiEventControl
Definition: wdfwmi.h:52
@ WdfWmiInstanceControl
Definition: wdfwmi.h:53
@ WdfWmiProviderEventOnly
Definition: wdfwmi.h:69
_Must_inspect_result_ _In_ WDFDEVICE _In_ PWDF_WMI_INSTANCE_CONFIG _In_opt_ PWDF_OBJECT_ATTRIBUTES _Out_opt_ WDFWMIINSTANCE * Instance
Definition: wdfwmi.h:481
WDF_EXTERN_C_START enum _WDF_WMI_PROVIDER_CONTROL WDF_WMI_PROVIDER_CONTROL
_Must_inspect_result_ _In_ WDFDEVICE _In_ PWDF_WMI_PROVIDER_CONFIG WmiProviderConfig
Definition: wdfwmi.h:358
_Must_inspect_result_ _In_ WDFDEVICE _In_ PWDF_WMI_PROVIDER_CONFIG _In_opt_ PWDF_OBJECT_ATTRIBUTES _Out_ WDFWMIPROVIDER * WmiProvider
Definition: wdfwmi.h:363
EVT_WDF_WMI_PROVIDER_FUNCTION_CONTROL * PFN_WDF_WMI_PROVIDER_FUNCTION_CONTROL
Definition: wdfwmi.h:171
_Must_inspect_result_ _In_ WDFDEVICE _In_ PWDF_WMI_PROVIDER_CONFIG _In_opt_ PWDF_OBJECT_ATTRIBUTES ProviderAttributes
Definition: wdfwmi.h:360