ReactOS 0.4.16-dev-297-gc569aee
fxdeviceinit.hpp
Go to the documentation of this file.
1/*++
2
3Copyright (c) Microsoft Corporation
4
5Module Name:
6
7 FxDeviceInit.hpp
8
9Abstract:
10
11
12Author:
13
14
15Environment:
16
17 kernel mode only
18
19Revision History:
20
21--*/
22
23#ifndef __FXDEVICEINIT_HPP__
24#define __FXDEVICEINIT_HPP__
25
30};
31
34
36
38
40
42};
43
46
48
50};
51
54
56
58
60
62
64};
65
66struct FdoInit {
68
70
72
74
76};
77
78
79
80
82
85 VOID
86 )
87 {
89 Flags = 0;
90 }
91
93
95};
96
97//
98// The typedef for a pointer to this structure is exposed in wdfdevice.h
99//
100struct WDFDEVICE_INIT : public FxStump {
101public:
104 );
105
107
108 VOID
109 SetPdo(
111 );
112
113 BOOLEAN
115 VOID
116 )
117 {
119 }
120
121 BOOLEAN
123 VOID
124 )
125 {
127 }
128
129 BOOLEAN
131 VOID
132 )
133 {
135 }
136
137 BOOLEAN
139 VOID
140 )
141 {
143 }
144 BOOLEAN
146 VOID
147 )
148 {
150 }
151
152 BOOLEAN
154 VOID
155 )
156 {
158 }
159
160 BOOLEAN
162 VOID
163 )
164 {
165 if (DeviceName != NULL ||
167 return TRUE;
168 }
169 else {
170 return FALSE;
171 }
172 }
173
174 BOOLEAN
176 VOID
177 );
178
179 BOOLEAN
181 VOID
182 )
183 {
185 return TRUE;
186 }
187 else if (PnpPower.PowerPolicyOwner == WdfFalse) {
188 return FALSE;
189 }
190 else if (IsPdoInit()) {
191 //
192 // This is a PDO. If we are a raw PDO, we own pwr policy.
193 //
194 return Pdo.Raw;
195 }
196 else {
197 ASSERT(IsFdoInit());
198
199 //
200 // This is an FDO. If we are not a filter, we own pwr policy.
201 //
202 return (Fdo.Filter == FALSE ? TRUE : FALSE);
203 }
204 }
205
209 __in PFX_DRIVER_GLOBALS FxDriverGlobals,
211 );
212
213 static
219 );
220
221 VOID
224 );
225
226 VOID
229 );
230
231public:
233
235
237
239
241
243
245
246 //
247 // If set, the Cx/Client intends to leverage Self IO Target
248 //
250
252
254
256
258
260
262
264
266
268
270
272
274
279
280 //
281 // Class extension's device init.
282 //
284
285#if (FX_CORE_MODE == FX_CORE_USER_MODE)
286 //
287 // IoType preference for IOCTL
288 //
290
291 //
292 // Direct I/O threshold
293 //
295
296 //
297 // Weak reference to host side device stack
298 //
299 IWudfDeviceStack * DevStack;
300
301 //
302 // Kernel redirector's side object name.
303 //
305
306 //
307 // PnP devinode hw key handle
308 //
310
311 //
312 // Registry sub-path name containing driver configuration information.
313 // The registry path name is relative to the "device key".
314 //
316
317 //
318 // PDO Instance ID
319 //
321
322 //
323 // This ID is used by Host to associated host device and its driver info.
324 //
326#endif
327
328};
329
330#endif // __FXDEVICEINIT_HPP__
unsigned char BOOLEAN
ACPI_PHYSICAL_ADDRESS ACPI_SIZE BOOLEAN Warn UINT32 *TableIdx UINT32 ACPI_TABLE_HEADER *OutTableHeader ACPI_TABLE_HEADER **OutTable ACPI_HANDLE UINT32 ACPI_WALK_CALLBACK ACPI_WALK_CALLBACK void void **ReturnValue UINT32 ACPI_BUFFER *RetPathPtr ACPI_OBJECT_HANDLER void *Data ACPI_OBJECT_HANDLER void **Data ACPI_STRING ACPI_OBJECT_LIST ACPI_BUFFER *ReturnObjectBuffer ACPI_DEVICE_INFO **ReturnBuffer ACPI_HANDLE Parent
Definition: acpixf.h:732
LONG NTSTATUS
Definition: precomp.h:26
#define __in
Definition: dbghelp.h:35
#define NULL
Definition: types.h:112
#define TRUE
Definition: types.h:120
#define FALSE
Definition: types.h:117
#define DEVICE_TYPE
Definition: guid.c:10
FxDeviceInitType
@ FxDeviceInitTypeControlDevice
@ FxDeviceInitTypeFdo
@ FxDeviceInitTypePdo
_Must_inspect_result_ _In_ PWDFCXDEVICE_INIT CxDeviceInit
Definition: fxdynamics.h:1012
#define ASSERT(a)
Definition: mode.c:44
#define FILE_AUTOGENERATED_DEVICE_NAME
Definition: iotypes.h:138
#define _Must_inspect_result_
Definition: no_sal2.h:62
#define _In_
Definition: no_sal2.h:158
PFN_WDF_DEVICE_SHUTDOWN_NOTIFICATION ShutdownNotification
ControlInit(VOID)
WDF_CHILD_LIST_CONFIG ListConfig
WDF_FDO_EVENT_CALLBACKS EventCallbacks
WDF_OBJECT_ATTRIBUTES ListConfigAttributes
MdDeviceObject PhysicalDevice
BOOLEAN Filter
WDF_OBJECT_ATTRIBUTES Attributes
WDF_TRI_STATE AutoForwardCleanupClose
WDF_FILEOBJECT_CLASS Class
WDF_FILEOBJECT_CONFIG Callbacks
WDF_POWER_POLICY_EVENT_CALLBACKS PolicyEventCallbacks
WDF_PNPPOWER_EVENT_CALLBACKS PnpPowerEventCallbacks
WDF_TRI_STATE PowerPolicyOwner
FxPowerPolicyStateCallback * PowerPolicyStateCallbacks
FxPowerStateCallback * PowerStateCallbacks
FxPnpStateCallback * PnpStateCallbacks
BOOLEAN DeviceClassSet
FxString * Sddl
PWSTR ConfigRegistryPath
ControlInit Control
BOOLEAN PowerPageable
FxString * DeviceName
SecurityInit Security
FxDeviceInitType InitType
LIST_ENTRY CxDeviceInitListHead
VOID SetPdo(__in FxDevice *Parent)
FileObjectInit FileObject
PFX_DRIVER_GLOBALS DriverGlobals
BOOLEAN IsNotFdoInit(VOID)
BOOLEAN ShouldCreateSecure(VOID)
PFN_WDF_IO_IN_CALLER_CONTEXT IoInCallerContextCallback
BOOLEAN IsNotPdoInit(VOID)
FxDriver * Driver
WDF_DEVICE_IO_TYPE DeviceControlIoType
IWudfDeviceStack * DevStack
BOOLEAN IsControlDeviceInit(VOID)
VOID AddCxDeviceInit(__in PWDFCXDEVICE_INIT CxDeviceInit)
VOID AssignIoType(_In_ PWDF_IO_TYPE_CONFIG IoTypeConfig)
WDF_DEVICE_IO_TYPE ReadWriteIoType
_Must_inspect_result_ NTSTATUS AssignName(__in PFX_DRIVER_GLOBALS FxDriverGlobals, __in const UNICODE_STRING *Name)
PnpPowerInit PnpPower
BOOLEAN CreatedOnStack
FxIrpPreprocessInfo * PreprocessInfo
static _Must_inspect_result_ PWDFDEVICE_INIT _AllocateControlDeviceInit(__in FxDriver *Driver, __in const UNICODE_STRING *SDDLString)
BOOLEAN IsNotControlDeviceInit(VOID)
ULONG RemoveLockOptionFlags
BOOLEAN IsPwrPolOwner(VOID)
ULONG DirectTransferThreshold
FxDevice * CreatedDevice
BOOLEAN IsPdoInit(VOID)
DEVICE_TYPE DeviceType
WDF_RELEASE_HARDWARE_ORDER_ON_FAILURE ReleaseHardwareOrderOnFailure
BOOLEAN RequiresSelfIoTarget
BOOLEAN HasName(VOID)
WDF_OBJECT_ATTRIBUTES RequestAttributes
BOOLEAN IsFdoInit(VOID)
Definition: typedefs.h:120
uint16_t * PWSTR
Definition: typedefs.h:56
uint32_t ULONG
Definition: typedefs.h:59
_Must_inspect_result_ _In_ WDFDRIVER Driver
Definition: wdfcontrol.h:83
_Must_inspect_result_ _In_ WDFDRIVER _In_ CONST UNICODE_STRING * SDDLString
Definition: wdfcontrol.h:86
EVT_WDF_DEVICE_SHUTDOWN_NOTIFICATION * PFN_WDF_DEVICE_SHUTDOWN_NOTIFICATION
Definition: wdfcontrol.h:62
enum _WDF_FILEOBJECT_CLASS WDF_FILEOBJECT_CLASS
_In_ PWDFDEVICE_INIT _In_ PWDF_IO_TYPE_CONFIG IoTypeConfig
Definition: wdfdevice.h:4394
EVT_WDF_IO_IN_CALLER_CONTEXT * PFN_WDF_IO_IN_CALLER_CONTEXT
Definition: wdfdevice.h:1728
enum _WDF_DEVICE_IO_TYPE WDF_DEVICE_IO_TYPE
enum _WDF_RELEASE_HARDWARE_ORDER_ON_FAILURE WDF_RELEASE_HARDWARE_ORDER_ON_FAILURE
_Must_inspect_result_ _In_ PWDFDEVICE_INIT _In_opt_ PCUNICODE_STRING DeviceName
Definition: wdfdevice.h:3275
_Must_inspect_result_ _In_ WDFDEVICE Fdo
Definition: wdffdo.h:461
@ WdfTrue
Definition: wdftypes.h:88
@ WdfFalse
Definition: wdftypes.h:87
enum _WDF_TRI_STATE WDF_TRI_STATE
_Must_inspect_result_ _In_ ULONG Flags
Definition: wsk.h:170
unsigned char UCHAR
Definition: xmlstorage.h:181