FLT_PARAMETERS for IRP_MJ_FILE_SYSTEM_CONTROL union

Union component used when the MajorFunction field of the FLT_IO_PARAMETER_BLOCK structure for the operation is IRP_MJ_FILE_SYSTEM_CONTROL.

Syntax

typedef union _FLT_PARAMETERS {
  ...   ;
  union {
    struct {
      PVPB           Vpb;
      PDEVICE_OBJECT DeviceObject;
    } VerifyVolume;
    struct {
      ULONG                   OutputBufferLength;
      ULONG POINTER_ALIGNMENT InputBufferLength;
      ULONG POINTER_ALIGNMENT FsControlCode;
    } Common;
    struct {
      ULONG                    OutputBufferLength;
      ULONG POINTER_ALIGNMENT  InputBufferLength;
      ULONG POINTER_ALIGNMENT  FsControlCode;
      PVOID                    InputBuffer;
      PVOID                    OutputBuffer;
      PMDL                     OutputMdlAddress;
    } Neither;
    struct {
      ULONG                   OutputBufferLength;
      ULONG POINTER_ALIGNMENT InputBufferLength;
      ULONG POINTER_ALIGNMENT FsControlCode;
      PVOID                   SystemBuffer;
    } Buffered;
    struct {
      ULONG                   OutputBufferLength;
      ULONG POINTER_ALIGNMENT InputBufferLength;
      ULONG POINTER_ALIGNMENT FsControlCode;
      PVOID                   InputSystemBuffer;
      PVOID                   OutputBuffer;
      PMDL                    OutputMdlAddress;
    } Direct;
  } FileSystemControl;
  ...   ;
} FLT_PARAMETERS, *PFLT_PARAMETERS;

Members

FileSystemControl
Structure containing the following members.

VerifyVolume
Union component used for IRP_MN_VERIFY_VOLUME operations.

Vpb
Pointer to the volume parameter block (VPB) for the volume to be verified.

DeviceObject
Pointer to the device object for the volume to be verified.

Common
Union component used for all buffering methods for IRP_MN_KERNEL_CALL and IRP_MN_USER_FS_REQUEST operations.

OutputBufferLength
Length, in bytes, of the buffer that the Neither.OutputBuffer or Direct.OutputBuffer member points to.

InputBufferLength
Length, in bytes, of the buffer that the Neither.InputBuffer, Buffered.SystemBuffer, or Direct.InputSystemBuffer member points to.

FsControlCode
FSCTL function code to be passed to the file system, file system filter, or minifilter driver for the target device.

For detailed information about IOCTL and FSCTL requests, see Using I/O Control Codes in the Kernel Mode Architecture Guide and "Device Input and Output Control Codes" in the Microsoft Windows SDK documentation. (This resource may not be available in some languages and countries.)

Neither
Union component used for IRP_MN_KERNEL_CALL and IRP_MN_USER_FS_REQUEST operations when the buffering method is METHOD_NEITHER. For more information about buffering methods, see Defining I/O Control Codes in the Kernel Mode Architecture Guide. (This resource may not be available in some languages and countries.)

InputBuffer
User-mode virtual address of the input buffer that the original requester of the operation supplied. The I/O Manager and Filter Manager do not validate these addresses. To ensure that user-space addresses are valid, the minifilter must use routines such as ProbeForRead, ProbeForWrite, and MmProbeAndLockPages, enclosing all buffer references in try/except blocks. For more information, see Using Neither Buffered Nor Direct I/O and Errors in Referencing User-Space Addresses in the Kernel Mode Architecture Guide. (This resource may not be available in some languages and countries.)

OutputBuffer
User-mode virtual address of the output buffer that the original requester of the operation supplied. The I/O Manager and Filter Manager do not validate these addresses. To ensure that user-space addresses are valid, the minifilter must use routines such as ProbeForRead, ProbeForWrite, and MmProbeAndLockPages, enclosing all buffer references in try/except blocks. For more information, see Using Neither Buffered Nor Direct I/O and Errors in Referencing User-Space Addresses in the Kernel Mode Architecture Guide. (This resource may not be available in some languages and countries.)

OutputMdlAddress
Address of a memory descriptor list (MDL) that describes the buffer that the Neither.OutputBuffer member points to. This member is optional and can be NULL.

Buffered
Union component used for IRP_MN_KERNEL_CALL and IRP_MN_USER_FS_REQUEST operations when the buffering method is METHOD_BUFFERED. For more information about buffering methods, see Defining I/O Control Codes in the Kernel Mode Architecture Guide. (This resource may not be available in some languages and countries.)

SystemBuffer
Address of the system-allocated buffer for the operation. In METHOD_BUFFERED I/O, this buffer is used for both input and output. For more information, see Methods for Accessing Data Buffers in the Kernel Mode Architecture Guide. (This resource may not be available in some languages and countries.)

Direct
Union component used for IRP_MN_KERNEL_CALL and IRP_MN_USER_FS_REQUEST operations when the buffering method is METHOD_IN_DIRECT or METHOD_OUT_DIRECT. For more information about buffering methods, see Defining I/O Control Codes in the Kernel Mode Architecture Guide.

InputSystemBuffer
Address of the input buffer for the operation. This buffer is locked down by the operating system so that it is safe to access from kernel mode. For more information, see Methods for Accessing Data Buffers in the Kernel Mode Architecture Guide. (This resource may not be available in some languages and countries.)

OutputBuffer
User-mode virtual address of the output buffer that the original requester of the operation supplied. In direct I/O, unlike METHOD_NEITHER I/O, the operating system locks down this buffer so that it is safe to access from kernel mode, as long as the minifilter is in the same process context as the original requester of the I/O operation. (Otherwise it must call MmGetSystemAddressForMdlSafe to get the system address from the MDL that the OutputMdlAddress member points to.) For more information, see Using Direct I/O and Errors in Direct I/O in the Kernel Mode Architecture Guide. (This resource may not be available in some languages and countries.)

OutputMdlAddress
Address of an MDL that describes the buffer that the Direct.OutputBuffer member points to. This member is required and cannot be NULL.

Remarks

The FLT_PARAMETERS structure for IRP_MJ_FILE_SYSTEM_CONTROL operations contains the parameters for a file-system-control-information operation represented by a callback data (FLT_CALLBACK_DATA) structure. It is contained in an FLT_IO_PARAMETER_BLOCK structure.

IRP_MJ_FILE_SYSTEM_CONTROL is an IRP-based operation.

Requirements

Header

Fltkernel.h (include Fltkernel.h)

See also

FLT_CALLBACK_DATA

FLT_IO_PARAMETER_BLOCK

FLT_IS_FASTIO_OPERATION

FLT_IS_FS_FILTER_OPERATION

FLT_IS_IRP_OPERATION

FLT_PARAMETERS

FltFsControlFile

IoBuildAsynchronousFsdRequest

IoBuildSynchronousFsdRequest

IoVerifyVolume

IRP_MJ_FILE_SYSTEM_CONTROL

MmGetSystemAddressForMdlSafe

MmProbeAndLockPages

ProbeForRead

ProbeForWrite

ZwFsControlFile