2.3.55 FSCTL_QUERY_FILE_REGIONS Request
The FSCTL_QUERY_FILE_REGIONS request message requests that the server return a list of file regions, based on a specified usage parameter, for the file associated with the handle on which this FSCTL was invoked. This message contains an optional FILE_REGION_INPUT data element. If no FILE_REGION_INPUT parameter is specified, information for the entire size of the file is returned.
A FILE_REGION_INPUT data element is as follows.
|
|
|
|
|
|
|
|
|
|
1 |
|
|
|
|
|
|
|
|
|
2 |
|
|
|
|
|
|
|
|
|
3 |
|
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
FileOffset |
|||||||||||||||||||||||||||||||
... |
|||||||||||||||||||||||||||||||
Length |
|||||||||||||||||||||||||||||||
... |
|||||||||||||||||||||||||||||||
DesiredUsage |
|||||||||||||||||||||||||||||||
Reserved |
FileOffset (8 bytes): A 64-bit signed integer that contains the file offset, in bytes, of the start of a range of bytes in a file.
Length (8 bytes): A 64-bit signed integer that contains the size, in bytes, of the range.
DesiredUsage (4 bytes): A 32-bit unsigned integer that indicates usage parameters for this operation. The following table provides the currently defined usage parameters.
-
Value
Meaning
FILE_REGION_USAGE_VALID_CACHED_DATA
0x00000001
Information about the valid data length for the specified file and file range in the cache will be returned.<47>
FILE_REGION_USAGE_VALID_NONCACHED_DATA
0x00000002
Information about the valid data length for the specified file and file range on disk will be returned.<48>
All other values
If a FILE_REGION_INPUT object is specified in FSCTL_QUERY_FILE_REGION, then any other value will return STATUS_INVALID_PARAMETER.
Reserved (4 bytes): A 32-bit unsigned integer that is reserved. This field SHOULD be 0x00000000 and MUST be ignored.