NTOSKRNL.FSRtl MDL stubs added.
[reactos.git] / reactos / include / ddk / iofuncs.h
1 /* $Id: iofuncs.h,v 1.6 2000/03/05 19:17:37 ea Exp $ */
2 /* IO MANAGER ***************************************************************/
3
4 BOOLEAN
5 IoRaiseInformationalHardError (
6 NTSTATUS ErrorStatus,
7 PUNICODE_STRING String,
8 PKTHREAD Thread
9 );
10
11
12 /*
13 * FUNCTION: Registers the driver with WMI
14 * ARGUMENTS:
15 * DeviceObject = Device to register
16 * Action = Action to take
17 * RETURNS: Status (?)
18 */
19 //NTSTATUS IoWMIRegistrationControl(DeviceObject, WMIREGACTION Action);
20
21 /*
22 * FUNCTION: Synchronizes cancelable-state transistions for IRPs in a
23 * multiprocessor-safe way
24 * ARGUMENTS:
25 * Irpl = Variable to store the current IRQ level
26 */
27 VOID
28 IoAcquireCancelSpinLock (
29 PKIRQL Irpl
30 );
31
32 typedef
33 IO_ALLOCATION_ACTION
34 (*PDRIVER_CONTROL) (
35 PDEVICE_OBJECT DeviceObject,
36 PIRP irp,
37 PVOID MapRegisterBase,
38 PVOID Context
39 );
40
41 /*
42 * FUNCTION: Allocates an adaptor object for a DMA operation on the target
43 * device
44 * ARGUMENTS:
45 * Adaptor = Adapter channel or busmaster adapter to be allocated
46 * DeviceObject = Target device for DMA
47 * NumberOfMapRegisters = Number of map registers
48 * ExecutionRoutine = Routine to be called when the adaptor is
49 * available
50 * Context = driver defined contex that will be passed to the
51 * execution routine
52 * RETURNS: Success or failure code
53 */
54 NTSTATUS
55 IoAllocateAdapterChannel (
56 PADAPTER_OBJECT AdaperObject,
57 PDEVICE_OBJECT DeviceObject,
58 ULONG NumberOfMapRegisters,
59 PDRIVER_CONTROL ExecutionRoutine,
60 PVOID Context
61 );
62
63 /*
64 * FUNCTION: Sets up a call to a driver supplied controller object as
65 * soon as it is available
66 * ARGUMENTS:
67 * ControllerObject = Driver created controller object
68 * DeviceObject = target device
69 * ExecutionObject = Routine to be called
70 * Context = Driver determined context to be based to the routine
71 */
72 VOID
73 IoAllocateController (
74 PCONTROLLER_OBJECT ControllerObject,
75 PDEVICE_OBJECT DeviceObject,
76 PDRIVER_CONTROL ExecutionRoutine,
77 PVOID Context
78 );
79
80 /*
81 * FUNCTION: Allocates an error log packet
82 * ARGUMENTS:
83 * IoObject = Object which found the error
84 * EntrySize = Size in bytes of the packet to be allocated
85 * RETURNS: On success a pointer to the allocated packet
86 * On failure returns NULL
87 */
88 PVOID
89 IoAllocateErrorLogEntry (
90 PVOID IoObject,
91 UCHAR EntrySize
92 );
93
94 /*
95 * FUNCTION: Allocates an IRP
96 * ARGUMENTS:
97 * StackSize = number of stack locations to allocate
98 * ChargeQuota = Who knows
99 * RETURNS: On success the allocated IRP
100 * On failure NULL
101 */
102 PIRP
103 IoAllocateIrp (
104 CCHAR StackSize,
105 BOOLEAN ChargeQuota
106 );
107
108 /*
109 * FUNCTION: Allocates an MDL large enough to map the supplied buffer
110 * ARGUMENTS:
111 * VirtualAddress = base virtual address of the buffer to be mapped
112 * Length = length of the buffer to be mapped
113 * SecondaryBuffer = Whether the buffer is primary or secondary
114 * ChargeQuota = Charge non-paged pool quota to current thread
115 * Irp = Optional irp to be associated with the MDL
116 * RETURNS: On the success the allocated MDL
117 * On failure NULL
118 */
119 PMDL
120 IoAllocateMdl (
121 PVOID VirtualAddress,
122 ULONG Length,
123 BOOLEAN SecondaryBuffer,
124 BOOLEAN ChargeQuota,
125 PIRP Irp
126 );
127
128 /*
129 * FUNCTION: Creates a symbolic link between the ARC name of a physical
130 * device and the name of the corresponding device object
131 * ARGUMENTS:
132 * ArcName = ARC name of the device
133 * DeviceName = Name of the device object
134 */
135 VOID
136 IoAssignArcName (
137 PUNICODE_STRING ArcName,
138 PUNICODE_STRING DeviceName
139 );
140
141 enum
142 {
143 IO_NO_INCREMENT,
144 };
145
146 /*
147 * FUNCTION: Takes a list of requested hardware resources and allocates them
148 * ARGUMENTS:
149 * RegisterPath =
150 * DriverClassName =
151 * DriverObject = Driver object passed to the DriverEntry routine
152 * DeviceObject =
153 * RequestedResources = List of resources
154 * RETURNS:
155 */
156 NTSTATUS
157 IoAssignResources (
158 PUNICODE_STRING RegistryPath,
159 PUNICODE_STRING DriverClassName,
160 PDRIVER_OBJECT DriverObject,
161 PDEVICE_OBJECT DeviceObject,
162 PIO_RESOURCE_REQUIREMENTS_LIST RequestedResources,
163 PCM_RESOURCE_LIST * AllocatedResources
164 );
165
166 /*
167 * FUNCTION: Attaches the callers device object to a named target device
168 * ARGUMENTS:
169 * SourceDevice = caller's device
170 * TargetDevice = Name of the target device
171 * AttachedDevice = Caller allocated storage. On return contains
172 * a pointer to the target device
173 * RETURNS: Success or failure code
174 */
175 NTSTATUS
176 IoAttachDevice (
177 PDEVICE_OBJECT SourceDevice,
178 PUNICODE_STRING TargetDevice,
179 PDEVICE_OBJECT * AttachedDevice
180 );
181
182 /*
183 * FUNCTION: Obsolete
184 * ARGUMENTS:
185 * SourceDevice = device to attach
186 * TargetDevice = device to be attached to
187 * RETURNS: Success or failure code
188 */
189 NTSTATUS
190 IoAttachDeviceByPointer (
191 PDEVICE_OBJECT SourceDevice,
192 PDEVICE_OBJECT TargetDevice
193 );
194
195 /*
196 * FUNCTION: Attaches the callers device to the highest device in the chain
197 * ARGUMENTS:
198 * SourceDevice = caller's device
199 * TargetDevice = Device to attach
200 * RETURNS: On success the previously highest device
201 * On failure NULL
202 */
203 PDEVICE_OBJECT
204 IoAttachDeviceToDeviceStack (
205 PDEVICE_OBJECT SourceDevice,
206 PDEVICE_OBJECT TargetDevice
207 );
208
209 /*
210 * FUNCTION: Builds a irp to be sent to lower level drivers
211 * ARGUMENTS:
212 * MajorFunction = Major function code to be set in the IRP
213 * DeviceObject = Next lower device object
214 * Buffer = Buffer (only required for some major function codes)
215 * Length = Length in bytes of the buffer
216 * StartingOffset = Starting offset on the target device
217 * IoStatusBlock = Storage for status about the operation (optional)
218 * RETURNS: On success the IRP allocated
219 * On failure NULL
220 */
221 PIRP
222 IoBuildAsynchronousFsdRequest (
223 ULONG MajorFunction,
224 PDEVICE_OBJECT DeviceObject,
225 PVOID Buffer,
226 ULONG Length,
227 PLARGE_INTEGER StartingOffset,
228 PIO_STATUS_BLOCK IoStatusBlock
229 );
230
231 /*
232 * FUNCTION: Allocates and sets up an IRP for a device control request
233 * ARGUMENTS:
234 * IoControlCode = Type of request
235 * DeviceObject = Target device
236 * InputBuffer = Optional input buffer to the driver
237 * InputBufferLength = Length of the input buffer
238 * OutputBuffer = Optional output buffer
239 * OutputBufferLength = Length of the output buffer
240 * InternalDeviceIoControl = TRUE if the request is internal
241 * Event = Initialized event for the caller to wait for the request
242 * to be completed
243 * IoStatusBlock = I/O status block to be set when the request is
244 * completed
245 * RETURNS: Returns the IRP created
246 */
247 PIRP
248 IoBuildDeviceIoControlRequest (
249 ULONG IoControlCode,
250 PDEVICE_OBJECT DeviceObject,
251 PVOID InputBuffer,
252 ULONG InputBufferLength,
253 PVOID OutputBuffer,
254 ULONG OutputBufferLength,
255 BOOLEAN InternalDeviceIoControl,
256 PKEVENT Event,
257 PIO_STATUS_BLOCK IoStatusBlock
258 );
259
260
261 VOID
262 IoBuildPartialMdl (
263 PMDL SourceMdl,
264 PMDL TargetMdl,
265 PVOID VirtualAddress,
266 ULONG Length
267 );
268
269 PIRP
270 IoBuildSynchronousFsdRequest (
271 ULONG MajorFunction,
272 PDEVICE_OBJECT DeviceObject,
273 PVOID Buffer,
274 ULONG Length,
275 PLARGE_INTEGER StartingOffset,
276 PKEVENT Event,
277 PIO_STATUS_BLOCK IoStatusBlock
278 );
279
280 /*
281 * FUNCTION: Sends an irp to the next lower driver
282 */
283 NTSTATUS
284 IoCallDriver (
285 PDEVICE_OBJECT DeviceObject,
286 PIRP irp
287 );
288
289 BOOLEAN
290 IoCancelIrp (
291 PIRP Irp
292 );
293
294 NTSTATUS
295 IoCheckShareAccess (
296 ACCESS_MASK DesiredAccess,
297 ULONG DesiredShareAccess,
298 PFILE_OBJECT FileObject,
299 PSHARE_ACCESS ShareAccess,
300 BOOLEAN Update
301 );
302
303 /*
304 * FUNCTION: Indicates the caller has finished all processing for a given
305 * I/O request and is returning the given IRP to the I/O manager
306 * ARGUMENTS:
307 * Irp = Irp to be cancelled
308 * PriorityBoost = Increment by which to boost the priority of the
309 * thread making the request
310 */
311 VOID
312 IoCompleteRequest (
313 PIRP Irp,
314 CCHAR PriorityBoost
315 );
316
317 NTSTATUS
318 IoConnectInterrupt (
319 PKINTERRUPT * InterruptObject,
320 PKSERVICE_ROUTINE ServiceRoutine,
321 PVOID ServiceContext,
322 PKSPIN_LOCK SpinLock,
323 ULONG Vector,
324 KIRQL Irql,
325 KIRQL SynchronizeIrql,
326 KINTERRUPT_MODE InterruptMode,
327 BOOLEAN ShareVector,
328 KAFFINITY ProcessorEnableMask,
329 BOOLEAN FloatingSave
330 );
331
332 PCONTROLLER_OBJECT
333 IoCreateController (
334 ULONG Size
335 );
336
337 /*
338 * FUNCTION: Allocates memory for and intializes a device object for use for
339 * a driver
340 * ARGUMENTS:
341 * DriverObject : Driver object passed by iomgr when the driver was
342 * loaded
343 * DeviceExtensionSize : Number of bytes for the device extension
344 * DeviceName : Unicode name of device
345 * DeviceType : Device type
346 * DeviceCharacteristics : Bit mask of device characteristics
347 * Exclusive : True if only one thread can access the device at a
348 * time
349 * RETURNS:
350 * Success or failure
351 * DeviceObject : Contains a pointer to allocated device object
352 * if the call succeeded
353 * NOTES: See the DDK documentation for more information
354 */
355 NTSTATUS
356 IoCreateDevice (
357 PDRIVER_OBJECT DriverObject,
358 ULONG DeviceExtensionSize,
359 PUNICODE_STRING DeviceName,
360 DEVICE_TYPE DeviceType,
361 ULONG DeviceCharacteristics,
362 BOOLEAN Exclusive,
363 PDEVICE_OBJECT * DeviceObject
364 );
365
366 NTSTATUS
367 STDCALL
368 IoCreateFile (
369 OUT PHANDLE FileHandle,
370 IN ACCESS_MASK DesiredAccess,
371 IN POBJECT_ATTRIBUTES ObjectAttributes,
372 OUT PIO_STATUS_BLOCK IoStatusBlock,
373 IN PLARGE_INTEGER AllocationSize OPTIONAL,
374 IN ULONG FileAttributes,
375 IN ULONG ShareAccess,
376 IN ULONG CreateDisposition,
377 IN ULONG CreateOptions,
378 IN PVOID EaBuffer OPTIONAL,
379 IN ULONG EaLength,
380 IN CREATE_FILE_TYPE CreateFileType,
381 IN ULONG ExtraCreateParameters,
382 IN ULONG Options
383 );
384 PKEVENT
385 IoCreateNotificationEvent (
386 PUNICODE_STRING EventName,
387 PHANDLE EventHandle
388 );
389
390 NTSTATUS
391 STDCALL
392 IoCreateSymbolicLink (
393 PUNICODE_STRING SymbolicLinkName,
394 PUNICODE_STRING DeviceName
395 );
396
397 PKEVENT
398 IoCreateSynchronizationEvent (
399 PUNICODE_STRING EventName,
400 PHANDLE EventHandle
401 );
402
403 NTSTATUS
404 STDCALL
405 IoCreateUnprotectedSymbolicLink (
406 PUNICODE_STRING SymbolicLinkName,
407 PUNICODE_STRING DeviceName
408 );
409
410
411 VOID
412 IoDeassignArcName (
413 PUNICODE_STRING ArcName
414 );
415
416 VOID
417 IoDeleteController (
418 PCONTROLLER_OBJECT ControllerObject
419 );
420
421 VOID
422 IoDeleteDevice (
423 PDEVICE_OBJECT DeviceObject
424 );
425
426 NTSTATUS
427 STDCALL
428 IoDeleteSymbolicLink (
429 PUNICODE_STRING SymbolicLinkName
430 );
431
432 VOID
433 IoDetachDevice (
434 PDEVICE_OBJECT TargetDevice
435 );
436
437 VOID
438 IoDisconnectInterrupt (
439 PKINTERRUPT InterruptObject
440 );
441
442 BOOLEAN
443 IoFlushAdapterBuffers (
444 PADAPTER_OBJECT AdapterObject,
445 PMDL Mdl,
446 PVOID MapRegisterBase,
447 PVOID CurrentVa,
448 ULONG Length,
449 BOOLEAN WriteToDevice
450 );
451
452 VOID
453 IoFreeAdapterChannel (
454 PADAPTER_OBJECT AdapterObject
455 );
456
457 VOID
458 IoFreeController (
459 PCONTROLLER_OBJECT ControllerObject
460 );
461
462 VOID
463 IoFreeIrp (
464 PIRP Irp
465 );
466
467 VOID
468 IoFreeMapRegisters (
469 PADAPTER_OBJECT AdapterObject,
470 PVOID MapRegisterBase,
471 ULONG NumberOfMapRegisters
472 );
473
474 VOID
475 IoFreeMdl (
476 PMDL Mdl
477 );
478 PDEVICE_OBJECT
479 STDCALL
480 IoGetBaseFileSystemDeviceObject (
481 IN PFILE_OBJECT FileObject
482 );
483 PCONFIGURATION_INFORMATION
484 IoGetConfigurationInformation (VOID);
485
486
487 /*
488 * FUNCTION: Returns a pointer to the callers stack location in the irp
489 */
490 PIO_STACK_LOCATION
491 IoGetCurrentIrpStackLocation (
492 IRP * irp
493 );
494
495 struct _EPROCESS *
496 IoGetCurrentProcess (VOID);
497
498 NTSTATUS
499 IoGetDeviceObjectPointer (
500 PUNICODE_STRING ObjectName,
501 ACCESS_MASK DesiredAccess,
502 PFILE_OBJECT * FileObject,
503 PDEVICE_OBJECT * DeviceObject
504 );
505
506 PDEVICE_OBJECT
507 IoGetDeviceToVerify (
508 PETHREAD Thread
509 );
510
511 PGENERIC_MAPPING
512 IoGetFileObjectGenericMapping (VOID);
513
514 ULONG
515 IoGetFunctionCodeFromCtlCode (
516 ULONG ControlCode
517 );
518
519 PVOID
520 IoGetInitialStack (VOID);
521
522 /*
523 * FUNCTION:
524 */
525 PIO_STACK_LOCATION
526 IoGetNextIrpStackLocation (
527 IRP * irp
528 );
529
530 PDEVICE_OBJECT
531 STDCALL
532 IoGetRelatedDeviceObject (
533 PFILE_OBJECT FileObject
534 );
535
536 VOID
537 IoInitializeDpcRequest (
538 PDEVICE_OBJECT DeviceObject,
539 PIO_DPC_ROUTINE DpcRoutine
540 );
541
542 /*
543 * FUNCTION: Initalizes an irp allocated by the caller
544 * ARGUMENTS:
545 * Irp = IRP to initalize
546 * PacketSize = Size in bytes of the IRP
547 * StackSize = Number of stack locations in the IRP
548 */
549 VOID
550 IoInitializeIrp (
551 PIRP Irp,
552 USHORT PacketSize,
553 CCHAR StackSize
554 );
555
556 NTSTATUS
557 IoInitializeTimer (
558 PDEVICE_OBJECT DeviceObject,
559 PIO_TIMER_ROUTINE TimerRoutine,
560 PVOID Context
561 );
562
563 BOOLEAN
564 IoIsErrorUserInduced (
565 NTSTATUS Status
566 );
567
568 BOOLEAN
569 IoIsTotalDeviceFailure (
570 NTSTATUS Status
571 );
572
573 PIRP
574 IoMakeAssociatedIrp (
575 PIRP Irp,
576 CCHAR StackSize
577 );
578
579 PHYSICAL_ADDRESS
580 IoMapTransfer (
581 PADAPTER_OBJECT AdapterObject,
582 PMDL Mdl,
583 PVOID MapRegisterBase,
584 PVOID CurrentVa,
585 PULONG Length,
586 BOOLEAN WriteToDevice
587 );
588
589 /*
590 * FUNCTION: Marks an IRP as pending
591 * ARGUMENTS:
592 * Irp = Irp to mark
593 * NOTE: If a driver doesn't complete the irp in its dispatch routine it
594 * must mark it pending otherwise the I/O manager will complete it on
595 * return from the dispatch routine.
596 */
597 VOID
598 IoMarkIrpPending (
599 PIRP Irp
600 );
601
602 NTSTATUS
603 IoQueryDeviceDescription (
604 PINTERFACE_TYPE BusType,
605 PULONG BusNumber,
606 PCONFIGURATION_TYPE ControllerType,
607 PULONG ControllerNumber,
608 PCONFIGURATION_TYPE PeripheralType,
609 PULONG PeripheralNumber,
610 PIO_QUERY_DEVICE_ROUTINE CalloutRoutine,
611 PVOID Context
612 );
613
614 VOID
615 IoRaiseHardError (
616 PIRP Irp,
617 PVPB Vpb,
618 PDEVICE_OBJECT RealDeviceObject
619 );
620
621 BOOLEAN
622 IoRaiseHardInformationalError (
623 NTSTATUS ErrorStatus,
624 PUNICODE_STRING String,
625 PKTHREAD Thread
626 );
627
628 NTSTATUS
629 IoReadPartitionTable (
630 PDEVICE_OBJECT DeviceObject,
631 ULONG SectorSize,
632 BOOLEAN ReturnedRecognizedPartitions,
633 struct _DRIVE_LAYOUT_INFORMATION ** PBuffer
634 );
635
636 VOID
637 IoRegisterDriverReinitialization (
638 PDRIVER_OBJECT DriverObject,
639 PDRIVER_REINITIALIZE ReinitRoutine,
640 PVOID Context
641 );
642
643 NTSTATUS
644 IoRegisterShutdownNotification (
645 PDEVICE_OBJECT DeviceObject
646 );
647
648 VOID
649 IoReleaseCancelSpinLock (
650 KIRQL Irql
651 );
652
653 VOID
654 IoRemoveShareAccess (
655 PFILE_OBJECT FileObject,
656 PSHARE_ACCESS ShareAccess
657 );
658
659 NTSTATUS
660 IoReportResourceUsage (
661 PUNICODE_STRING DriverClassName,
662 PDRIVER_OBJECT DriverObject,
663 PCM_RESOURCE_LIST DriverList,
664 ULONG DriverListSize,
665 PDEVICE_OBJECT DeviceObject,
666 PCM_RESOURCE_LIST DeviceList,
667 ULONG DeviceListSize,
668 BOOLEAN OverrideConflict,
669 PBOOLEAN ConflictDetected
670 );
671
672 VOID
673 IoRequestDpc (
674 PDEVICE_OBJECT DeviceObject,
675 PIRP Irp,
676 PVOID Context
677 );
678
679 PDRIVER_CANCEL
680 IoSetCancelRoutine (
681 PIRP Irp,
682 PDRIVER_CANCEL CancelRoutine
683 );
684
685 VOID
686 IoSetCompletionRoutine (
687 PIRP Irp,
688 PIO_COMPLETION_ROUTINE CompletionRoutine,
689 PVOID Context,
690 BOOLEAN InvokeOnSuccess,
691 BOOLEAN InvokeOnError,
692 BOOLEAN InvokeOnCancel
693 );
694
695 VOID
696 IoSetHardErrorOrVerifyDevice (
697 PIRP Irp,
698 PDEVICE_OBJECT DeviceObject
699 );
700
701 VOID
702 IoSetNextIrpStackLocation (
703 PIRP Irp
704 );
705
706 NTSTATUS
707 IoSetPartitionInformation (
708 PDEVICE_OBJECT DeviceObject,
709 ULONG SectorSize,
710 ULONG PartitionNumber,
711 ULONG PartitionType
712 );
713
714 VOID
715 IoSetShareAccess (
716 ACCESS_MASK DesiredAccess,
717 ULONG DesiredShareAccess,
718 PFILE_OBJECT FileObject,
719 PSHARE_ACCESS ShareAccess
720 );
721
722 /*
723 * FUNCTION: Determines the size of an IRP
724 * ARGUMENTS:
725 * StackSize = number of stack locations in the IRP
726 * RETURNS: The size of the IRP in bytes
727 */
728 USHORT
729 IoSizeOfIrp (
730 CCHAR StackSize
731 );
732
733 /*
734 * FUNCTION: Dequeues the next IRP from the device's associated queue and
735 * calls its StartIo routine
736 * ARGUMENTS:
737 * DeviceObject = Device object
738 * Cancelable = True if IRPs in the queue can be cancelled
739 */
740 VOID
741 IoStartNextPacket (
742 PDEVICE_OBJECT DeviceObject,
743 BOOLEAN Cancelable
744 );
745
746 VOID
747 IoStartNextPacketByKey (
748 PDEVICE_OBJECT DeviceObject,
749 BOOLEAN Cancelable,
750 ULONG Key
751 );
752
753 /*
754 * FUNCTION: Calls the drivers StartIO routine with the IRP or queues it if
755 * the device is busy
756 * ARGUMENTS:
757 * DeviceObject = Device to pass the IRP to
758 * Irp = Irp to be processed
759 * Key = Optional value for where to insert the IRP
760 * CancelFunction = Entry point for a driver supplied cancel function
761 */
762 VOID
763 IoStartPacket (
764 PDEVICE_OBJECT DeviceObject,
765 PIRP Irp,
766 PULONG Key,
767 PDRIVER_CANCEL CancelFunction
768 );
769
770 VOID
771 IoStartTimer (
772 PDEVICE_OBJECT DeviceObject
773 );
774
775 VOID
776 IoStopTimer (
777 PDEVICE_OBJECT DeviceObject
778 );
779
780 VOID
781 IoUnregisterShutdownNotification (
782 PDEVICE_OBJECT DeviceObject
783 );
784
785 VOID
786 IoUpdateShareAccess (
787 PFILE_OBJECT FileObject,
788 PSHARE_ACCESS ShareAccess
789 );
790
791 VOID
792 IoWriteErrorLogEntry (
793 PVOID ElEntry
794 );
795
796 NTSTATUS
797 IoWritePartitionTable (
798 PDEVICE_OBJECT DeviceObject,
799 ULONG SectorSize,
800 ULONG SectorsPerTrack,
801 ULONG NumberOfHeads,
802 struct _DRIVE_LAYOUT_INFORMATION* PBuffer
803 );
804
805
806 // Preliminary guess
807 NTKERNELAPI
808 NTSTATUS
809 IoQueryFileVolumeInformation (
810 IN PFILE_OBJECT FileObject,
811 IN FS_INFORMATION_CLASS FsInformationClass,
812 IN ULONG Length,
813 OUT PVOID FsInformation,
814 OUT PULONG ReturnedLength
815 );
816
817 NTKERNELAPI // confirmed - Undocumented because it does not require a valid file handle
818 NTSTATUS
819 IoQueryFileInformation (
820 IN PFILE_OBJECT FileObject,
821 IN FILE_INFORMATION_CLASS FileInformationClass,
822 IN ULONG Length,
823 OUT PVOID FileInformation,
824 OUT PULONG ReturnedLength
825 );
826
827 VOID
828 IoRegisterFileSystem (
829 PDEVICE_OBJECT DeviceObject
830 );
831
832 PDEVICE_OBJECT
833 IoGetAttachedDevice (
834 PDEVICE_OBJECT DeviceObject
835 );
836
837 PFILE_OBJECT
838 IoCreateStreamFileObject (
839 PFILE_OBJECT FileObject,
840 PDEVICE_OBJECT DeviceObject
841 );
842