ReactOS 0.4.15-dev-7674-gc0b4db1
io.h
Go to the documentation of this file.
1/*
2 * PROJECT: ReactOS Kernel
3 * LICENSE: GPL - See COPYING in the top level directory
4 * FILE: ntoskrnl/include/internal/io.h
5 * PURPOSE: Internal header for the I/O Manager
6 * PROGRAMMERS: Alex Ionescu (alex.ionescu@reactos.org)
7 */
8
9#include "ntdddisk.h"
10
11//
12// Define this if you want debugging support
13//
14#define _IO_DEBUG_ 0x00
15
16//
17// These define the Debug Masks Supported
18//
19#define IO_IRP_DEBUG 0x01
20#define IO_FILE_DEBUG 0x02
21#define IO_API_DEBUG 0x04
22#define IO_CTL_DEBUG 0x08
23
24//
25// Debug/Tracing support
26//
27#if _IO_DEBUG_
28#ifdef NEW_DEBUG_SYSTEM_IMPLEMENTED // enable when Debug Filters are implemented
29#define IOTRACE(x, ...) \
30 { \
31 DbgPrintEx("%s [%.16s] - ", \
32 __FUNCTION__, \
33 PsGetCurrentProcess()->ImageFileName); \
34 DbgPrintEx(__VA_ARGS__); \
35 }
36#else
37#define IOTRACE(x, ...) \
38 if (x & IopTraceLevel) \
39 { \
40 DbgPrint("%s [%.16s] - ", \
41 __FUNCTION__, \
42 PsGetCurrentProcess()->ImageFileName); \
43 DbgPrint(__VA_ARGS__); \
44 }
45#endif
46#else
47#define IOTRACE(x, fmt, ...) DPRINT(fmt, ##__VA_ARGS__)
48#endif
49
50//
51// Registry path to the enumeration root key
52//
53#define ENUM_ROOT L"\\Registry\\Machine\\System\\CurrentControlSet\\Enum"
54
55//
56// Returns the type of METHOD_ used in this IOCTL
57//
58#define IO_METHOD_FROM_CTL_CODE(c) (c & 0x00000003)
59
60//
61// Bugcheck codes for RAM disk booting
62//
63//
64// No LoaderXIPRom descriptor was found in the loader memory list
65//
66#define RD_NO_XIPROM_DESCRIPTOR 1
67//
68// Unable to open the RAM disk driver (ramdisk.sys or \Device\Ramdisk)
69//
70#define RD_NO_RAMDISK_DRIVER 2
71//
72// FSCTL_CREATE_RAM_DISK failed
73//
74#define RD_FSCTL_FAILED 3
75//
76// Unable to create GUID string from binary GUID
77//
78#define RD_GUID_CONVERT_FAILED 4
79//
80// Unable to create symbolic link pointing to the RAM disk device
81//
82#define RD_SYMLINK_CREATE_FAILED 5
83//
84// Unable to create system root path when creating the RAM disk
85//
86#define RD_SYSROOT_INIT_FAILED 6
87
88//
89// Max traversal of reparse points for a single open in IoParseDevice
90//
91#define IOP_MAX_REPARSE_TRAVERSAL 0x20
92
93//
94// Private flags for IoCreateFile / IoParseDevice
95//
96#define IOP_USE_TOP_LEVEL_DEVICE_HINT 0x01
97#define IOP_CREATE_FILE_OBJECT_EXTENSION 0x02
98
99
101{
104
106
107
108
109//
110// We can call the Ob Inlined API, it's the same thing
111//
112#define IopAllocateMdlFromLookaside \
113 ObpAllocateObjectCreateInfoBuffer
114#define IopFreeMdlFromLookaside \
115 ObpFreeCapturedAttributes
116
117//
118// Determines if the IRP is Synchronous
119//
120#define IsIrpSynchronous(Irp, FileObject) \
121 ((Irp->Flags & IRP_SYNCHRONOUS_API) || \
122 (!(FileObject) ? \
123 FALSE : \
124 FileObject->Flags & FO_SYNCHRONOUS_IO)) \
125
126//
127// Returns the internal Device Object Extension
128//
129#define IoGetDevObjExtension(DeviceObject) \
130 ((PEXTENDED_DEVOBJ_EXTENSION) \
131 (DeviceObject->DeviceObjectExtension)) \
132
133//
134// Returns the internal Driver Object Extension
135//
136#define IoGetDrvObjExtension(DriverObject) \
137 ((PEXTENDED_DRIVER_EXTENSION) \
138 (DriverObject->DriverExtension)) \
139
140/*
141 * VOID
142 * IopDeviceNodeSetFlag(
143 * PDEVICE_NODE DeviceNode,
144 * ULONG Flag);
145 */
146#define IopDeviceNodeSetFlag(DeviceNode, Flag) \
147 ((DeviceNode)->Flags |= (Flag))
148
149/*
150 * VOID
151 * IopDeviceNodeClearFlag(
152 * PDEVICE_NODE DeviceNode,
153 * ULONG Flag);
154 */
155#define IopDeviceNodeClearFlag(DeviceNode, Flag) \
156 ((DeviceNode)->Flags &= ~(Flag))
157
158/*
159 * BOOLEAN
160 * IopDeviceNodeHasFlag(
161 * PDEVICE_NODE DeviceNode,
162 * ULONG Flag);
163 */
164#define IopDeviceNodeHasFlag(DeviceNode, Flag) \
165 (((DeviceNode)->Flags & (Flag)) > 0)
166
167/*
168 * VOID
169 * IopDeviceNodeSetUserFlag(
170 * PDEVICE_NODE DeviceNode,
171 * ULONG UserFlag);
172 */
173#define IopDeviceNodeSetUserFlag(DeviceNode, UserFlag) \
174 ((DeviceNode)->UserFlags |= (UserFlag))
175
176/*
177 * VOID
178 * IopDeviceNodeClearUserFlag(
179 * PDEVICE_NODE DeviceNode,
180 * ULONG UserFlag);
181 */
182#define IopDeviceNodeClearUserFlag(DeviceNode, UserFlag)\
183 ((DeviceNode)->UserFlags &= ~(UserFlag))
184
185/*
186 * BOOLEAN
187 * IopDeviceNodeHasUserFlag(
188 * PDEVICE_NODE DeviceNode,
189 * ULONG UserFlag);
190 */
191#define IopDeviceNodeHasUserFlag(DeviceNode, UserFlag) \
192 (((DeviceNode)->UserFlags & (UserFlag)) > 0)
193
194 /*
195 * VOID
196 * IopDeviceNodeSetProblem(
197 * PDEVICE_NODE DeviceNode,
198 * ULONG Problem);
199 */
200#define IopDeviceNodeSetProblem(DeviceNode, Problem) \
201 ((DeviceNode)->Problem |= (Problem))
202
203/*
204 * VOID
205 * IopDeviceNodeClearProblem(
206 * PDEVICE_NODE DeviceNode,
207 * ULONG Problem);
208 */
209#define IopDeviceNodeClearProblem(DeviceNode, Problem) \
210 ((DeviceNode)->Problem &= ~(Problem))
211
212/*
213 * BOOLEAN
214 * IopDeviceNodeHasProblem(
215 * PDEVICE_NODE DeviceNode,
216 * ULONG Problem);
217 */
218#define IopDeviceNodeHasProblem(DeviceNode, Problem) \
219 (((DeviceNode)->Problem & (Problem)) > 0)
220
221/*
222 * VOID
223 * IopInitDeviceTreeTraverseContext(
224 * PDEVICETREE_TRAVERSE_CONTEXT DeviceTreeTraverseContext,
225 * PDEVICE_NODE DeviceNode,
226 * DEVICETREE_TRAVERSE_ROUTINE Action,
227 * PVOID Context);
228 */
229#define IopInitDeviceTreeTraverseContext( \
230 _DeviceTreeTraverseContext, _DeviceNode, _Action, \
231 _Context) { \
232 (_DeviceTreeTraverseContext)->FirstDeviceNode = \
233 (_DeviceNode); \
234 (_DeviceTreeTraverseContext)->Action = (_Action); \
235 (_DeviceTreeTraverseContext)->Context = (_Context); }
236
237/*
238 * BOOLEAN
239 * IopIsValidPhysicalDeviceObject(
240 * IN PDEVICE_OBJECT PhysicalDeviceObject);
241 */
242#define IopIsValidPhysicalDeviceObject(PhysicalDeviceObject) \
243 (((PEXTENDED_DEVOBJ_EXTENSION)PhysicalDeviceObject) && \
244 (((PEXTENDED_DEVOBJ_EXTENSION)PhysicalDeviceObject->DeviceObjectExtension)->DeviceNode) && \
245 (((PEXTENDED_DEVOBJ_EXTENSION)PhysicalDeviceObject->DeviceObjectExtension)->DeviceNode->Flags & DNF_ENUMERATED))
246
247//
248// Device List Operations
249//
251{
253 IopAdd
255
256//
257// Transfer statistics
258//
260{
265
266//
267// Packet Types when piggybacking on the IRP Overlay
268//
270 {
275
276//
277// Special version of the IRP Overlay used to optimize I/O completion
278// by not using up a separate structure.
279//
281{
282 struct
283 {
285 union
286 {
289 };
290 };
296
297//
298// I/O Completion Context for IoSetIoCompletionRoutineEx
299//
301{
306
307//
308// I/O Wrapper around the Executive Work Item
309//
310typedef struct _IO_WORKITEM
311{
317
318//
319// I/O Wrapper around the Kernel Interrupt
320//
321typedef struct _IO_INTERRUPT
322{
327
328//
329// I/O Error Log Packet Header
330//
331typedef struct _ERROR_LOG_ENTRY
332{
340
341//
342// To simplify matters, the kernel is made to support both the checked and free
343// version of the I/O Remove Lock in the same binary. This structure includes
344// both, since the DDK has the structure with a compile-time #ifdef.
345//
347{
351
352//
353// Dummy File Object used inside the Open Packet so that OB knows how to
354// deal with the Object Pointer even though it's not a real file.
355//
356typedef struct _DUMMY_FILE_OBJECT
357{
361
362//
363// Open packet used as a context for Device/File parsing so that the parse
364// routine can know what operation is being requested.
365//
366typedef struct _OPEN_PACKET
367{
397
398//
399// Boot Driver List Entry
400//
401typedef struct _DRIVER_INFORMATION
402{
412
413//
414// List of Bus Type GUIDs
415//
417{
423
424//
425// Shutdown entry for registed devices
426//
427typedef struct _SHUTDOWN_ENTRY
428{
432
433//
434// F/S Notification entry for registered File Systems
435//
437{
442
443//
444// Driver (Boot) Re-Initialization Entry
445//
447{
453
454//
455// Called on every visit of a node during a preorder-traversal of the device
456// node tree.
457// If the routine returns STATUS_UNSUCCESSFUL the traversal will stop and
458// STATUS_SUCCESS is returned to the caller who initiated the tree traversal.
459// Any other returned status code will be returned to the caller. If a status
460// code that indicates an error (other than STATUS_UNSUCCESSFUL) is returned,
461// the traversal is stopped immediately and the status code is returned to
462// the caller.
463//
464typedef
469);
470
471//
472// Context information for traversing the device tree
473//
475{
476 //
477 // Current device node during a traversal
478 //
480
481 //
482 // Initial device node where we start the traversal
483 //
485
486 //
487 // Action routine to be called for every device node
488 //
490
491 //
492 // Context passed to the action routine
493 //
496
497//
498// Reserve IRP allocator
499// Used for read paging IOs in low-memory situations
500//
502{
508
509//
510// Type selection for IopCreateSecurityDescriptorPerType()
511//
513{
520
521//
522// Action types and data for PiQueueDeviceAction()
523//
524typedef enum _DEVICE_ACTION
525{
533
534//
535// Resource code
536//
537ULONG
538NTAPI
540
542NTAPI
545);
546
548NTAPI
552);
553
555NTAPI
558 IN BOOLEAN Silent,
559 OUT OPTIONAL PCM_PARTIAL_RESOURCE_DESCRIPTOR ConflictingDescriptor
560);
561
562//
563// PNP Routines
564//
566NTAPI
569 IN BOOLEAN LoadDriver,
571);
572
573CODE_SEG("INIT")
575NTAPI
577 VOID
578);
579
581NTAPI
583 VOID
584);
585
586VOID
588 VOID
589);
590
591VOID
593 VOID
594);
595
599);
600
604);
605
606VOID
609 _In_ PDEVICE_NODE ParentNode);
610
614 _In_ PNP_DEVNODE_STATE NewState);
615
616VOID
619 _In_ UINT32 Problem);
620
621VOID
624
628);
629
631NTAPI
633 PDEVICE_CAPABILITIES DeviceCaps);
634
638 IN PIO_STACK_LOCATION IoStackLocation,
640);
641
643NTAPI
649);
650
655);
656
659 VOID
660);
661
664 VOID
665);
666
667CODE_SEG("INIT")
670
676
680 _In_ PUNICODE_STRING DeviceIds);
681
685 _In_ PUNICODE_STRING DeviceId);
686
688NTAPI
694
696NTAPI
701);
702
704NTAPI
707 IN HANDLE BaseHandle OPTIONAL,
712);
713
714
718
720NTAPI
725
726//
727// PnP Routines
728//
729CODE_SEG("INIT")
731NTAPI
733 VOID
734);
735
736CODE_SEG("INIT")
738NTAPI
740 VOID
741);
742
743USHORT
744NTAPI
746 IN HANDLE ServiceHandle
747);
748
749USHORT
750NTAPI
752 IN HANDLE ServiceHandle
753);
754
756NTAPI
758 IN PKEY_VALUE_FULL_INFORMATION KeyValueInformation,
759 OUT PUNICODE_STRING *UnicodeStringList,
760 OUT PULONG UnicodeStringCount
761);
762
764NTAPI
766 IN PWCHAR RegSzData,
767 IN ULONG RegSzLength,
768 OUT PUSHORT StringLength OPTIONAL
769);
770
771VOID
774 _In_ HANDLE InstanceKey);
775
776//
777// Initialization Routines
778//
779CODE_SEG("INIT")
781NTAPI
783 IN PLOADER_PARAMETER_BLOCK LoaderBlock
784);
785
786CODE_SEG("INIT")
788NTAPI
790 IN PLOADER_PARAMETER_BLOCK LoaderBlock,
791 OUT PANSI_STRING NtBootPath
792);
793
794CODE_SEG("INIT")
796NTAPI
798 IN PLOADER_PARAMETER_BLOCK LoaderBlock
799);
800
802NTAPI
804 IN PDRIVE_LAYOUT_INFORMATION_EX DriveLayout,
805 IN PARC_DISK_SIGNATURE ArcDiskSignature,
807);
808
810NTAPI
812 IN HANDLE PageFileHandle
813);
814
815CODE_SEG("INIT")
816VOID
818 VOID);
819
820//
821// Device/Volume Routines
822//
823VOID
824NTAPI
827);
828
829PVPB
830NTAPI
832 IN POPEN_PACKET OpenPacket,
836);
837
839NTAPI
842 IN BOOLEAN AllowRawMount,
843 IN BOOLEAN DeviceIsLocked,
845 OUT PVPB *Vpb
846);
847
848PVOID
851);
852
853PVOID
857);
858
860NTAPI
863);
864
865VOID
866NTAPI
868 IN PVPB Vpb
869);
870
871VOID
872NTAPI
874 VOID
875);
876
877VOID
878NTAPI
880 VOID
881);
882
884NTAPI
887);
888
889VOID
890NTAPI
893 IN BOOLEAN ForceUnload
894);
895
897NTAPI
901
903NTAPI
907);
908
909VOID
910NTAPI
913);
914
916NTAPI
919);
920
921//
922// IRP Routines
923//
925NTAPI
928 IN PKEVENT EventObject,
930);
931
932VOID
933NTAPI
935 IN PKEVENT EventObject,
936 IN PIRP Irp
937);
938
939PIRP
940NTAPI
943);
944
946NTAPI
948 IN PRESERVE_IRP_ALLOCATOR ReserveIrpAllocator
949);
950
951PIRP
952NTAPI
955);
956
957//
958// Shutdown routines
959//
960VOID
962 VOID
963);
964
965VOID
966NTAPI
968 IN ULONG Phase
969);
970
971VOID
972NTAPI
974 IN PLIST_ENTRY ListHead
975);
976
977//
978// Boot logging support
979//
980CODE_SEG("INIT")
981VOID
983 IN BOOLEAN StartBootLog
984);
985
986CODE_SEG("INIT")
987VOID
989 VOID
990);
991
992VOID
994 VOID
995);
996
997VOID
999 IN PUNICODE_STRING DriverName,
1001);
1002
1003VOID
1005 VOID
1006);
1007
1008//
1009// I/O Cancellation Routines
1010//
1011VOID
1012NTAPI
1015);
1016
1017VOID
1019 VOID
1020);
1021
1022//
1023// I/O Completion
1024//
1025VOID
1026NTAPI
1028 IN PKAPC Apc,
1029 IN PKNORMAL_ROUTINE* NormalRoutine,
1030 IN PVOID* NormalContext,
1033);
1034
1035//
1036// Error Logging Routines
1037//
1038VOID
1039NTAPI
1041 VOID
1042);
1043
1044VOID
1045NTAPI
1048);
1049
1050//
1051// Raw File System MiniDriver
1052//
1053BOOLEAN
1056);
1057
1058CODE_SEG("INIT")
1060NTAPI
1064);
1065
1066//
1067// PnP Root MiniDriver
1068//
1070NTAPI
1074);
1075
1079
1084 OUT PUNICODE_STRING FullInstancePath
1085);
1086
1090
1091VOID
1093
1094//
1095// Driver Routines
1096//
1097CODE_SEG("INIT")
1098VOID
1101 VOID
1102);
1103
1104CODE_SEG("INIT")
1105VOID
1108 VOID
1109);
1110
1111VOID
1112NTAPI
1114 IN PVOID ObjectBody
1115);
1116
1119 _In_ HANDLE ServiceHandle,
1121
1124 _In_ HANDLE ServiceHandle,
1125 _Out_ PUNICODE_STRING DriverName,
1127
1130 _In_ PLDR_DATA_TABLE_ENTRY ModuleObject,
1131 _In_ HANDLE ServiceHandle,
1133 _Out_ NTSTATUS *DriverEntryStatus);
1134
1139 IN HANDLE EnumSubKey,
1140 IN HANDLE ClassKey,
1141 IN BOOLEAN Lower
1142);
1143
1144VOID
1145NTAPI
1147 VOID
1148);
1149
1150VOID
1151NTAPI
1153 VOID
1154);
1155
1156//
1157// File Routines
1158//
1159VOID
1160NTAPI
1161IopDeleteDevice(IN PVOID ObjectBody);
1162
1164NTAPI
1166 IN PVOID ParseObject,
1171 IN OUT PUNICODE_STRING CompleteName,
1176);
1177
1179NTAPI
1181 IN PVOID ParseObject,
1186 IN OUT PUNICODE_STRING CompleteName,
1191);
1192
1193VOID
1194NTAPI
1196 IN PVOID ObjectBody
1197);
1198
1200NTAPI
1202 IN PVOID ObjectBody,
1203 IN SECURITY_OPERATION_CODE OperationCode,
1207 OUT PSECURITY_DESCRIPTOR *OldSecurityDescriptor,
1210);
1211
1213NTAPI
1215 IN PVOID ObjectBody,
1216 IN BOOLEAN HasName,
1217 OUT POBJECT_NAME_INFORMATION ObjectNameInfo,
1218 IN ULONG Length,
1221);
1222
1224NTAPI
1226 IN PVOID ObjectBody,
1227 IN BOOLEAN HasName,
1228 IN BOOLEAN QueryDosName,
1229 OUT POBJECT_NAME_INFORMATION ObjectNameInfo,
1230 IN ULONG Length,
1233);
1234
1235VOID
1236NTAPI
1239 IN PVOID Object,
1242 IN ULONG SystemHandleCount
1243);
1244
1246NTAPI
1251 _Out_ PBOOLEAN LockFailed
1252);
1253
1254PVOID
1255NTAPI
1258);
1259
1261NTAPI
1265 IN BOOLEAN Define
1266);
1267
1268VOID
1269NTAPI
1271 IN PIRP Irp,
1273 IN PREPARSE_DATA_BUFFER DataBuffer
1274);
1275
1277NTAPI
1281);
1282
1284NTAPI
1287 IN ULONG Length,
1288 IN FILE_INFORMATION_CLASS FileInfoClass,
1291);
1292
1293BOOLEAN
1294NTAPI
1296 IN PDEVICE_OBJECT BaseDeviceObject,
1297 IN PDEVICE_OBJECT TopDeviceObjectHint
1298);
1299
1300//
1301// I/O Timer Routines
1302//
1303VOID
1306 VOID
1307);
1308
1309VOID
1310NTAPI
1313);
1314
1315//
1316// I/O Completion Routines
1317//
1318VOID
1319NTAPI
1321 PVOID ObjectBody
1322);
1323
1325NTAPI
1328 IN PVOID KeyContext,
1331 IN ULONG_PTR IoStatusInformation,
1332 IN BOOLEAN Quota
1333);
1334
1335//
1336// Ramdisk Routines
1337//
1338CODE_SEG("INIT")
1340NTAPI
1342 IN PLOADER_PARAMETER_BLOCK LoaderBlock
1343);
1344
1345//
1346// Configuration Routines
1347//
1351 _In_ GUID Guid,
1353 _Out_ PULONG Interfaces
1354);
1355
1356VOID
1358 _In_ PUNICODE_STRING NtSystemPartitionDeviceName,
1359 _In_ PUNICODE_STRING OsLoaderPathName
1360);
1361
1362//
1363// Device action
1364//
1365VOID
1369 _In_opt_ PKEVENT CompletionEvent,
1370 _Out_opt_ NTSTATUS *CompletionStatus);
1371
1376
1377//
1378// PnP notifications
1379//
1380CODE_SEG("PAGE")
1381VOID
1386
1387CODE_SEG("PAGE")
1388VOID
1391
1392CODE_SEG("PAGE")
1393VOID
1397 _In_opt_ PTARGET_DEVICE_CUSTOM_NOTIFICATION CustomNotification);
1398
1399//
1400// PnP IRPs
1401//
1405
1409
1413
1417
1422
1427
1432
1438 _Out_ PWSTR *DeviceText);
1439
1444
1445//
1446// Global I/O Data
1447//
1451extern ULONG IopTraceLevel;
1466
1467//
1468// Inlined Functions
1469//
1470#include "io_x.h"
@ DeviceNode
Definition: Node.h:9
unsigned char BOOLEAN
unsigned int UINT32
static GENERIC_MAPPING GenericMapping
Definition: SeInheritance.c:11
static ULONG StackSize
Definition: StackOverflow.c:19
Type
Definition: Type.h:7
LONG NTSTATUS
Definition: precomp.h:26
static WCHAR ServiceName[]
Definition: browser.c:19
_In_ ULONG _In_ BATTERY_QUERY_INFORMATION_LEVEL _In_ LONG _In_ ULONG _Out_ PULONG ReturnedLength
Definition: batclass.h:188
static const CLASS_AND_INTERFACES ExpectedInterfaces[]
Definition: browseui.c:13
PDEVICE_OBJECT PhysicalDeviceObject
Definition: btrfs_drv.h:1157
_Inout_ PFCB _Inout_ PUNICODE_STRING RemainingName
Definition: cdprocs.h:802
Definition: bufpool.h:45
_In_ PIRP Irp
Definition: csq.h:116
#define NTSTATUS
Definition: precomp.h:21
static const WCHAR SymbolicLink[]
Definition: interface.c:31
static const WCHAR Signature[]
Definition: parser.c:141
NTSTATUS NTAPI IoCompletion(PDEVICE_OBJECT DeviceObject, PIRP Irp, PVOID Ctx)
Definition: control.c:382
IN CINT OUT PVOID IN ULONG OUT PULONG ReturnLength
Definition: dumpinfo.c:43
ULONG KSPIN_LOCK
Definition: env_spec_w32.h:72
@ Success
Definition: eventcreate.c:712
IN OUT PVCB IN PDEVICE_OBJECT IN PVPB Vpb
Definition: fatprocs.h:1675
#define MAXIMUM_PROCESSORS
Definition: rwlock.h:5
_In_opt_ PFILE_OBJECT _In_opt_ PETHREAD Thread
Definition: fltkernel.h:2653
_Must_inspect_result_ _In_ PFILE_OBJECT _In_ SECURITY_INFORMATION SecurityInformation
Definition: fltkernel.h:1340
enum _FILE_INFORMATION_CLASS FILE_INFORMATION_CLASS
Definition: directory.c:44
_In_ PLIST_ENTRY _In_ PSTRING _In_ USHORT _In_opt_ PSTRING _In_opt_ PSTRING _In_ ULONG _In_ ULONG _In_opt_ PVOID _In_opt_ PVOID FilterContext
Definition: fsrtlfuncs.h:746
_Must_inspect_result_ _In_ PLARGE_INTEGER _In_ PLARGE_INTEGER _In_ ULONG _In_ PFILE_OBJECT _In_ PVOID Process
Definition: fsrtlfuncs.h:223
_Must_inspect_result_ _In_ WDFDEVICE _In_ REFGUID EventGuid
ULONG Handle
Definition: gdb_input.c:15
Status
Definition: gdiplustypes.h:25
@ ProcessHandleCount
Definition: winternl.h:876
static CODE_SEG("PAGE")
Definition: isapnp.c:1482
* PNTSTATUS
Definition: strlen.c:14
ObjectType
Definition: metafile.c:81
static OUT PIO_STATUS_BLOCK IoStatusBlock
Definition: pipe.c:75
DWORD * PSECURITY_INFORMATION
Definition: ms-dtyp.idl:311
#define _Out_opt_
Definition: ms_sal.h:346
#define _Out_
Definition: ms_sal.h:345
#define _In_
Definition: ms_sal.h:308
#define _In_opt_
Definition: ms_sal.h:309
__in UCHAR __in POWER_STATE __in_opt PVOID __in PIO_STATUS_BLOCK IoStatus
Definition: mxum.h:159
_Must_inspect_result_ _Out_ PNDIS_STATUS _In_ NDIS_HANDLE _In_ ULONG _Out_ PNDIS_STRING _Out_ PNDIS_HANDLE KeyHandle
Definition: ndis.h:4715
_In_ ACCESS_MASK _In_ POBJECT_ATTRIBUTES _Reserved_ ULONG _In_opt_ PUNICODE_STRING _In_ ULONG _Out_opt_ PULONG Disposition
Definition: cmfuncs.h:56
_In_ PVOID _In_ BOOLEAN Alertable
Definition: exfuncs.h:453
_In_opt_ HANDLE _In_opt_ PIO_APC_ROUTINE _In_opt_ PVOID ApcContext
Definition: iofuncs.h:727
enum _PNP_DEVNODE_STATE PNP_DEVNODE_STATE
VOID(NTAPI * PKNORMAL_ROUTINE)(IN PVOID NormalContext OPTIONAL, IN PVOID SystemArgument1 OPTIONAL, IN PVOID SystemArgument2 OPTIONAL)
Definition: ketypes.h:744
ULONG ACCESS_MASK
Definition: nt_native.h:40
ACCESS_MASK * PACCESS_MASK
Definition: nt_native.h:41
#define FASTCALL
Definition: nt_native.h:50
_In_ ULONG _In_ ULONG _In_ ULONG Length
Definition: ntddpcm.h:102
@ FILE_OBJECT
Definition: ntobjenum.h:17
NTSTATUS PiIrpQueryResources(_In_ PDEVICE_NODE DeviceNode, _Out_ PCM_RESOURCE_LIST *Resources)
Definition: pnpirp.c:201
struct _DRIVER_INFORMATION DRIVER_INFORMATION
PVOID IoOpenFileOnDevice(IN PVOID SymbolicLink, IN PWCHAR Name)
LIST_ENTRY IopErrorLogListHead
Definition: error.c:30
NTSTATUS NTAPI IopOpenRegistryKeyEx(PHANDLE KeyHandle, HANDLE ParentKey, PUNICODE_STRING Name, ACCESS_MASK DesiredAccess)
Definition: pnpmgr.c:885
NTSTATUS PiIrpStartDevice(_In_ PDEVICE_NODE DeviceNode)
Definition: pnpirp.c:87
LIST_ENTRY IopDeviceActionRequestList
Definition: devaction.c:46
PDEVICE_NODE FASTCALL IopGetDeviceNode(IN PDEVICE_OBJECT DeviceObject)
NTSTATUS PiIrpQueryPnPDeviceState(_In_ PDEVICE_NODE DeviceNode, _Out_ PPNP_DEVICE_STATE DeviceState)
Definition: pnpirp.c:284
enum _SECURITY_DESCRIPTOR_TYPE SECURITY_DESCRIPTOR_TYPE
BOOLEAN NTAPI IoInitSystem(IN PLOADER_PARAMETER_BLOCK LoaderBlock)
Definition: iomgr.c:465
enum _IOP_TRANSFER_TYPE IOP_TRANSFER_TYPE
NTSTATUS PiIrpCancelStopDevice(_In_ PDEVICE_NODE DeviceNode)
Definition: pnpirp.c:154
VOID NTAPI IoCancelThreadIo(IN PETHREAD Thread)
Definition: irp.c:1146
struct _EXTENDED_IO_REMOVE_LOCK * PEXTENDED_IO_REMOVE_LOCK
VOID NTAPI IopRemoveTimerFromTimerList(IN PIO_TIMER Timer)
Definition: iotimer.c:70
NTSTATUS NTAPI RawFsDriverEntry(IN PDRIVER_OBJECT DriverObject, IN PUNICODE_STRING RegistryPath)
Definition: rawfs.c:1193
VOID NTAPI IopReinitializeBootDrivers(VOID)
Definition: driver.c:1532
NTSTATUS NTAPI IoChangeFileObjectFilterContext(IN PFILE_OBJECT FileObject, IN PVOID FilterContext, IN BOOLEAN Define)
Definition: file.c:2511
KSPIN_LOCK IopDeviceActionLock
Definition: devaction.c:49
_DEVICE_ACTION
Definition: io.h:525
@ PiActionResetDevice
Definition: io.h:528
@ PiActionQueryState
Definition: io.h:531
@ PiActionAddBootDevices
Definition: io.h:529
@ PiActionStartDevice
Definition: io.h:530
@ PiActionEnumRootDevices
Definition: io.h:527
@ PiActionEnumDeviceTree
Definition: io.h:526
NTSTATUS IopInitPlugPlayEvents(VOID)
Definition: plugplay.c:40
NTSTATUS IopInitializeDriverModule(_In_ PLDR_DATA_TABLE_ENTRY ModuleObject, _In_ HANDLE ServiceHandle, _Out_ PDRIVER_OBJECT *DriverObject, _Out_ NTSTATUS *DriverEntryStatus)
Initialize a loaded driver.
Definition: driver.c:443
ULONG NTAPI PnpDetermineResourceListSize(IN PCM_RESOURCE_LIST ResourceList)
Definition: pnpmgr.c:1237
VOID NTAPI IopLogWorker(IN PVOID Parameter)
Definition: error.c:148
VOID NTAPI IopUnloadDevice(IN PDEVICE_OBJECT DeviceObject)
Definition: device.c:390
NTSTATUS IopLoadDriver(_In_ HANDLE ServiceHandle, _Out_ PDRIVER_OBJECT *DriverObject)
Definition: driver.c:1938
POBJECT_TYPE _IoFileObjectType
VOID PnpRootInitializeDevExtension(VOID)
Definition: pnproot.c:1440
BOOLEAN NTAPI IoInitializeCrashDump(IN HANDLE PageFileHandle)
Definition: iomgr.c:649
GENERIC_MAPPING IopFileMapping
Definition: iomgr.c:49
NTSTATUS NTAPI IopReferenceDeviceObject(IN PDEVICE_OBJECT DeviceObject)
VOID PiInsertDevNode(_In_ PDEVICE_NODE DeviceNode, _In_ PDEVICE_NODE ParentNode)
Definition: devnode.c:80
BOOLEAN IoRemoteBootClient
Definition: init.c:70
NTSTATUS NTAPI IopFixupResourceListWithRequirements(IN PIO_RESOURCE_REQUIREMENTS_LIST RequirementsList, OUT PCM_RESOURCE_LIST *ResourceList)
Definition: pnpres.c:219
_SECURITY_DESCRIPTOR_TYPE
Definition: io.h:513
@ RestrictedPublicOpen
Definition: io.h:516
@ RestrictedPublic
Definition: io.h:514
@ UnrestrictedPublicOpen
Definition: io.h:517
@ SystemDefault
Definition: io.h:518
@ UnrestrictedPublic
Definition: io.h:515
USHORT NTAPI PpInitGetGroupOrderIndex(IN HANDLE ServiceHandle)
Definition: pnpinit.c:149
PVOID IoOpenSymlink(IN PVOID SymbolicLink)
VOID NTAPI IopCompleteRequest(IN PKAPC Apc, IN PKNORMAL_ROUTINE *NormalRoutine, IN PVOID *NormalContext, IN PVOID *SystemArgument1, IN PVOID *SystemArgument2)
Definition: irp.c:238
NTSTATUS IopFetchConfigurationInformation(_Out_ PWSTR *SymbolicLinkList, _In_ GUID Guid, _In_ ULONG ExpectedInterfaces, _Out_ PULONG Interfaces)
Definition: iorsrce.c:821
NTSTATUS NTAPI IopGetSetSecurityObject(IN PVOID ObjectBody, IN SECURITY_OPERATION_CODE OperationCode, IN PSECURITY_INFORMATION SecurityInformation, IN OUT PSECURITY_DESCRIPTOR SecurityDescriptor, IN OUT PULONG BufferLength, OUT PSECURITY_DESCRIPTOR *OldSecurityDescriptor, IN POOL_TYPE PoolType, IN OUT PGENERIC_MAPPING GenericMapping)
NTSTATUS NTAPI IopQueryDeviceCapabilities(PDEVICE_NODE DeviceNode, PDEVICE_CAPABILITIES DeviceCaps)
Definition: devaction.c:854
NTSTATUS NTAPI IoComputeDesiredAccessFileObject(IN PFILE_OBJECT FileObject, IN PACCESS_MASK DesiredAccess)
Definition: util.c:26
VOID NTAPI IopShutdownBaseFileSystems(IN PLIST_ENTRY ListHead)
Definition: volume.c:349
BOOLEAN NTAPI IopInitializeReserveIrp(IN PRESERVE_IRP_ALLOCATOR ReserveIrpAllocator)
Definition: irp.c:549
struct _OPEN_PACKET * POPEN_PACKET
VOID IopStartBootLog(VOID)
Definition: bootlog.c:38
NTSTATUS NTAPI IopAssignDeviceResources(IN PDEVICE_NODE DeviceNode)
Definition: pnpres.c:1116
PVPB NTAPI IopCheckVpbMounted(IN POPEN_PACKET OpenPacket, IN PDEVICE_OBJECT DeviceObject, IN PUNICODE_STRING RemainingName, OUT PNTSTATUS Status)
Definition: volume.c:76
struct _FILE_OBJECT_EXTENSION FILE_OBJECT_EXTENSION
VOID IopStoreSystemPartitionInformation(_In_ PUNICODE_STRING NtSystemPartitionDeviceName, _In_ PUNICODE_STRING OsLoaderPathName)
Definition: iorsrce.c:860
struct _IOP_MINI_COMPLETION_PACKET IOP_MINI_COMPLETION_PACKET
VOID FASTCALL IopInitializeSystemDrivers(VOID)
Definition: driver.c:1210
POBJECT_TYPE IoCompletionType
Definition: iocomp.c:16
PDEVICE_NODE PipAllocateDeviceNode(IN PDEVICE_OBJECT PhysicalDeviceObject)
NTSTATUS IoCreateDriverList(VOID)
struct _EXTENDED_IO_REMOVE_LOCK EXTENDED_IO_REMOVE_LOCK
VOID PiClearDevNodeProblem(_In_ PDEVICE_NODE DeviceNode)
Definition: devnode.c:141
struct _IO_BUS_TYPE_GUID_LIST IO_BUS_TYPE_GUID_LIST
PIRP NTAPI IopAllocateReserveIrp(IN CCHAR StackSize)
Definition: irp.c:573
VOID IopInitBootLog(IN BOOLEAN StartBootLog)
VOID IopSaveBootLogToFile(VOID)
Definition: bootlog.c:288
KSPIN_LOCK IopDeviceTreeLock
Definition: devnode.c:19
ULONG IopNumTriageDumpDataBlocks
Definition: iomgr.c:46
struct _ERROR_LOG_ENTRY * PERROR_LOG_ENTRY
NTSTATUS NTAPI IopQueryNameInternal(IN PVOID ObjectBody, IN BOOLEAN HasName, IN BOOLEAN QueryDosName, OUT POBJECT_NAME_INFORMATION ObjectNameInfo, IN ULONG Length, OUT PULONG ReturnLength, IN KPROCESSOR_MODE PreviousMode)
Definition: file.c:1944
BOOLEAN NTAPI IopVerifyDeviceObjectOnStack(IN PDEVICE_OBJECT BaseDeviceObject, IN PDEVICE_OBJECT TopDeviceObjectHint)
Definition: device.c:695
VOID NTAPI IopInitErrorLog(VOID)
NTSTATUS NTAPI IopCreateDeviceKeyPath(IN PCUNICODE_STRING RegistryPath, IN ULONG CreateOptions, OUT PHANDLE Handle)
Definition: pnpmgr.c:522
enum _IOP_DEVICE_LIST_OPERATION * PIOP_DEVICE_LIST_OPERATION
VOID PiNotifyTargetDeviceChange(_In_ LPCGUID Event, _In_ PDEVICE_OBJECT DeviceObject, _In_opt_ PTARGET_DEVICE_CUSTOM_NOTIFICATION CustomNotification)
Delivers the event to all drivers subscribed to EventCategoryTargetDeviceChange PnP event.
Definition: pnpnotify.c:258
VOID NTAPI IopDereferenceDeviceObject(IN PDEVICE_OBJECT DeviceObject, IN BOOLEAN ForceUnload)
Definition: device.c:462
NTSTATUS NTAPI IopCleanupFailedIrp(IN PFILE_OBJECT FileObject, IN PKEVENT EventObject, IN PVOID Buffer OPTIONAL)
Definition: irp.c:45
NTSTATUS NTAPI IopCreateVpb(IN PDEVICE_OBJECT DeviceObject)
Definition: volume.c:158
NTSTATUS PnpRootRegisterDevice(IN PDEVICE_OBJECT DeviceObject)
Definition: pnproot.c:107
BOOLEAN NTAPI PnpRegSzToString(IN PWCHAR RegSzData, IN ULONG RegSzLength, OUT PUSHORT StringLength OPTIONAL)
Definition: pnputil.c:171
USHORT NTAPI PipGetDriverTagPriority(IN HANDLE ServiceHandle)
Definition: pnpinit.c:192
NTSTATUS NTAPI IopInitializePlugPlayServices(VOID)
Definition: pnpinit.c:287
struct _FS_CHANGE_NOTIFY_ENTRY FS_CHANGE_NOTIFY_ENTRY
VOID PnpInit2(VOID)
NTSTATUS NTAPI IopParseFile(IN PVOID ParseObject, IN PVOID ObjectType, IN OUT PACCESS_STATE AccessState, IN KPROCESSOR_MODE AccessMode, IN ULONG Attributes, IN OUT PUNICODE_STRING CompleteName, IN OUT PUNICODE_STRING RemainingName, IN OUT PVOID Context OPTIONAL, IN PSECURITY_QUALITY_OF_SERVICE SecurityQos OPTIONAL, OUT PVOID *Object)
Definition: file.c:1319
NTSTATUS PnpRootCreateDevice(IN PUNICODE_STRING ServiceName, OUT PDEVICE_OBJECT *PhysicalDeviceObject, OUT PUNICODE_STRING FullInstancePath)
Definition: pnproot.c:184
NTSTATUS IopGetSystemPowerDeviceObject(IN PDEVICE_OBJECT *DeviceObject)
VOID NTAPI IopDoNameTransmogrify(IN PIRP Irp, IN PFILE_OBJECT FileObject, IN PREPARSE_DATA_BUFFER DataBuffer)
Definition: file.c:170
enum _SECURITY_DESCRIPTOR_TYPE * PSECURITY_DESCRIPTOR_TYPE
_IOP_TRANSFER_TYPE
Definition: io.h:260
@ IopWriteTransfer
Definition: io.h:262
@ IopReadTransfer
Definition: io.h:261
@ IopOtherTransfer
Definition: io.h:263
PVOID IopTriageDumpDataBlocks[64]
Definition: iomgr.c:47
NTSTATUS NTAPI IopGetRelatedTargetDevice(IN PFILE_OBJECT FileObject, OUT PDEVICE_NODE *DeviceNode)
Definition: device.c:653
NTSTATUS NTAPI IoGetRelatedTargetDevice(IN PFILE_OBJECT FileObject, OUT PDEVICE_OBJECT *DeviceObject)
Definition: device.c:1607
NTSTATUS IopQueueDeviceInstallEvent(_In_ const GUID *Guid, _In_ PUNICODE_STRING DeviceId)
Definition: plugplay.c:97
VOID IopInitDriverImplementation(VOID)
VOID NTAPI IopAbortInterruptedIrp(IN PKEVENT EventObject, IN PIRP Irp)
Definition: irp.c:67
NTSTATUS NTAPI IopGetRegistryValue(IN HANDLE Handle, IN PWSTR ValueName, OUT PKEY_VALUE_FULL_INFORMATION *Information)
Definition: pnpmgr.c:1036
VOID NTAPI IoInitVpbImplementation(VOID)
PIRP NTAPI IopAllocateIrpMustSucceed(IN CCHAR StackSize)
Definition: irp.c:716
NTSTATUS FASTCALL IopAttachFilterDrivers(IN PDEVICE_NODE DeviceNode, IN HANDLE EnumSubKey, IN HANDLE ClassKey, IN BOOLEAN Lower)
struct _SHUTDOWN_ENTRY SHUTDOWN_ENTRY
struct _IO_INTERRUPT * PIO_INTERRUPT
NTSTATUS NTAPI PiInitCacheGroupInformation(VOID)
Definition: pnpinit.c:94
PIO_BUS_TYPE_GUID_LIST IopBusTypeGuidList
struct _FS_CHANGE_NOTIFY_ENTRY * PFS_CHANGE_NOTIFY_ENTRY
NTSTATUS NTAPI PnpRootDriverEntry(IN PDRIVER_OBJECT DriverObject, IN PUNICODE_STRING RegistryPath)
Definition: pnproot.c:1488
_COMPLETION_PACKET_TYPE
Definition: io.h:270
@ IopCompletionPacketIrp
Definition: io.h:271
@ IopCompletionPacketMini
Definition: io.h:272
@ IopCompletionPacketQuota
Definition: io.h:273
struct _DRIVER_INFORMATION * PDRIVER_INFORMATION
NTSTATUS IopTraverseDeviceTree(PDEVICETREE_TRAVERSE_CONTEXT Context)
NTSTATUS IopQueueDeviceChangeEvent(_In_ const GUID *EventGuid, _In_ const GUID *InterfaceClassGuid, _In_ PUNICODE_STRING SymbolicLinkName)
Definition: plugplay.c:52
VOID PiNotifyDeviceInterfaceChange(_In_ LPCGUID Event, _In_ LPCGUID InterfaceClassGuid, _In_ PUNICODE_STRING SymbolicLinkName)
Delivers the event to all drivers subscribed to EventCategoryDeviceInterfaceChange.
Definition: pnpnotify.c:161
VOID PiSetDevNodeText(_In_ PDEVICE_NODE DeviceNode, _In_ HANDLE InstanceKey)
Sets the DeviceNode's DeviceDesc and LocationInformation registry values.
Definition: devaction.c:1089
NTSTATUS IopSynchronousCall(IN PDEVICE_OBJECT DeviceObject, IN PIO_STACK_LOCATION IoStackLocation, OUT PVOID *Information)
NTSTATUS IopFreeDeviceNode(IN PDEVICE_NODE DeviceNode)
struct _DUMMY_FILE_OBJECT DUMMY_FILE_OBJECT
VOID NTAPI IoShutdownSystem(IN ULONG Phase)
Definition: device.c:133
NTSTATUS NTAPI IopInitiatePnpIrp(IN PDEVICE_OBJECT DeviceObject, IN PIO_STATUS_BLOCK IoStatusBlock, IN UCHAR MinorFunction, IN PIO_STACK_LOCATION Stack)
PVOID NTAPI IoGetFileObjectFilterContext(IN PFILE_OBJECT FileObject)
Definition: file.c:2496
BOOLEAN NTAPI IopVerifyDiskSignature(IN PDRIVE_LAYOUT_INFORMATION_EX DriveLayout, IN PARC_DISK_SIGNATURE ArcDiskSignature, OUT PULONG Signature)
Definition: arcname.c:948
NTSTATUS NTAPI IopQueryName(IN PVOID ObjectBody, IN BOOLEAN HasName, OUT POBJECT_NAME_INFORMATION ObjectNameInfo, IN ULONG Length, OUT PULONG ReturnLength, IN KPROCESSOR_MODE PreviousMode)
Definition: file.c:1926
NTSTATUS NTAPI IopAcquireFileObjectLock(_In_ PFILE_OBJECT FileObject, _In_ KPROCESSOR_MODE AccessMode, _In_ BOOLEAN Alertable, _Out_ PBOOLEAN LockFailed)
Definition: file.c:2450
VOID NTAPI IopDeleteDriver(IN PVOID ObjectBody)
Definition: driver.c:77
struct _IO_UNLOAD_SAFE_COMPLETION_CONTEXT * PIO_UNLOAD_SAFE_COMPLETION_CONTEXT
struct _RESERVE_IRP_ALLOCATOR RESERVE_IRP_ALLOCATOR
NTSTATUS IopGetDriverNames(_In_ HANDLE ServiceHandle, _Out_ PUNICODE_STRING DriverName, _Out_opt_ PUNICODE_STRING ServiceName)
Definition: driver.c:123
VOID FASTCALL IopInitializeBootDrivers(VOID)
Definition: driver.c:1023
NTSTATUS PiIrpQueryResourceRequirements(_In_ PDEVICE_NODE DeviceNode, _Out_ PIO_RESOURCE_REQUIREMENTS_LIST *Resources)
Definition: pnpirp.c:227
NTSTATUS NTAPI IopUpdateRootKey(VOID)
Definition: pnpmap.c:670
VOID PiSetDevNodeProblem(_In_ PDEVICE_NODE DeviceNode, _In_ UINT32 Problem)
Definition: devnode.c:132
NTSTATUS NTAPI IopCreateRegistryKeyEx(OUT PHANDLE Handle, IN HANDLE BaseHandle OPTIONAL, IN PUNICODE_STRING KeyName, IN ACCESS_MASK DesiredAccess, IN ULONG CreateOptions, OUT PULONG Disposition OPTIONAL)
NTSTATUS NTAPI IopStartRamdisk(IN PLOADER_PARAMETER_BLOCK LoaderBlock)
Definition: ramdisk.c:26
PNP_DEVNODE_STATE PiSetDevNodeState(_In_ PDEVICE_NODE DeviceNode, _In_ PNP_DEVNODE_STATE NewState)
Definition: devnode.c:108
enum _DEVICE_ACTION DEVICE_ACTION
NTSTATUS NTAPI PipCallDriverAddDevice(IN PDEVICE_NODE DeviceNode, IN BOOLEAN LoadDriver, IN PDRIVER_OBJECT DriverObject)
struct _DUMMY_FILE_OBJECT * PDUMMY_FILE_OBJECT
struct _IO_BUS_TYPE_GUID_LIST * PIO_BUS_TYPE_GUID_LIST
struct _SHUTDOWN_ENTRY * PSHUTDOWN_ENTRY
NTSTATUS NTAPI IopDetectResourceConflict(IN PCM_RESOURCE_LIST ResourceList, IN BOOLEAN Silent, OUT OPTIONAL PCM_PARTIAL_RESOURCE_DESCRIPTOR ConflictingDescriptor)
Definition: pnpres.c:1255
enum _IOP_TRANSFER_TYPE * PIOP_TRANSFER_TYPE
enum _COMPLETION_PACKET_TYPE COMPLETION_PACKET_TYPE
VOID NTAPI IoInitFileSystemImplementation(VOID)
VOID IopStopBootLog(VOID)
Definition: bootlog.c:46
VOID NTAPI IopCloseFile(IN PEPROCESS Process OPTIONAL, IN PVOID Object, IN ACCESS_MASK GrantedAccess, IN ULONG ProcessHandleCount, IN ULONG SystemHandleCount)
Definition: file.c:2178
VOID NTAPI IopReinitializeDrivers(VOID)
Definition: driver.c:1496
struct _DEVICETREE_TRAVERSE_CONTEXT DEVICETREE_TRAVERSE_CONTEXT
VOID IoInitCancelHandling(VOID)
NTSTATUS PiIrpQueryStopDevice(_In_ PDEVICE_NODE DeviceNode)
Definition: pnpirp.c:133
struct _FILE_OBJECT_EXTENSION * PFILE_OBJECT_EXTENSION
NTSTATUS NTAPI IoSetIoCompletion(IN PVOID IoCompletion, IN PVOID KeyContext, IN PVOID ApcContext, IN NTSTATUS IoStatus, IN ULONG_PTR IoStatusInformation, IN BOOLEAN Quota)
Definition: iocomp.c:147
NTSTATUS PiIrpStopDevice(_In_ PDEVICE_NODE DeviceNode)
Definition: pnpirp.c:111
PIO_BUS_TYPE_GUID_LIST PnpBusTypeGuidList
Definition: pnpmgr.c:27
NTSTATUS IopQueueTargetDeviceEvent(_In_ const GUID *Guid, _In_ PUNICODE_STRING DeviceIds)
PDRIVER_OBJECT IopRootDriverObject
Definition: pnpmgr.c:26
NTSTATUS NTAPI IopGetFileInformation(IN PFILE_OBJECT FileObject, IN ULONG Length, IN FILE_INFORMATION_CLASS FileInfoClass, OUT PVOID Buffer, OUT PULONG ReturnedLength)
Definition: iofunc.c:777
NTSTATUS NTAPI IopMountVolume(IN PDEVICE_OBJECT DeviceObject, IN BOOLEAN AllowRawMount, IN BOOLEAN DeviceIsLocked, IN BOOLEAN Alertable, OUT PVPB *Vpb)
Definition: volume.c:462
VOID FASTCALL IopInitTimerImplementation(VOID)
NTSTATUS NTAPI IopReassignSystemRoot(IN PLOADER_PARAMETER_BLOCK LoaderBlock, OUT PANSI_STRING NtBootPath)
Definition: arcname.c:840
GENERAL_LOOKASIDE IopMdlLookasideList
Definition: iomgr.c:84
NTSTATUS IoDestroyDriverList(VOID)
struct _IO_UNLOAD_SAFE_COMPLETION_CONTEXT IO_UNLOAD_SAFE_COMPLETION_CONTEXT
struct _DRIVER_REINIT_ITEM * PDRIVER_REINIT_ITEM
VOID NTAPI IopDereferenceVpbAndFree(IN PVPB Vpb)
Definition: volume.c:186
VOID PiQueueDeviceAction(_In_ PDEVICE_OBJECT DeviceObject, _In_ DEVICE_ACTION Action, _In_opt_ PKEVENT CompletionEvent, _Out_opt_ NTSTATUS *CompletionStatus)
Queue a device operation to a worker thread.
Definition: devaction.c:2659
PDEVICE_OBJECT NTAPI IopGetDeviceAttachmentBase(IN PDEVICE_OBJECT DeviceObject)
Definition: file.c:1486
NTSTATUS(* DEVICETREE_TRAVERSE_ROUTINE)(IN PDEVICE_NODE DeviceNode, IN PVOID Context)
Definition: io.h:466
struct _IO_WORKITEM IO_WORKITEM
VOID PiInitializeNotifications(VOID)
Definition: pnpnotify.c:55
NTSTATUS PiIrpQueryDeviceText(_In_ PDEVICE_NODE DeviceNode, _In_ LCID LocaleId, _In_ DEVICE_TEXT_TYPE Type, _Out_ PWSTR *DeviceText)
Definition: pnpirp.c:253
VOID NTAPI IopDeleteDevice(IN PVOID ObjectBody)
Definition: device.c:52
ULONG IopTraceLevel
Definition: iomgr.c:16
PDEVICE_NODE IopRootDeviceNode
Definition: devnode.c:18
HAL_DISPATCH _HalDispatchTable
NTSTATUS NTAPI PnpRegMultiSzToUnicodeStrings(IN PKEY_VALUE_FULL_INFORMATION KeyValueInformation, OUT PUNICODE_STRING *UnicodeStringList, OUT PULONG UnicodeStringCount)
Definition: pnputil.c:47
VOID NTAPI IopDeleteIoCompletion(PVOID ObjectBody)
Definition: iocomp.c:100
struct _IOP_MINI_COMPLETION_PACKET * PIOP_MINI_COMPLETION_PACKET
BOOLEAN RawFsIsRawFileSystemDeviceObject(IN PDEVICE_OBJECT DeviceObject)
BOOLEAN NTAPI PpInitSystem(VOID)
Definition: pnpmgr.c:1142
struct _ERROR_LOG_ENTRY ERROR_LOG_ENTRY
NTSTATUS PiIrpQueryDeviceRelations(_In_ PDEVICE_NODE DeviceNode, _In_ DEVICE_RELATION_TYPE Type)
Definition: pnpirp.c:176
_IOP_DEVICE_LIST_OPERATION
Definition: io.h:251
@ IopAdd
Definition: io.h:253
@ IopRemove
Definition: io.h:252
GENERIC_MAPPING IopCompletionMapping
Definition: iocomp.c:20
NTSTATUS PiPerformSyncDeviceAction(_In_ PDEVICE_OBJECT DeviceObject, _In_ DEVICE_ACTION Action)
Perfom a device operation synchronously via PiQueueDeviceAction.
Definition: devaction.c:2718
VOID NTAPI IopDeleteFile(IN PVOID ObjectBody)
Definition: file.c:1355
struct _DEVICETREE_TRAVERSE_CONTEXT * PDEVICETREE_TRAVERSE_CONTEXT
NTSTATUS NTAPI IopParseDevice(IN PVOID ParseObject, IN PVOID ObjectType, IN OUT PACCESS_STATE AccessState, IN KPROCESSOR_MODE AccessMode, IN ULONG Attributes, IN OUT PUNICODE_STRING CompleteName, IN OUT PUNICODE_STRING RemainingName, IN OUT PVOID Context, IN PSECURITY_QUALITY_OF_SERVICE SecurityQos OPTIONAL, OUT PVOID *Object)
Definition: file.c:324
VOID IopBootLog(IN PUNICODE_STRING DriverName, IN BOOLEAN Success)
struct _OPEN_PACKET OPEN_PACKET
VOID NTAPI IopReadyDeviceObjects(IN PDRIVER_OBJECT Driver)
Definition: device.c:34
NTSTATUS NTAPI IopCreateArcNames(IN PLOADER_PARAMETER_BLOCK LoaderBlock)
Definition: arcname.c:39
enum _IOP_DEVICE_LIST_OPERATION IOP_DEVICE_LIST_OPERATION
struct _IO_INTERRUPT IO_INTERRUPT
enum _COMPLETION_PACKET_TYPE * PCOMPLETION_PACKET_TYPE
struct _RESERVE_IRP_ALLOCATOR * PRESERVE_IRP_ALLOCATOR
RESERVE_IRP_ALLOCATOR IopReserveIrpAllocator
Definition: irp.c:19
VOID IoInitShutdownNotification(VOID)
VOID PiNotifyHardwareProfileChange(_In_ LPCGUID Event)
Delivers the event to all drivers subscribed to EventCategoryHardwareProfileChange PnP event.
Definition: pnpnotify.c:214
struct _DRIVER_REINIT_ITEM DRIVER_REINIT_ITEM
NTSTATUS PnpRootCreateDeviceObject(OUT PDEVICE_OBJECT *DeviceObject)
Definition: pnproot.c:167
PVOID *typedef PHANDLE
Definition: ntsecpkg.h:455
long LONG
Definition: pedump.c:60
unsigned short USHORT
Definition: pedump.c:61
DWORD LCID
Definition: nls.h:13
PULONG MinorVersion OPTIONAL
Definition: CrossNt.h:68
Definition: arc.h:246
PDEVICE_NODE FirstDeviceNode
Definition: io.h:484
PDEVICE_NODE DeviceNode
Definition: io.h:479
DEVICETREE_TRAVERSE_ROUTINE Action
Definition: io.h:489
NTSTATUS Status
Definition: io.h:410
HANDLE ServiceHandle
Definition: io.h:406
PBOOT_DRIVER_LIST_ENTRY DataTableEntry
Definition: io.h:405
ULONG Failed
Definition: io.h:408
LIST_ENTRY Link
Definition: io.h:403
ULONG Processed
Definition: io.h:409
USHORT TagPosition
Definition: io.h:407
PDRIVER_OBJECT DriverObject
Definition: io.h:404
PDRIVER_OBJECT DriverObject
Definition: io.h:449
PDRIVER_REINITIALIZE ReinitRoutine
Definition: io.h:450
LIST_ENTRY ItemEntry
Definition: io.h:448
PVOID Context
Definition: io.h:451
CHAR FileObjectBody[sizeof(FILE_OBJECT)]
Definition: io.h:359
OBJECT_HEADER ObjectHeader
Definition: io.h:358
Definition: io.h:332
LARGE_INTEGER TimeStamp
Definition: io.h:338
CSHORT Size
Definition: io.h:334
CSHORT Type
Definition: io.h:333
LIST_ENTRY ListEntry
Definition: io.h:335
PDEVICE_OBJECT DeviceObject
Definition: io.h:336
PDRIVER_OBJECT DriverObject
Definition: io.h:337
IO_REMOVE_LOCK_DBG_BLOCK Dbg
Definition: io.h:349
IO_REMOVE_LOCK_COMMON_BLOCK Common
Definition: io.h:348
PDEVICE_OBJECT TopDeviceObjectHint
Definition: io.h:102
PVOID FilterContext
Definition: io.h:103
Definition: io.h:437
PDRIVER_FS_NOTIFICATION FSDNotificationProc
Definition: io.h:440
LIST_ENTRY FsChangeNotifyList
Definition: io.h:438
PDRIVER_OBJECT DriverObject
Definition: io.h:439
ULONG_PTR IoStatusInformation
Definition: io.h:294
struct _IO_STACK_LOCATION * CurrentStackLocation
Definition: io.h:287
LIST_ENTRY ListEntry
Definition: io.h:284
GUID Guids[1]
Definition: io.h:420
FAST_MUTEX Lock
Definition: io.h:419
KSPIN_LOCK SpinLock
Definition: io.h:325
KINTERRUPT FirstInterrupt
Definition: io.h:323
PIO_COMPLETION_ROUTINE CompletionRoutine
Definition: io.h:304
PDEVICE_OBJECT DeviceObject
Definition: io.h:302
PIO_WORKITEM_ROUTINE WorkerRoutine
Definition: io.h:314
PDEVICE_OBJECT DeviceObject
Definition: io.h:313
WORK_QUEUE_ITEM Item
Definition: io.h:312
PVOID Context
Definition: io.h:315
Definition: ketypes.h:547
Definition: btrfs_drv.h:1876
Definition: typedefs.h:120
LARGE_INTEGER AllocationSize
Definition: io.h:376
BOOLEAN Override
Definition: io.h:388
BOOLEAN DeleteOnly
Definition: io.h:390
OBJECT_ATTRIBUTES OriginalAttributes
Definition: io.h:375
PFILE_BASIC_INFORMATION BasicInformation
Definition: io.h:384
USHORT FileAttributes
Definition: io.h:378
PVOID ExtraCreateParameters
Definition: io.h:387
PFILE_NETWORK_OPEN_INFORMATION NetworkInformation
Definition: io.h:385
USHORT ShareAccess
Definition: io.h:379
BOOLEAN FullAttributes
Definition: io.h:391
NTSTATUS FinalStatus
Definition: io.h:371
CREATE_FILE_TYPE CreateFileType
Definition: io.h:386
PDUMMY_FILE_OBJECT LocalFileObject
Definition: io.h:392
CSHORT Type
Definition: io.h:368
ULONG_PTR Information
Definition: io.h:372
ULONG InternalFlags
Definition: io.h:394
ULONG Disposition
Definition: io.h:383
PDEVICE_OBJECT TopDeviceObjectHint
Definition: io.h:395
PFILE_OBJECT FileObject
Definition: io.h:370
ULONG Options
Definition: io.h:382
BOOLEAN TraversedMountPoint
Definition: io.h:393
PFILE_OBJECT RelatedFileObject
Definition: io.h:374
ULONG ParseCheck
Definition: io.h:373
CSHORT Size
Definition: io.h:369
ULONG CreateOptions
Definition: io.h:377
PVOID EaBuffer
Definition: io.h:380
ULONG EaLength
Definition: io.h:381
BOOLEAN QueryOnly
Definition: io.h:389
volatile LONG ReserveIrpInUse
Definition: io.h:504
KEVENT WaitEvent
Definition: io.h:505
Definition: io.h:428
PDEVICE_OBJECT DeviceObject
Definition: io.h:430
LIST_ENTRY ShutdownList
Definition: io.h:429
Definition: iotypes.h:189
uint16_t * PWSTR
Definition: typedefs.h:56
uint32_t * PULONG
Definition: typedefs.h:59
unsigned char * PBOOLEAN
Definition: typedefs.h:53
INT POOL_TYPE
Definition: typedefs.h:78
#define NTAPI
Definition: typedefs.h:36
uint16_t * PUSHORT
Definition: typedefs.h:56
uint32_t ULONG_PTR
Definition: typedefs.h:65
#define IN
Definition: typedefs.h:39
uint16_t * PWCHAR
Definition: typedefs.h:56
uint32_t ULONG
Definition: typedefs.h:59
#define OUT
Definition: typedefs.h:40
char CCHAR
Definition: typedefs.h:51
short CSHORT
Definition: umtypes.h:127
_Must_inspect_result_ _In_ WDFCOLLECTION _In_ WDFOBJECT Object
_Must_inspect_result_ _In_ WDFDMAENABLER _In_ _In_opt_ PWDF_OBJECT_ATTRIBUTES Attributes
_Must_inspect_result_ _In_ WDFDRIVER Driver
Definition: wdfcontrol.h:83
_In_ PDEVICE_OBJECT DeviceObject
Definition: wdfdevice.h:2055
_In_ WDFDEVICE _Out_ PWDF_DEVICE_STATE DeviceState
Definition: wdfdevice.h:1999
_Must_inspect_result_ _In_ WDFDEVICE _In_ ULONG _In_ ACCESS_MASK DesiredAccess
Definition: wdfdevice.h:2658
_Must_inspect_result_ _In_ WDFDEVICE _In_ DEVICE_REGISTRY_PROPERTY _In_ _Strict_type_match_ POOL_TYPE PoolType
Definition: wdfdevice.h:3815
_In_ WDFREQUEST _In_ WDFFILEOBJECT FileObject
Definition: wdfdevice.h:550
_Must_inspect_result_ _In_ WDFDEVICE _In_ PCUNICODE_STRING SymbolicLinkName
Definition: wdfdevice.h:3739
_Must_inspect_result_ _In_ WDFDEVICE _In_ PCUNICODE_STRING KeyName
Definition: wdfdevice.h:2699
_Must_inspect_result_ _In_ WDFDEVICE _In_ DEVICE_REGISTRY_PROPERTY _In_ ULONG BufferLength
Definition: wdfdevice.h:3771
_In_ UCHAR _In_ UCHAR MinorFunction
Definition: wdfdevice.h:1699
_Must_inspect_result_ _In_ PDRIVER_OBJECT _In_ PCUNICODE_STRING RegistryPath
Definition: wdfdriver.h:215
_Must_inspect_result_ _In_ PDRIVER_OBJECT DriverObject
Definition: wdfdriver.h:213
_Must_inspect_result_ _In_ WDFDEVICE _In_ PWDF_INTERRUPT_CONFIG _In_opt_ PWDF_OBJECT_ATTRIBUTES _Out_ WDFINTERRUPT * Interrupt
Definition: wdfinterrupt.h:379
_In_ WDFIOTARGET _In_ _Strict_type_match_ WDF_IO_TARGET_SENT_IO_ACTION Action
Definition: wdfiotarget.h:510
_Must_inspect_result_ _In_ WDFOBJECT _In_ CONST GUID * Guid
Definition: wdfobject.h:762
_Must_inspect_result_ _In_ PWDFDEVICE_INIT _In_ PCUNICODE_STRING _In_ PCUNICODE_STRING _In_ LCID LocaleId
Definition: wdfpdo.h:437
_Must_inspect_result_ _In_opt_ WDFKEY _In_ PCUNICODE_STRING _In_ ACCESS_MASK _In_ ULONG CreateOptions
Definition: wdfregistry.h:118
_Must_inspect_result_ _In_opt_ WDFKEY ParentKey
Definition: wdfregistry.h:69
_Must_inspect_result_ _In_ WDFKEY _In_ PCUNICODE_STRING ValueName
Definition: wdfregistry.h:243
_In_ WDFREQUEST _In_ PIO_STACK_LOCATION Stack
Definition: wdfrequest.h:639
_In_ WDFREQUEST _In_ NTSTATUS _In_ ULONG_PTR Information
Definition: wdfrequest.h:1049
_Must_inspect_result_ _In_ WDFIORESREQLIST _In_opt_ PWDF_OBJECT_ATTRIBUTES _Out_ WDFIORESLIST * ResourceList
Definition: wdfresource.h:309
_In_ WDFIORESREQLIST RequirementsList
Definition: wdfresource.h:65
_In_ USHORT _In_ ULONG _In_ PSOCKADDR _In_ PSOCKADDR _Reserved_ ULONG _In_opt_ PVOID _In_opt_ const WSK_CLIENT_CONNECTION_DISPATCH _In_opt_ PEPROCESS _In_opt_ PETHREAD _In_opt_ PSECURITY_DESCRIPTOR SecurityDescriptor
Definition: wsk.h:191
struct LOOKASIDE_ALIGN _GENERAL_LOOKASIDE GENERAL_LOOKASIDE
FAST_MUTEX
Definition: extypes.h:17
_In_opt_ PDEVICE_OBJECT _In_ ULONG _Outptr_result_nullonfailure_ _At_ * SymbolicLinkList(return==0, __drv_allocatesMem(Mem))) PZZWSTR *SymbolicLinkList
_In_ CONST GUID * InterfaceClassGuid
Definition: iofuncs.h:1136
VOID(NTAPI * PDRIVER_REINITIALIZE)(_In_ struct _DRIVER_OBJECT *DriverObject, _In_opt_ PVOID Context, _In_ ULONG Count)
Definition: iotypes.h:4455
IO_COMPLETION_ROUTINE * PIO_COMPLETION_ROUTINE
Definition: iotypes.h:2835
* PFILE_OBJECT
Definition: iotypes.h:1998
* PDEVICE_CAPABILITIES
Definition: iotypes.h:965
DRIVER_FS_NOTIFICATION * PDRIVER_FS_NOTIFICATION
Definition: iotypes.h:7361
enum _DEVICE_TEXT_TYPE DEVICE_TEXT_TYPE
enum _CREATE_FILE_TYPE CREATE_FILE_TYPE
ULONG * PPNP_DEVICE_STATE
Definition: iotypes.h:997
enum _DEVICE_RELATION_TYPE DEVICE_RELATION_TYPE
IO_WORKITEM_ROUTINE * PIO_WORKITEM_ROUTINE
Definition: iotypes.h:515
CCHAR KPROCESSOR_MODE
Definition: ketypes.h:7
_In_opt_ PVOID _In_opt_ PVOID SystemArgument1
Definition: ketypes.h:688
_In_opt_ PVOID _In_opt_ PVOID _In_opt_ PVOID SystemArgument2
Definition: ketypes.h:689
_In_ PEPROCESS _In_ KPROCESSOR_MODE AccessMode
Definition: mmfuncs.h:396
_Inout_opt_ PVOID Parameter
Definition: rtltypes.h:323
_In_ KPROCESSOR_MODE PreviousMode
Definition: sefuncs.h:103
_In_opt_ PVOID _In_opt_ PUNICODE_STRING _In_ PSECURITY_DESCRIPTOR _In_ PACCESS_STATE AccessState
Definition: sefuncs.h:417
_In_ PSECURITY_SUBJECT_CONTEXT _In_ BOOLEAN _In_ ACCESS_MASK _In_ ACCESS_MASK _Outptr_opt_ PPRIVILEGE_SET _In_ PGENERIC_MAPPING _In_ KPROCESSOR_MODE _Out_ PACCESS_MASK GrantedAccess
Definition: sefuncs.h:20
SECURITY_OPERATION_CODE
Definition: setypes.h:170
unsigned char UCHAR
Definition: xmlstorage.h:181
char CHAR
Definition: xmlstorage.h:175
#define const
Definition: zconf.h:233