ReactOS 0.4.15-dev-8145-ga541a46
wdfio.h
Go to the documentation of this file.
1/*++
2
3Copyright (c) Microsoft Corporation. All rights reserved.
4
5_WdfVersionBuild_
6
7Module Name:
8
9 wdfio.h
10
11Abstract:
12
13 This module contains contains the Windows Driver Framework I/O
14 interfaces.
15
16Environment:
17
18 kernel mode only
19
20Revision History:
21
22
23--*/
24
25//
26// NOTE: This header is generated by stubwork. Please make any
27// modifications to the corresponding template files
28// (.x or .y) and use stubwork to regenerate the header
29//
30
31#ifndef _WDFIO_H_
32#define _WDFIO_H_
33
34#ifndef WDF_EXTERN_C
35 #ifdef __cplusplus
36 #define WDF_EXTERN_C extern "C"
37 #define WDF_EXTERN_C_START extern "C" {
38 #define WDF_EXTERN_C_END }
39 #else
40 #define WDF_EXTERN_C
41 #define WDF_EXTERN_C_START
42 #define WDF_EXTERN_C_END
43 #endif
44#endif
45
47
48
49
50#if (NTDDI_VERSION >= NTDDI_WIN2K)
51
52//
53// Types
54//
55
56//
57// This defines the dispatch type of the queue. This controls how
58// the queue raises I/O events to the driver through the registered
59// callbacks.
60//
61// Sequential allows the driver to have the queue automatically dispatch
62// one request at a time, and will hold requests until a current request
63// is completed.
64//
65// Parallel has the queue dispatch requests to the driver as they arrive
66// at the queue, and the queue is in a processing state. The driver can
67// look at the requests in real time, and decide to service them, forward them
68// to another queue, pend them, or return a status to have the queue held
69// due to a hardware or other resource limit.
70//
71// Manual allows the driver to create multiple queues for requests, and control
72// when it wants to retrieve requests from the queue by calling the queues
73// WdfIoQueueRetrieveNextRequest() API.
74//
75
83
84//
85// This defines the status of the queue.
86//
87// WdfIoQueueAcceptRequests - If TRUE, Queue will accept requests from WDM
88// dispatch through WdfDeviceConfigureRequestDispatching,
89// or from WdfRequestForwardToIoQueue.
90//
91// If FALSE, Queue will complete requests with
92// STATUS_CANCELLED from WdfDeviceConfigureRequestDispatching,
93// and fail WdfRequestForwardToIoQueue with
94// STATUS_WDF_BUSY.
95//
96//
97// WdfIoQueueDispatchRequests - If TRUE, and the Queue is configured for
98// automatic dispatch as either
99// WdfIoQueueDispatchSequential,
100// or WdfIoQueueDispatchParallel, the Queue will
101// present the requests to the driver according
102// to the drivers configuration.
103//
104// If FALSE, requests are not automatically
105// presented to the device driver.
106//
107// This has no effect on the drivers ability to
108// retrieve requests with WdfIoQueueRetrieveNextRequest.
109//
110// WdfIoQueueNoRequests - If TRUE, the Queue has no requests to present
111// or return to the device driver.
112//
113// WdfIoQueueDriverNoRequests - If TRUE, the device driver is not operating
114// on any requests retrieved from or presented
115// by this Queue.
116//
117// WdfIoQueuePnpHeld - The Framework PnP stage has requested that
118// the device driver stop receiving new requests.
119//
120// Automatic request dispatch stops, and
121// WdfIoQueueRetrieveNextRequest returns STATUS_WDF_BUSY.
122//
123
131
132
133
134
135//
136// These macros represent some common Queue states
137//
138
139//
140// A Queue is idle if it has no requests, and the driver
141// is not operating on any.
142//
143
148 )
149{
150 return ((State & WdfIoQueueNoRequests) &&
152}
153
154//
155// A Queue is ready if it can accept and dispatch requests and
156// queue is not held by PNP
157//
162 )
163{
164 return ((State & WdfIoQueueDispatchRequests) &&
166 ((State & WdfIoQueuePnpHeld)==0)) ? TRUE: FALSE;
167}
168
169//
170// A Queue is stopped if it can accept new requests, but
171// is not automatically delivering them to the device driver,
172// and the queue is idle.
173//
178 )
179{
180 return (((State & WdfIoQueueDispatchRequests) == 0) &&
183
184}
185
186//
187// A Queue is drained if it can not accept new requests but
188// can dispatch existing requests, and there are no requests
189// either in the Queue or the device driver.
190//
191
196 )
197{
198 return ( ((State & WdfIoQueueAcceptRequests)==0) &&
202
203}
204
205//
206// A Queue is purged if it can not accept new requests
207// and there are no requests either in the Queue or
208// the device driver.
209//
214 )
215{
216 return ( ((State & WdfIoQueueAcceptRequests)==0) &&
219
220}
221
222//
223// Event callback definitions
224//
225
226typedef
227_Function_class_(EVT_WDF_IO_QUEUE_IO_DEFAULT)
230VOID
232EVT_WDF_IO_QUEUE_IO_DEFAULT(
233 _In_
234 WDFQUEUE Queue,
235 _In_
236 WDFREQUEST Request
237 );
238
239typedef EVT_WDF_IO_QUEUE_IO_DEFAULT *PFN_WDF_IO_QUEUE_IO_DEFAULT;
240
241
242typedef
243_Function_class_(EVT_WDF_IO_QUEUE_IO_STOP)
246VOID
248EVT_WDF_IO_QUEUE_IO_STOP(
249 _In_
250 WDFQUEUE Queue,
251 _In_
252 WDFREQUEST Request,
253 _In_
255 );
256
257typedef EVT_WDF_IO_QUEUE_IO_STOP *PFN_WDF_IO_QUEUE_IO_STOP;
258
259typedef
260_Function_class_(EVT_WDF_IO_QUEUE_IO_RESUME)
263VOID
265EVT_WDF_IO_QUEUE_IO_RESUME(
266 _In_
267 WDFQUEUE Queue,
268 _In_
269 WDFREQUEST Request
270 );
271
272typedef EVT_WDF_IO_QUEUE_IO_RESUME *PFN_WDF_IO_QUEUE_IO_RESUME;
273
274typedef
275_Function_class_(EVT_WDF_IO_QUEUE_IO_READ)
278VOID
280EVT_WDF_IO_QUEUE_IO_READ(
281 _In_
282 WDFQUEUE Queue,
283 _In_
284 WDFREQUEST Request,
285 _In_
286 size_t Length
287 );
288
289typedef EVT_WDF_IO_QUEUE_IO_READ *PFN_WDF_IO_QUEUE_IO_READ;
290
291typedef
292_Function_class_(EVT_WDF_IO_QUEUE_IO_WRITE)
295VOID
297EVT_WDF_IO_QUEUE_IO_WRITE(
298 _In_
299 WDFQUEUE Queue,
300 _In_
301 WDFREQUEST Request,
302 _In_
303 size_t Length
304 );
305
306typedef EVT_WDF_IO_QUEUE_IO_WRITE *PFN_WDF_IO_QUEUE_IO_WRITE;
307
308typedef
309_Function_class_(EVT_WDF_IO_QUEUE_IO_DEVICE_CONTROL)
312VOID
314EVT_WDF_IO_QUEUE_IO_DEVICE_CONTROL(
315 _In_
316 WDFQUEUE Queue,
317 _In_
318 WDFREQUEST Request,
319 _In_
321 _In_
323 _In_
325 );
326
327typedef EVT_WDF_IO_QUEUE_IO_DEVICE_CONTROL *PFN_WDF_IO_QUEUE_IO_DEVICE_CONTROL;
328
329typedef
330_Function_class_(EVT_WDF_IO_QUEUE_IO_INTERNAL_DEVICE_CONTROL)
333VOID
335EVT_WDF_IO_QUEUE_IO_INTERNAL_DEVICE_CONTROL(
336 _In_
337 WDFQUEUE Queue,
338 _In_
339 WDFREQUEST Request,
340 _In_
341 size_t OutputBufferLength,
342 _In_
343 size_t InputBufferLength,
344 _In_
346 );
347
348typedef EVT_WDF_IO_QUEUE_IO_INTERNAL_DEVICE_CONTROL *PFN_WDF_IO_QUEUE_IO_INTERNAL_DEVICE_CONTROL;
349
350
351typedef
352_Function_class_(EVT_WDF_IO_QUEUE_IO_CANCELED_ON_QUEUE)
355VOID
357EVT_WDF_IO_QUEUE_IO_CANCELED_ON_QUEUE(
358 _In_
359 WDFQUEUE Queue,
360 _In_
361 WDFREQUEST Request
362 );
363
364typedef EVT_WDF_IO_QUEUE_IO_CANCELED_ON_QUEUE *PFN_WDF_IO_QUEUE_IO_CANCELED_ON_QUEUE;
365
366
367typedef
368_Function_class_(EVT_WDF_IO_QUEUE_STATE)
371VOID
373EVT_WDF_IO_QUEUE_STATE(
374 _In_
375 WDFQUEUE Queue,
376 _In_
378 );
379
380typedef EVT_WDF_IO_QUEUE_STATE *PFN_WDF_IO_QUEUE_STATE;
381
382//
383// This is the structure used to configure an IoQueue and
384// register callback events to it.
385//
386
387typedef struct _WDF_IO_QUEUE_CONFIG {
388
390
392
394
396
398
400
402
404
406
408
410
412
414
415 union {
416 struct {
420
421 WDFDRIVER Driver;
423
425VOID
429 )
430{
432
433 Config->Size = sizeof(WDF_IO_QUEUE_CONFIG);
434 Config->PowerManaged = WdfUseDefault;
435 Config->DispatchType = DispatchType;
436 if (Config->DispatchType == WdfIoQueueDispatchParallel) {
437 Config->Settings.Parallel.NumberOfPresentedRequests = (ULONG)-1;
438 }
439}
440
442VOID
446 )
447{
449
450 Config->Size = sizeof(WDF_IO_QUEUE_CONFIG);
451 Config->PowerManaged = WdfUseDefault;
452 Config->DefaultQueue = TRUE;
453 Config->DispatchType = DispatchType;
454 if (Config->DispatchType == WdfIoQueueDispatchParallel) {
455 Config->Settings.Parallel.NumberOfPresentedRequests = (ULONG)-1;
456 }
457}
458
464
471
472typedef
473_Function_class_(EVT_WDF_IO_ALLOCATE_RESOURCES_FOR_RESERVED_REQUEST)
478EVT_WDF_IO_ALLOCATE_RESOURCES_FOR_RESERVED_REQUEST(
479 _In_
480 WDFQUEUE Queue,
481 _In_
482 WDFREQUEST Request
483 );
484
485typedef EVT_WDF_IO_ALLOCATE_RESOURCES_FOR_RESERVED_REQUEST *PFN_WDF_IO_ALLOCATE_RESOURCES_FOR_RESERVED_REQUEST;
486
487typedef
488_Function_class_(EVT_WDF_IO_ALLOCATE_REQUEST_RESOURCES)
493EVT_WDF_IO_ALLOCATE_REQUEST_RESOURCES(
494 _In_
495 WDFQUEUE Queue,
496 _In_
497 WDFREQUEST Request
498 );
499
500typedef EVT_WDF_IO_ALLOCATE_REQUEST_RESOURCES *PFN_WDF_IO_ALLOCATE_REQUEST_RESOURCES;
501
502typedef
503_Function_class_(EVT_WDF_IO_WDM_IRP_FOR_FORWARD_PROGRESS)
508EVT_WDF_IO_WDM_IRP_FOR_FORWARD_PROGRESS(
509 _In_
510 WDFQUEUE Queue,
511 _In_
513 );
514
515typedef EVT_WDF_IO_WDM_IRP_FOR_FORWARD_PROGRESS *PFN_WDF_IO_WDM_IRP_FOR_FORWARD_PROGRESS;
516
518 union {
519
520 struct {
523
526
529
531
532 //
533 // Specify the type of the policy here.
534 //
536
537 //
538 // Structure which contains the policy specific fields
539 //
541
542 //
543 // Callback for reserved request given at initialization time
544 //
546
547 //
548 // Callback for reserved request given at run time
549 //
551
553
555VOID
558 _In_ ULONG TotalForwardProgressRequests
559 )
560{
562
564 Policy->TotalForwardProgressRequests = TotalForwardProgressRequests;
566}
567
568
570VOID
573 _In_ ULONG TotalForwardProgressRequests,
574 _In_ PFN_WDF_IO_WDM_IRP_FOR_FORWARD_PROGRESS EvtIoWdmIrpForForwardProgress
575 )
576{
578
580 Policy->TotalForwardProgressRequests = TotalForwardProgressRequests;
581 Policy->ForwardProgressReservedPolicy = WdfIoForwardProgressReservedPolicyUseExamine;
582 Policy->ForwardProgressReservePolicySettings.Policy.ExaminePolicy.EvtIoWdmIrpForForwardProgress =
583 EvtIoWdmIrpForForwardProgress;
584}
585
587VOID
590 _In_ ULONG TotalForwardProgressRequests
591 )
592{
594
596 Policy->TotalForwardProgressRequests = TotalForwardProgressRequests;
597 Policy->ForwardProgressReservedPolicy = WdfIoForwardProgressReservedPolicyPagingIO;
598}
599
600
601//
602// WDF Function: WdfIoQueueCreate
603//
604typedef
607WDFAPI
609(STDCALL *PFN_WDFIOQUEUECREATE)(
610 _In_
612 _In_
613 WDFDEVICE Device,
614 _In_
619 WDFQUEUE* Queue
620 );
621
626WdfIoQueueCreate(
627 _In_
628 WDFDEVICE Device,
629 _In_
634 WDFQUEUE* Queue
635 )
636{
638}
639
640//
641// WDF Function: WdfIoQueueGetState
642//
643typedef
645WDFAPI
647(STDCALL *PFN_WDFIOQUEUEGETSTATE)(
648 _In_
650 _In_
651 WDFQUEUE Queue,
656 );
657
661WdfIoQueueGetState(
662 _In_
663 WDFQUEUE Queue,
668 )
669{
671}
672
673//
674// WDF Function: WdfIoQueueStart
675//
676typedef
678WDFAPI
679VOID
680(STDCALL *PFN_WDFIOQUEUESTART)(
681 _In_
683 _In_
684 WDFQUEUE Queue
685 );
686
689VOID
690WdfIoQueueStart(
691 _In_
692 WDFQUEUE Queue
693 )
694{
696}
697
698//
699// WDF Function: WdfIoQueueStop
700//
701typedef
703WDFAPI
704VOID
705(STDCALL *PFN_WDFIOQUEUESTOP)(
706 _In_
708 _In_
709 WDFQUEUE Queue,
711 _When_(Context == 0, _In_opt_)
716 );
717
720VOID
721WdfIoQueueStop(
722 _In_
723 WDFQUEUE Queue,
724 _When_(Context != 0, _In_)
725 _When_(Context == 0, _In_opt_)
730 )
731{
733}
734
735//
736// WDF Function: WdfIoQueueStopSynchronously
737//
738typedef
740WDFAPI
741VOID
742(STDCALL *PFN_WDFIOQUEUESTOPSYNCHRONOUSLY)(
743 _In_
745 _In_
746 WDFQUEUE Queue
747 );
748
751VOID
752WdfIoQueueStopSynchronously(
753 _In_
754 WDFQUEUE Queue
755 )
756{
757 ((PFN_WDFIOQUEUESTOPSYNCHRONOUSLY) WdfFunctions[WdfIoQueueStopSynchronouslyTableIndex])(WdfDriverGlobals, Queue);
758}
759
760//
761// WDF Function: WdfIoQueueGetDevice
762//
763typedef
765WDFAPI
766WDFDEVICE
767(STDCALL *PFN_WDFIOQUEUEGETDEVICE)(
768 _In_
770 _In_
771 WDFQUEUE Queue
772 );
773
776WDFDEVICE
777WdfIoQueueGetDevice(
778 _In_
779 WDFQUEUE Queue
780 )
781{
782 return ((PFN_WDFIOQUEUEGETDEVICE) WdfFunctions[WdfIoQueueGetDeviceTableIndex])(WdfDriverGlobals, Queue);
783}
784
785//
786// WDF Function: WdfIoQueueRetrieveNextRequest
787//
788typedef
791WDFAPI
793(STDCALL *PFN_WDFIOQUEUERETRIEVENEXTREQUEST)(
794 _In_
796 _In_
797 WDFQUEUE Queue,
798 _Out_
799 WDFREQUEST* OutRequest
800 );
801
806WdfIoQueueRetrieveNextRequest(
807 _In_
808 WDFQUEUE Queue,
809 _Out_
810 WDFREQUEST* OutRequest
811 )
812{
813 return ((PFN_WDFIOQUEUERETRIEVENEXTREQUEST) WdfFunctions[WdfIoQueueRetrieveNextRequestTableIndex])(WdfDriverGlobals, Queue, OutRequest);
814}
815
816//
817// WDF Function: WdfIoQueueRetrieveRequestByFileObject
818//
819typedef
822WDFAPI
824(STDCALL *PFN_WDFIOQUEUERETRIEVEREQUESTBYFILEOBJECT)(
825 _In_
827 _In_
828 WDFQUEUE Queue,
829 _In_
830 WDFFILEOBJECT FileObject,
831 _Out_
832 WDFREQUEST* OutRequest
833 );
834
839WdfIoQueueRetrieveRequestByFileObject(
840 _In_
841 WDFQUEUE Queue,
842 _In_
843 WDFFILEOBJECT FileObject,
844 _Out_
845 WDFREQUEST* OutRequest
846 )
847{
848 return ((PFN_WDFIOQUEUERETRIEVEREQUESTBYFILEOBJECT) WdfFunctions[WdfIoQueueRetrieveRequestByFileObjectTableIndex])(WdfDriverGlobals, Queue, FileObject, OutRequest);
849}
850
851//
852// WDF Function: WdfIoQueueFindRequest
853//
854typedef
857WDFAPI
859(STDCALL *PFN_WDFIOQUEUEFINDREQUEST)(
860 _In_
862 _In_
863 WDFQUEUE Queue,
865 WDFREQUEST FoundRequest,
867 WDFFILEOBJECT FileObject,
870 _Out_
871 WDFREQUEST* OutRequest
872 );
873
878WdfIoQueueFindRequest(
879 _In_
880 WDFQUEUE Queue,
882 WDFREQUEST FoundRequest,
884 WDFFILEOBJECT FileObject,
887 _Out_
888 WDFREQUEST* OutRequest
889 )
890{
892}
893
894//
895// WDF Function: WdfIoQueueRetrieveFoundRequest
896//
897typedef
900WDFAPI
902(STDCALL *PFN_WDFIOQUEUERETRIEVEFOUNDREQUEST)(
903 _In_
905 _In_
906 WDFQUEUE Queue,
907 _In_
908 WDFREQUEST FoundRequest,
909 _Out_
910 WDFREQUEST* OutRequest
911 );
912
917WdfIoQueueRetrieveFoundRequest(
918 _In_
919 WDFQUEUE Queue,
920 _In_
921 WDFREQUEST FoundRequest,
922 _Out_
923 WDFREQUEST* OutRequest
924 )
925{
927}
928
929//
930// WDF Function: WdfIoQueueDrainSynchronously
931//
932typedef
934WDFAPI
935VOID
936(STDCALL *PFN_WDFIOQUEUEDRAINSYNCHRONOUSLY)(
937 _In_
939 _In_
940 WDFQUEUE Queue
941 );
942
945VOID
946WdfIoQueueDrainSynchronously(
947 _In_
948 WDFQUEUE Queue
949 )
950{
951 ((PFN_WDFIOQUEUEDRAINSYNCHRONOUSLY) WdfFunctions[WdfIoQueueDrainSynchronouslyTableIndex])(WdfDriverGlobals, Queue);
952}
953
954//
955// WDF Function: WdfIoQueueDrain
956//
957typedef
959WDFAPI
960VOID
961(STDCALL *PFN_WDFIOQUEUEDRAIN)(
962 _In_
964 _In_
965 WDFQUEUE Queue,
966 _When_(Context != 0, _In_)
967 _When_(Context == 0, _In_opt_)
972 );
973
976VOID
977WdfIoQueueDrain(
978 _In_
979 WDFQUEUE Queue,
980 _When_(Context != 0, _In_)
981 _When_(Context == 0, _In_opt_)
986 )
987{
989}
990
991//
992// WDF Function: WdfIoQueuePurgeSynchronously
993//
994typedef
996WDFAPI
997VOID
998(STDCALL *PFN_WDFIOQUEUEPURGESYNCHRONOUSLY)(
999 _In_
1001 _In_
1002 WDFQUEUE Queue
1003 );
1004
1007VOID
1008WdfIoQueuePurgeSynchronously(
1009 _In_
1010 WDFQUEUE Queue
1011 )
1012{
1013 ((PFN_WDFIOQUEUEPURGESYNCHRONOUSLY) WdfFunctions[WdfIoQueuePurgeSynchronouslyTableIndex])(WdfDriverGlobals, Queue);
1014}
1015
1016//
1017// WDF Function: WdfIoQueuePurge
1018//
1019typedef
1021WDFAPI
1022VOID
1023(STDCALL *PFN_WDFIOQUEUEPURGE)(
1024 _In_
1026 _In_
1027 WDFQUEUE Queue,
1028 _When_(Context != 0, _In_)
1029 _When_(Context == 0, _In_opt_)
1034 );
1035
1038VOID
1039WdfIoQueuePurge(
1040 _In_
1041 WDFQUEUE Queue,
1042 _When_(Context != 0, _In_)
1043 _When_(Context == 0, _In_opt_)
1048 )
1049{
1051}
1052
1053//
1054// WDF Function: WdfIoQueueReadyNotify
1055//
1056typedef
1059WDFAPI
1061(STDCALL *PFN_WDFIOQUEUEREADYNOTIFY)(
1062 _In_
1064 _In_
1065 WDFQUEUE Queue,
1066 _In_opt_
1068 _In_opt_
1070 );
1071
1076WdfIoQueueReadyNotify(
1077 _In_
1078 WDFQUEUE Queue,
1079 _In_opt_
1081 _In_opt_
1083 )
1084{
1085 return ((PFN_WDFIOQUEUEREADYNOTIFY) WdfFunctions[WdfIoQueueReadyNotifyTableIndex])(WdfDriverGlobals, Queue, QueueReady, Context);
1086}
1087
1088//
1089// WDF Function: WdfIoQueueAssignForwardProgressPolicy
1090//
1091typedef
1094WDFAPI
1096(STDCALL *PFN_WDFIOQUEUEASSIGNFORWARDPROGRESSPOLICY)(
1097 _In_
1099 _In_
1100 WDFQUEUE Queue,
1101 _In_
1103 );
1104
1109WdfIoQueueAssignForwardProgressPolicy(
1110 _In_
1111 WDFQUEUE Queue,
1112 _In_
1114 )
1115{
1116 return ((PFN_WDFIOQUEUEASSIGNFORWARDPROGRESSPOLICY) WdfFunctions[WdfIoQueueAssignForwardProgressPolicyTableIndex])(WdfDriverGlobals, Queue, ForwardProgressPolicy);
1117}
1118
1119//
1120// WDF Function: WdfIoQueueStopAndPurge
1121//
1122typedef
1124WDFAPI
1125VOID
1126(STDCALL *PFN_WDFIOQUEUESTOPANDPURGE)(
1127 _In_
1129 _In_
1130 WDFQUEUE Queue,
1131 _When_(Context != 0, _In_)
1132 _When_(Context == 0, _In_opt_)
1137 );
1138
1141VOID
1142WdfIoQueueStopAndPurge(
1143 _In_
1144 WDFQUEUE Queue,
1145 _When_(Context != 0, _In_)
1146 _When_(Context == 0, _In_opt_)
1151 )
1152{
1154}
1155
1156//
1157// WDF Function: WdfIoQueueStopAndPurgeSynchronously
1158//
1159typedef
1161WDFAPI
1162VOID
1163(STDCALL *PFN_WDFIOQUEUESTOPANDPURGESYNCHRONOUSLY)(
1164 _In_
1166 _In_
1167 WDFQUEUE Queue
1168 );
1169
1172VOID
1173WdfIoQueueStopAndPurgeSynchronously(
1174 _In_
1175 WDFQUEUE Queue
1176 )
1177{
1178 ((PFN_WDFIOQUEUESTOPANDPURGESYNCHRONOUSLY) WdfFunctions[WdfIoQueueStopAndPurgeSynchronouslyTableIndex])(WdfDriverGlobals, Queue);
1179}
1180
1181
1182
1183#endif // (NTDDI_VERSION >= NTDDI_WIN2K)
1184
1185
1187
1188#endif // _WDFIO_H_
1189
unsigned char BOOLEAN
#define VOID
Definition: acefi.h:82
LONG NTSTATUS
Definition: precomp.h:26
_In_ PIRP Irp
Definition: csq.h:116
#define TRUE
Definition: types.h:120
#define FALSE
Definition: types.h:117
#define NTSTATUS
Definition: precomp.h:21
#define _IRQL_requires_same_
Definition: driverspecs.h:232
#define PASSIVE_LEVEL
Definition: env_spec_w32.h:693
#define DISPATCH_LEVEL
Definition: env_spec_w32.h:696
DriverGlobals
#define _Function_class_(x)
Definition: ms_sal.h:2946
#define _Out_opt_
Definition: ms_sal.h:346
#define _Inout_opt_
Definition: ms_sal.h:379
#define _Must_inspect_result_
Definition: ms_sal.h:558
#define _Out_
Definition: ms_sal.h:345
#define _In_
Definition: ms_sal.h:308
#define _In_opt_
Definition: ms_sal.h:309
_In_ ULONG _In_ ULONG _In_ ULONG Length
Definition: ntddpcm.h:102
PFN_WDF_IO_WDM_IRP_FOR_FORWARD_PROGRESS EvtIoWdmIrpForForwardProgress
Definition: wdfio.h:521
struct _WDF_IO_FORWARD_PROGRESS_RESERVED_POLICY_SETTINGS::@3881::@3882 ExaminePolicy
union _WDF_IO_FORWARD_PROGRESS_RESERVED_POLICY_SETTINGS::@3881 Policy
ULONG NumberOfPresentedRequests
Definition: wdfio.h:417
PFN_WDF_IO_QUEUE_IO_DEFAULT EvtIoDefault
Definition: wdfio.h:399
PFN_WDF_IO_QUEUE_IO_DEVICE_CONTROL EvtIoDeviceControl
Definition: wdfio.h:405
WDF_IO_QUEUE_DISPATCH_TYPE DispatchType
Definition: wdfio.h:391
BOOLEAN DefaultQueue
Definition: wdfio.h:397
PFN_WDF_IO_QUEUE_IO_STOP EvtIoStop
Definition: wdfio.h:409
union _WDF_IO_QUEUE_CONFIG::@3879 Settings
BOOLEAN AllowZeroLengthRequests
Definition: wdfio.h:395
PFN_WDF_IO_QUEUE_IO_INTERNAL_DEVICE_CONTROL EvtIoInternalDeviceControl
Definition: wdfio.h:407
WDF_TRI_STATE PowerManaged
Definition: wdfio.h:393
PFN_WDF_IO_QUEUE_IO_CANCELED_ON_QUEUE EvtIoCanceledOnQueue
Definition: wdfio.h:413
PFN_WDF_IO_QUEUE_IO_READ EvtIoRead
Definition: wdfio.h:401
PFN_WDF_IO_QUEUE_IO_WRITE EvtIoWrite
Definition: wdfio.h:403
PFN_WDF_IO_QUEUE_IO_RESUME EvtIoResume
Definition: wdfio.h:411
WDFDRIVER Driver
Definition: wdfio.h:421
struct _WDF_IO_QUEUE_CONFIG::@3879::@3880 Parallel
WDF_IO_FORWARD_PROGRESS_RESERVED_POLICY ForwardProgressReservedPolicy
Definition: wdfio.h:535
PFN_WDF_IO_ALLOCATE_RESOURCES_FOR_RESERVED_REQUEST EvtIoAllocateResourcesForReservedRequest
Definition: wdfio.h:545
PFN_WDF_IO_ALLOCATE_REQUEST_RESOURCES EvtIoAllocateRequestResources
Definition: wdfio.h:550
WDF_IO_FORWARD_PROGRESS_RESERVED_POLICY_SETTINGS ForwardProgressReservePolicySettings
Definition: wdfio.h:540
uint32_t * PULONG
Definition: typedefs.h:59
#define RtlZeroMemory(Destination, Length)
Definition: typedefs.h:262
uint32_t ULONG
Definition: typedefs.h:59
#define STDCALL
Definition: wdf.h:45
#define WdfFunctions
Definition: wdf.h:66
_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_ WDFREQUEST _In_ WDFFILEOBJECT FileObject
Definition: wdfdevice.h:550
_Must_inspect_result_ _In_ WDFDEVICE _In_ PIRP _In_ WDFQUEUE Queue
Definition: wdfdevice.h:2225
_In_ WDFREQUEST Request
Definition: wdfdevice.h:547
PWDF_DRIVER_GLOBALS WdfDriverGlobals
@ WdfIoQueueDrainSynchronouslyTableIndex
Definition: wdffuncenum.h:187
@ WdfIoQueueStopTableIndex
Definition: wdffuncenum.h:180
@ WdfIoQueueGetStateTableIndex
Definition: wdffuncenum.h:178
@ WdfIoQueueFindRequestTableIndex
Definition: wdffuncenum.h:185
@ WdfIoQueueDrainTableIndex
Definition: wdffuncenum.h:188
@ WdfIoQueuePurgeTableIndex
Definition: wdffuncenum.h:190
@ WdfIoQueueStopAndPurgeSynchronouslyTableIndex
Definition: wdffuncenum.h:444
@ WdfIoQueuePurgeSynchronouslyTableIndex
Definition: wdffuncenum.h:189
@ WdfIoQueueRetrieveFoundRequestTableIndex
Definition: wdffuncenum.h:186
@ WdfIoQueueAssignForwardProgressPolicyTableIndex
Definition: wdffuncenum.h:415
@ WdfIoQueueRetrieveNextRequestTableIndex
Definition: wdffuncenum.h:183
@ WdfIoQueueCreateTableIndex
Definition: wdffuncenum.h:177
@ WdfIoQueueGetDeviceTableIndex
Definition: wdffuncenum.h:182
@ WdfIoQueueStopSynchronouslyTableIndex
Definition: wdffuncenum.h:181
@ WdfIoQueueStopAndPurgeTableIndex
Definition: wdffuncenum.h:443
@ WdfIoQueueRetrieveRequestByFileObjectTableIndex
Definition: wdffuncenum.h:184
@ WdfIoQueueReadyNotifyTableIndex
Definition: wdffuncenum.h:191
@ WdfIoQueueStartTableIndex
Definition: wdffuncenum.h:179
_In_ WDFINTERRUPT _In_ WDF_INTERRUPT_POLICY Policy
Definition: wdfinterrupt.h:653
_WDF_IO_FORWARD_PROGRESS_RESERVED_POLICY
Definition: wdfio.h:465
@ WdfIoForwardProgressReservedPolicyPagingIO
Definition: wdfio.h:469
@ WdfIoForwardProgressReservedPolicyAlwaysUseReservedRequest
Definition: wdfio.h:467
@ WdfIoForwardProgressReservedPolicyUseExamine
Definition: wdfio.h:468
@ WdfIoForwardProgressInvalidPolicy
Definition: wdfio.h:466
_In_ WDFREQUEST _In_ size_t _In_ size_t _In_ ULONG IoControlCode
Definition: wdfio.h:325
struct _WDF_IO_QUEUE_CONFIG * PWDF_IO_QUEUE_CONFIG
FORCEINLINE BOOLEAN WDF_IO_QUEUE_IDLE(_In_ WDF_IO_QUEUE_STATE State)
Definition: wdfio.h:146
_Must_inspect_result_ _In_ WDFQUEUE _In_opt_ WDFREQUEST FoundRequest
Definition: wdfio.h:865
EVT_WDF_IO_QUEUE_IO_INTERNAL_DEVICE_CONTROL * PFN_WDF_IO_QUEUE_IO_INTERNAL_DEVICE_CONTROL
Definition: wdfio.h:348
struct _WDF_IO_FORWARD_PROGRESS_RESERVED_POLICY_SETTINGS WDF_IO_FORWARD_PROGRESS_RESERVED_POLICY_SETTINGS
#define WDF_EXTERN_C_END
Definition: wdfio.h:42
EVT_WDF_IO_QUEUE_IO_CANCELED_ON_QUEUE * PFN_WDF_IO_QUEUE_IO_CANCELED_ON_QUEUE
Definition: wdfio.h:364
_Must_inspect_result_ _In_ WDFDEVICE Device
Definition: wdfio.h:613
_In_ WDFCONTEXT Context
Definition: wdfio.h:378
struct _WDF_IO_QUEUE_CONFIG WDF_IO_QUEUE_CONFIG
_WDF_IO_FORWARD_PROGRESS_ACTION
Definition: wdfio.h:459
@ WdfIoForwardProgressActionUseReservedRequest
Definition: wdfio.h:462
@ WdfIoForwardProgressActionInvalid
Definition: wdfio.h:460
@ WdfIoForwardProgressActionFailRequest
Definition: wdfio.h:461
_Must_inspect_result_ _In_ WDFQUEUE _Out_ WDFREQUEST * OutRequest
Definition: wdfio.h:800
_In_ WDFQUEUE _Out_opt_ PULONG QueueRequests
Definition: wdfio.h:653
EVT_WDF_IO_QUEUE_STATE * PFN_WDF_IO_QUEUE_STATE
Definition: wdfio.h:380
EVT_WDF_IO_QUEUE_IO_DEVICE_CONTROL * PFN_WDF_IO_QUEUE_IO_DEVICE_CONTROL
Definition: wdfio.h:327
_In_ WDFQUEUE _In_opt_ PFN_WDF_IO_QUEUE_STATE PurgeComplete
Definition: wdfio.h:1030
_Must_inspect_result_ _In_ WDFQUEUE _In_opt_ WDFREQUEST _In_opt_ WDFFILEOBJECT _Inout_opt_ PWDF_REQUEST_PARAMETERS Parameters
Definition: wdfio.h:869
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
_Must_inspect_result_ _In_ WDFQUEUE _In_ PWDF_IO_QUEUE_FORWARD_PROGRESS_POLICY ForwardProgressPolicy
Definition: wdfio.h:1103
EVT_WDF_IO_WDM_IRP_FOR_FORWARD_PROGRESS * PFN_WDF_IO_WDM_IRP_FOR_FORWARD_PROGRESS
Definition: wdfio.h:515
_In_ WDFQUEUE _In_opt_ PFN_WDF_IO_QUEUE_STATE StopComplete
Definition: wdfio.h:712
_In_ WDFQUEUE _Out_opt_ PULONG _Out_opt_ PULONG DriverRequests
Definition: wdfio.h:656
struct _WDF_IO_QUEUE_FORWARD_PROGRESS_POLICY * PWDF_IO_QUEUE_FORWARD_PROGRESS_POLICY
FORCEINLINE BOOLEAN WDF_IO_QUEUE_STOPPED(_In_ WDF_IO_QUEUE_STATE State)
Definition: wdfio.h:176
EVT_WDF_IO_ALLOCATE_RESOURCES_FOR_RESERVED_REQUEST * PFN_WDF_IO_ALLOCATE_RESOURCES_FOR_RESERVED_REQUEST
Definition: wdfio.h:485
EVT_WDF_IO_QUEUE_IO_RESUME * PFN_WDF_IO_QUEUE_IO_RESUME
Definition: wdfio.h:272
_Must_inspect_result_ _In_ WDFDEVICE _In_ PWDF_IO_QUEUE_CONFIG _In_opt_ PWDF_OBJECT_ATTRIBUTES QueueAttributes
Definition: wdfio.h:617
#define WDF_EXTERN_C_START
Definition: wdfio.h:41
FORCEINLINE VOID WDF_IO_QUEUE_FORWARD_PROGRESS_POLICY_EXAMINE_INIT(_Out_ PWDF_IO_QUEUE_FORWARD_PROGRESS_POLICY Policy, _In_ ULONG TotalForwardProgressRequests, _In_ PFN_WDF_IO_WDM_IRP_FOR_FORWARD_PROGRESS EvtIoWdmIrpForForwardProgress)
Definition: wdfio.h:571
FORCEINLINE VOID WDF_IO_QUEUE_FORWARD_PROGRESS_POLICY_DEFAULT_INIT(_Out_ PWDF_IO_QUEUE_FORWARD_PROGRESS_POLICY Policy, _In_ ULONG TotalForwardProgressRequests)
Definition: wdfio.h:556
FORCEINLINE BOOLEAN WDF_IO_QUEUE_PURGED(_In_ WDF_IO_QUEUE_STATE State)
Definition: wdfio.h:212
_Must_inspect_result_ _In_ WDFQUEUE _In_ WDFFILEOBJECT FileObject
Definition: wdfio.h:830
EVT_WDF_IO_QUEUE_IO_STOP * PFN_WDF_IO_QUEUE_IO_STOP
Definition: wdfio.h:257
_In_ WDFQUEUE _When_(Context !=0, _In_) _When_(Context
Definition: wdfio.h:710
_Must_inspect_result_ _In_ WDFDEVICE _In_ PWDF_IO_QUEUE_CONFIG _In_opt_ PWDF_OBJECT_ATTRIBUTES _Out_opt_ WDFQUEUE * Queue
Definition: wdfio.h:620
_WDF_IO_QUEUE_STATE
Definition: wdfio.h:124
@ WdfIoQueueDriverNoRequests
Definition: wdfio.h:128
@ WdfIoQueueAcceptRequests
Definition: wdfio.h:125
@ WdfIoQueueDispatchRequests
Definition: wdfio.h:126
@ WdfIoQueueNoRequests
Definition: wdfio.h:127
@ WdfIoQueuePnpHeld
Definition: wdfio.h:129
struct _WDF_IO_QUEUE_FORWARD_PROGRESS_POLICY WDF_IO_QUEUE_FORWARD_PROGRESS_POLICY
FORCEINLINE BOOLEAN WDF_IO_QUEUE_READY(_In_ WDF_IO_QUEUE_STATE State)
Definition: wdfio.h:160
_Must_inspect_result_ _IRQL_requires_max_(DISPATCH_LEVEL) WDFAPI NTSTATUS(STDCALL *PFN_WDFIOQUEUECREATE)(_In_ PWDF_DRIVER_GLOBALS DriverGlobals
Definition: wdfio.h:606
FORCEINLINE VOID WDF_IO_QUEUE_CONFIG_INIT(_Out_ PWDF_IO_QUEUE_CONFIG Config, _In_ WDF_IO_QUEUE_DISPATCH_TYPE DispatchType)
Definition: wdfio.h:426
_Must_inspect_result_ _In_ WDFDEVICE _In_ PWDF_IO_QUEUE_CONFIG Config
Definition: wdfio.h:615
_In_ WDFREQUEST _In_ ULONG ActionFlags
Definition: wdfio.h:255
FORCEINLINE VOID WDF_IO_QUEUE_CONFIG_INIT_DEFAULT_QUEUE(_Out_ PWDF_IO_QUEUE_CONFIG Config, _In_ WDF_IO_QUEUE_DISPATCH_TYPE DispatchType)
Definition: wdfio.h:443
_WDF_IO_QUEUE_DISPATCH_TYPE
Definition: wdfio.h:76
@ WdfIoQueueDispatchSequential
Definition: wdfio.h:78
@ WdfIoQueueDispatchMax
Definition: wdfio.h:81
@ WdfIoQueueDispatchInvalid
Definition: wdfio.h:77
@ WdfIoQueueDispatchParallel
Definition: wdfio.h:79
@ WdfIoQueueDispatchManual
Definition: wdfio.h:80
enum _WDF_IO_FORWARD_PROGRESS_ACTION WDF_IO_FORWARD_PROGRESS_ACTION
WDF_EXTERN_C_START enum _WDF_IO_QUEUE_DISPATCH_TYPE WDF_IO_QUEUE_DISPATCH_TYPE
_In_ WDFREQUEST _In_ size_t OutputBufferLength
Definition: wdfio.h:320
enum _WDF_IO_FORWARD_PROGRESS_RESERVED_POLICY WDF_IO_FORWARD_PROGRESS_RESERVED_POLICY
FORCEINLINE BOOLEAN WDF_IO_QUEUE_DRAINED(_In_ WDF_IO_QUEUE_STATE State)
Definition: wdfio.h:194
_Must_inspect_result_ _In_ WDFQUEUE _In_opt_ PFN_WDF_IO_QUEUE_STATE QueueReady
Definition: wdfio.h:1067
EVT_WDF_IO_QUEUE_IO_DEFAULT * PFN_WDF_IO_QUEUE_IO_DEFAULT
Definition: wdfio.h:239
enum _WDF_IO_QUEUE_STATE WDF_IO_QUEUE_STATE
FORCEINLINE VOID WDF_IO_QUEUE_FORWARD_PROGRESS_POLICY_PAGINGIO_INIT(_Out_ PWDF_IO_QUEUE_FORWARD_PROGRESS_POLICY Policy, _In_ ULONG TotalForwardProgressRequests)
Definition: wdfio.h:588
_In_ WDFQUEUE _In_opt_ PFN_WDF_IO_QUEUE_STATE StopAndPurgeComplete
Definition: wdfio.h:1133
_In_ WDFREQUEST _In_ size_t _In_ size_t InputBufferLength
Definition: wdfio.h:322
EVT_WDF_IO_ALLOCATE_REQUEST_RESOURCES * PFN_WDF_IO_ALLOCATE_REQUEST_RESOURCES
Definition: wdfio.h:500
_In_ WDFQUEUE _In_opt_ PFN_WDF_IO_QUEUE_STATE DrainComplete
Definition: wdfio.h:968
@ WdfUseDefault
Definition: wdftypes.h:89
#define WDFAPI
Definition: wdftypes.h:53
#define FORCEINLINE
Definition: wdftypes.h:67
enum _WDF_TRI_STATE WDF_TRI_STATE