2 * PROJECT: ReactOS Kernel
3 * LICENSE: GPL - See COPYING in the top level directory
4 * FILE: ntoskrnl/fsrtl/faulttol.c
5 * PURPOSE: Provides Fault Tolerance support for File System Drivers
6 * PROGRAMMERS: Alex Ionescu (alex.ionescu@reactos.org)
9 /* INCLUDES ******************************************************************/
16 /* PUBLIC FUNCTIONS **********************************************************/
19 * @name FsRtlBalanceReads
22 * The FsRtlBalanceReads routine sends an IRP to an FTDISK Driver
23 * requesting the driver to balance read requests across a mirror set.
26 * A pointer to an FTDISK Device Object.
28 * @return The NTSTATUS error code returned by the FTDISK Driver.
30 * @remarks FTDISK is a Software RAID Implementation.
35 FsRtlBalanceReads(PDEVICE_OBJECT TargetDevice
)
39 IO_STATUS_BLOCK IoStatusBlock
;
42 /* Initialize the Local Event */
43 KeInitializeEvent(&Event
, NotificationEvent
, FALSE
);
45 /* Build the special IOCTL */
46 Irp
= IoBuildDeviceIoControlRequest(FT_BALANCED_READ_MODE
,
55 if (!Irp
) return STATUS_INSUFFICIENT_RESOURCES
;
58 Status
= IoCallDriver(TargetDevice
, Irp
);
61 if (Status
== STATUS_PENDING
)
63 Status
= KeWaitForSingleObject(&Event
,
68 ASSERT(Status
== STATUS_SUCCESS
);
71 Status
= IoStatusBlock
.Status
;
74 /* Return the status */
79 * @name FsRtlSyncVolumes
82 * The FsRtlSyncVolumes routine is deprecated.
84 * @return Always returns STATUS_SUCCESS.
86 * @remarks Deprecated.
91 FsRtlSyncVolumes(ULONG Unknown0
,
95 /* Always return success */
96 return STATUS_SUCCESS
;