ReactOS 0.4.15-dev-7924-g5949c20
ioprivshared.hpp
Go to the documentation of this file.
1/*++
2
3Copyright (c) Microsoft. All rights reserved.
4
5Module Name:
6
7 iopriv.hpp
8
9Abstract:
10
11 This module defines private interfaces for the I/O package
12
13Author:
14
15
16
17Environment:
18
19 Both kernel and user mode
20
21Revision History:
22
23--*/
24
25#ifndef _IOPRIV_H_
26#define _IOPRIV_H_
27
28#if ((FX_CORE_MODE)==(FX_CORE_USER_MODE))
29#define FX_IS_USER_MODE (TRUE)
30#define FX_IS_KERNEL_MODE (FALSE)
31#elif ((FX_CORE_MODE)==(FX_CORE_KERNEL_MODE))
32#define FX_IS_USER_MODE (FALSE)
33#define FX_IS_KERNEL_MODE (TRUE)
34#endif
35
36/*#if defined(MODE_AGNSOTIC_FXPKGIO_NOT_IN_SHARED_FOLDER)
37#include <fx.hpp>
38#else
39// common header file for all irphandler\* files
40#include "irphandlerspriv.hpp"
41#endif
42
43#if FX_IS_USER_MODE
44#define PWDF_REQUEST_PARAMETERS PVOID
45#define PFN_WDF_REQUEST_CANCEL PVOID
46#define PIO_CSQ_IRP_CONTEXT PVOID
47#endif*/
48
49extern "C" {
50#include "mx.h"
51}
52
53#include "fxmin.hpp"
54
55#include "wdfmemory.h"
56#include "wdfrequest.h"
57#include "wdfio.h"
58#include "wdfdevice.h"
59#include "wdfwmi.h"
60#include "wdfchildlist.h"
61#include "wdfpdo.h"
62#include "wdffdo.h"
63#include "fxirpqueue.hpp"
64#include "fxcallback.hpp"
65
66// <FxSystemWorkItem.hpp>
67__drv_functionClass(EVT_SYSTEMWORKITEM)
71typedef
72VOID
73EVT_SYSTEMWORKITEM(
75 );
76
77typedef EVT_SYSTEMWORKITEM *PFN_WDF_SYSTEMWORKITEM;
78
79// </FxSystemWorkItem.hpp>
80
81#include "fxsystemthread.hpp"
82
86
87#if (FX_CORE_MODE == FX_CORE_KERNEL_MODE)
88#include "fxirpkm.hpp"
89#else
90#include "fxirpum.hpp"
91#endif
92
93
94#include "fxpackage.hpp"
95#include "fxcollection.hpp"
98
99#include "ifxmemory.hpp"
100#include "fxcallback.hpp"
101#include "fxrequestcontext.hpp"
103#include "fxrequestbase.hpp"
104#include "fxmemoryobject.hpp"
106#include "fxrequestmemory.hpp"
107#include "fxrequest.hpp"
108#include "fxrequestbuffer.hpp"
109#include "fxsyncrequest.hpp"
110
112#include "fxpkgpnp.hpp"
113#include "fxpkgio.hpp"
114#include "fxioqueue.hpp"
115#include "fxioqueuecallbacks.hpp"
116
117
118//
119// At this time we are unable to include wdf17.h in the share code, thus for
120// now we simply cut and paste the needed structures.
121//
122typedef struct _WDF_IO_QUEUE_CONFIG_V1_7 {
123 ULONG Size;
124
126
128
130
132
134
136
138
140
142
144
146
148
150
151//
152// At this time we are unable to include wdf19.h in the shared code, thus for
153// now we simply cut and paste the needed structures.
154//
155//
156typedef struct _WDF_IO_QUEUE_CONFIG_V1_9 {
157 ULONG Size;
158
160
162
164
166
168
170
172
174
176
178
180
182
183 union {
184 struct {
186
188
190
192
193
194//
195// public headers
196//
197/*#include "wdfDevice.h"
198#include "wdfChildList.h"
199#include "wdfPdo.h"
200#include "wdffdo.h"
201#include "wdfQueryInterface.h"
202#include "wdfMemory.h"
203#include "wdfWmi.h"
204
205#if FX_IS_KERNEL_MODE
206#include "wdfrequest.h"
207#endif
208#include "wdfio.h"
209
210
211
212#include "FxCallback.hpp"
213
214
215#include "FxRequestBaseShared.hpp"
216#include "FxRequestShared.hpp"
217
218// FxDevice To Shared interface header
219#include "FxDeviceToMxInterface.hpp"
220#include "FxRequestToMxInterface.hpp"
221
222#if defined(MODE_AGNSOTIC_FXPKGIO_NOT_IN_SHARED_FOLDER)
223#include "FxRequestToMxInterfaceKM.hpp"
224#endif
225
226//
227// private headers
228//
229#include "FxTransactionedList.hpp"
230#include "FxSystemThread.hpp"
231
232#if FX_IS_KERNEL_MODE
233#include "FxFileObject.hpp"
234#endif
235
236#include "Fxirpqueue.hpp"
237
238#include "FxCallbackSpinLock.hpp"
239#include "FxCallbackMutexLock.hpp"
240
241//#include "FxDeviceInterface.hpp"
242//#include "FxQueryInterface.hpp"
243//#include "FxPnpCallbacks.hpp"
244#include "FxPackage.hpp"
245
246#include "FxChildList.hpp"
247#include "FxPkgPnp.hpp"
248#include "FxPkgPdo.hpp"
249
250#include "FxPkgIo.hpp"
251#include "FxIoQueue.hpp"
252
253
254#if !defined(MODE_AGNSOTIC_FXPKGIO_NOT_IN_SHARED_FOLDER)
255
256// <wdf17.h>
257//
258// This is the structure used to configure an IoQueue and
259// register callback events to it.
260//
261//
262typedef struct _WDF_IO_QUEUE_CONFIG_V1_7 {
263 ULONG Size;
264
265 WDF_IO_QUEUE_DISPATCH_TYPE DispatchType;
266
267 WDF_TRI_STATE PowerManaged;
268
269 BOOLEAN AllowZeroLengthRequests;
270
271 BOOLEAN DefaultQueue;
272
273 PFN_WDF_IO_QUEUE_IO_DEFAULT EvtIoDefault;
274
275 PFN_WDF_IO_QUEUE_IO_READ EvtIoRead;
276
277 PFN_WDF_IO_QUEUE_IO_WRITE EvtIoWrite;
278
279 PFN_WDF_IO_QUEUE_IO_DEVICE_CONTROL EvtIoDeviceControl;
280
281 PFN_WDF_IO_QUEUE_IO_INTERNAL_DEVICE_CONTROL EvtIoInternalDeviceControl;
282
283 PFN_WDF_IO_QUEUE_IO_STOP EvtIoStop;
284
285 PFN_WDF_IO_QUEUE_IO_RESUME EvtIoResume;
286
287 PFN_WDF_IO_QUEUE_IO_CANCELED_ON_QUEUE EvtIoCanceledOnQueue;
288
289} WDF_IO_QUEUE_CONFIG_V1_7, *PWDF_IO_QUEUE_CONFIG_V1_7;
290
291// </wdf17.h>
292
293//
294// <wdfbugcoded.h>
295//
296typedef struct _WDF_QUEUE_FATAL_ERROR_DATA {
297 WDFQUEUE Queue;
298
299 WDFREQUEST Request;
300
301 NTSTATUS Status;
302
303} WDF_QUEUE_FATAL_ERROR_DATA, *PWDF_QUEUE_FATAL_ERROR_DATA;
304
305// </wdfbugcoded.h>
306
307#endif //MODE_AGNSOTIC_FXPKGIO_NOT_IN_SHARED_FOLDER*/
308
309#endif //_IOPRIV_H_
unsigned char BOOLEAN
#define __in
Definition: dbghelp.h:35
#define __drv_maxFunctionIRQL(irql)
Definition: driverspecs.h:290
#define __drv_maxIRQL(irql)
Definition: driverspecs.h:291
#define __drv_functionClass(x)
Definition: driverspecs.h:274
#define __drv_sameIRQL
Definition: driverspecs.h:325
#define PASSIVE_LEVEL
Definition: env_spec_w32.h:693
#define DISPATCH_LEVEL
Definition: env_spec_w32.h:696
struct _WDF_IO_QUEUE_CONFIG_V1_7 * PWDF_IO_QUEUE_CONFIG_V1_7
struct _WDF_IO_QUEUE_CONFIG_V1_9 * PWDF_IO_QUEUE_CONFIG_V1_9
struct _WDF_IO_QUEUE_CONFIG_V1_9 WDF_IO_QUEUE_CONFIG_V1_9
EVT_SYSTEMWORKITEM * PFN_WDF_SYSTEMWORKITEM
struct _WDF_IO_QUEUE_CONFIG_V1_7 WDF_IO_QUEUE_CONFIG_V1_7
PFN_WDF_IO_QUEUE_IO_DEVICE_CONTROL EvtIoDeviceControl
Definition: wdf17.h:1136
PFN_WDF_IO_QUEUE_IO_WRITE EvtIoWrite
Definition: wdf17.h:1134
WDF_TRI_STATE PowerManaged
Definition: wdf17.h:1124
BOOLEAN AllowZeroLengthRequests
Definition: wdf17.h:1126
WDF_IO_QUEUE_DISPATCH_TYPE DispatchType
Definition: wdf17.h:1122
PFN_WDF_IO_QUEUE_IO_DEFAULT EvtIoDefault
Definition: wdf17.h:1130
PFN_WDF_IO_QUEUE_IO_INTERNAL_DEVICE_CONTROL EvtIoInternalDeviceControl
Definition: wdf17.h:1138
PFN_WDF_IO_QUEUE_IO_CANCELED_ON_QUEUE EvtIoCanceledOnQueue
Definition: wdf17.h:1144
PFN_WDF_IO_QUEUE_IO_STOP EvtIoStop
Definition: wdf17.h:1140
PFN_WDF_IO_QUEUE_IO_READ EvtIoRead
Definition: wdf17.h:1132
PFN_WDF_IO_QUEUE_IO_RESUME EvtIoResume
Definition: wdf17.h:1142
struct _WDF_IO_QUEUE_CONFIG_V1_9::@4710::@4711 Parallel
PFN_WDF_IO_QUEUE_IO_RESUME EvtIoResume
Definition: wdf19.h:1280
PFN_WDF_IO_QUEUE_IO_STOP EvtIoStop
Definition: wdf19.h:1278
PFN_WDF_IO_QUEUE_IO_DEFAULT EvtIoDefault
Definition: wdf19.h:1268
PFN_WDF_IO_QUEUE_IO_WRITE EvtIoWrite
Definition: wdf19.h:1272
ULONG NumberOfPresentedRequests
Definition: wdf19.h:1286
BOOLEAN AllowZeroLengthRequests
Definition: wdf19.h:1264
WDF_IO_QUEUE_DISPATCH_TYPE DispatchType
Definition: wdf19.h:1260
PFN_WDF_IO_QUEUE_IO_CANCELED_ON_QUEUE EvtIoCanceledOnQueue
Definition: wdf19.h:1282
PFN_WDF_IO_QUEUE_IO_INTERNAL_DEVICE_CONTROL EvtIoInternalDeviceControl
Definition: wdf19.h:1276
union _WDF_IO_QUEUE_CONFIG_V1_9::@4710 Settings
PFN_WDF_IO_QUEUE_IO_READ EvtIoRead
Definition: wdf19.h:1270
PFN_WDF_IO_QUEUE_IO_DEVICE_CONTROL EvtIoDeviceControl
Definition: wdf19.h:1274
WDF_TRI_STATE PowerManaged
Definition: wdf19.h:1262
uint32_t ULONG
Definition: typedefs.h:59
EVT_WDF_IO_QUEUE_IO_INTERNAL_DEVICE_CONTROL * PFN_WDF_IO_QUEUE_IO_INTERNAL_DEVICE_CONTROL
Definition: wdfio.h:348
EVT_WDF_IO_QUEUE_IO_CANCELED_ON_QUEUE * PFN_WDF_IO_QUEUE_IO_CANCELED_ON_QUEUE
Definition: wdfio.h:364
EVT_WDF_IO_QUEUE_IO_DEVICE_CONTROL * PFN_WDF_IO_QUEUE_IO_DEVICE_CONTROL
Definition: wdfio.h:327
EVT_WDF_IO_QUEUE_IO_READ * PFN_WDF_IO_QUEUE_IO_READ
Definition: wdfio.h:289
EVT_WDF_IO_QUEUE_IO_WRITE * PFN_WDF_IO_QUEUE_IO_WRITE
Definition: wdfio.h:306
EVT_WDF_IO_QUEUE_IO_RESUME * PFN_WDF_IO_QUEUE_IO_RESUME
Definition: wdfio.h:272
EVT_WDF_IO_QUEUE_IO_STOP * PFN_WDF_IO_QUEUE_IO_STOP
Definition: wdfio.h:257
WDF_EXTERN_C_START enum _WDF_IO_QUEUE_DISPATCH_TYPE WDF_IO_QUEUE_DISPATCH_TYPE
EVT_WDF_IO_QUEUE_IO_DEFAULT * PFN_WDF_IO_QUEUE_IO_DEFAULT
Definition: wdfio.h:239
enum _WDF_TRI_STATE WDF_TRI_STATE
_Inout_opt_ PVOID Parameter
Definition: rtltypes.h:323