ReactOS 0.4.16-dev-311-g9382aa2
|
#include <ntifs.h>
#include <pseh/pseh2.h>
#include <section_attribs.h>
#include <pshpack1.h>
#include <poppack.h>
Go to the source code of this file.
Classes | |
struct | _BIOS_PARAMETERS_BLOCK |
struct | _EXTENDED_BIOS_PARAMETERS_BLOCK |
struct | _BOOT_SECTOR |
struct | _NTFS_INFO |
struct | NTFSIDENTIFIER |
struct | DEVICE_EXTENSION |
struct | NTFS_CCB |
struct | NTFS_GLOBAL_DATA |
struct | NTFS_RECORD_HEADER |
struct | _FILE_RECORD_HEADER |
struct | NTFS_ATTR_RECORD |
struct | NTFS_ATTRIBUTE_LIST_ITEM |
struct | STANDARD_INFORMATION |
struct | ATTRIBUTE_LIST |
struct | FILENAME_ATTRIBUTE |
struct | INDEX_HEADER_ATTRIBUTE |
struct | INDEX_ROOT_ATTRIBUTE |
struct | INDEX_BUFFER |
struct | INDEX_ENTRY_ATTRIBUTE |
struct | _B_TREE_KEY |
struct | _B_TREE_FILENAME_NODE |
struct | B_TREE |
struct | VOLINFO_ATTRIBUTE |
struct | REPARSE_POINT_ATTRIBUTE |
struct | NTFS_IRP_CONTEXT |
struct | _NTFS_ATTR_CONTEXT |
struct | _FCB |
struct | _FIND_ATTR_CONTXT |
struct | FIXUP_ARRAY |
Variables | |
PNTFS_GLOBAL_DATA | NtfsGlobalData |
DRIVER_DISPATCH | NtfsFsdDispatch |
FAST_IO_CHECK_IF_POSSIBLE | NtfsFastIoCheckIfPossible |
FAST_IO_READ | NtfsFastIoRead |
FAST_IO_WRITE | NtfsFastIoWrite |
DRIVER_INITIALIZE | DriverEntry |
#define CACHEPAGESIZE | ( | pDeviceExt | ) |
typedef struct _B_TREE_KEY B_TREE_KEY |
typedef struct _BOOT_SECTOR BOOT_SECTOR |
typedef struct _FIND_ATTR_CONTXT FIND_ATTR_CONTXT |
typedef struct _NTFS_INFO NTFS_INFO |
typedef struct DEVICE_EXTENSION NTFS_VCB |
typedef struct ATTRIBUTE_LIST * PATTRIBUTE_LIST |
typedef enum ATTRIBUTE_TYPE * PATTRIBUTE_TYPE |
typedef struct _B_TREE_FILENAME_NODE * PB_TREE_FILENAME_NODE |
typedef struct _B_TREE_KEY * PB_TREE_KEY |
typedef struct _BOOT_SECTOR * PBOOT_SECTOR |
typedef struct DEVICE_EXTENSION * PDEVICE_EXTENSION |
typedef struct _FILE_RECORD_HEADER * PFILE_RECORD_HEADER |
typedef struct FILENAME_ATTRIBUTE * PFILENAME_ATTRIBUTE |
typedef struct _FIND_ATTR_CONTXT * PFIND_ATTR_CONTXT |
typedef struct FIXUP_ARRAY * PFIXUP_ARRAY |
typedef struct INDEX_BUFFER * PINDEX_BUFFER |
typedef struct INDEX_ROOT_ATTRIBUTE * PINDEX_ROOT_ATTRIBUTE |
typedef struct _NTFS_ATTR_CONTEXT * PNTFS_ATTR_CONTEXT |
typedef struct NTFS_ATTR_RECORD * PNTFS_ATTR_RECORD |
typedef struct NTFS_GLOBAL_DATA * PNTFS_GLOBAL_DATA |
typedef struct _NTFS_INFO * PNTFS_INFO |
typedef struct NTFS_IRP_CONTEXT * PNTFS_IRP_CONTEXT |
typedef struct NTFS_RECORD_HEADER * PNTFS_RECORD_HEADER |
typedef struct DEVICE_EXTENSION * PNTFS_VCB |
typedef struct NTFSIDENTIFIER * PNTFSIDENTIFIER |
typedef struct STANDARD_INFORMATION * PSTANDARD_INFORMATION |
typedef struct VOLINFO_ATTRIBUTE * PVOLINFO_ATTRIBUTE |
Definition at line 159 of file ntfs.h.
NTSTATUS AddBitmap | ( | PNTFS_VCB | Vcb, |
PFILE_RECORD_HEADER | FileRecord, | ||
PNTFS_ATTR_RECORD | AttributeAddress, | ||
PCWSTR | Name, | ||
USHORT | NameLength | ||
) |
Definition at line 72 of file attrib.c.
Referenced by DECLARE_INTERFACE_(), CFontsDialog::InitToolbar(), and UpdateIndexAllocation().
NTSTATUS AddData | ( | PFILE_RECORD_HEADER | FileRecord, |
PNTFS_ATTR_RECORD | AttributeAddress | ||
) |
Definition at line 160 of file attrib.c.
Referenced by DECLARE_INTERFACE_(), and NtfsCreateFileRecord().
NTSTATUS AddFileName | ( | PFILE_RECORD_HEADER | FileRecord, |
PNTFS_ATTR_RECORD | AttributeAddress, | ||
PDEVICE_EXTENSION | DeviceExt, | ||
PFILE_OBJECT | FileObject, | ||
BOOLEAN | CaseSensitive, | ||
PULONGLONG | ParentMftIndex | ||
) |
Definition at line 230 of file attrib.c.
Referenced by NtfsCreateDirectory(), and NtfsCreateFileRecord().
NTSTATUS AddFixupArray | ( | PDEVICE_EXTENSION | Vcb, |
PNTFS_RECORD_HEADER | Record | ||
) |
Definition at line 2603 of file mft.c.
Referenced by CreateIndexBufferFromBTreeNode(), UpdateFileRecord(), and UpdateIndexEntryFileNameSize().
NTSTATUS AddIndexAllocation | ( | PNTFS_VCB | Vcb, |
PFILE_RECORD_HEADER | FileRecord, | ||
PNTFS_ATTR_RECORD | AttributeAddress, | ||
PCWSTR | Name, | ||
USHORT | NameLength | ||
) |
Definition at line 388 of file attrib.c.
Referenced by UpdateIndexAllocation().
NTSTATUS AddIndexRoot | ( | PNTFS_VCB | Vcb, |
PFILE_RECORD_HEADER | FileRecord, | ||
PNTFS_ATTR_RECORD | AttributeAddress, | ||
PINDEX_ROOT_ATTRIBUTE | NewIndexRoot, | ||
ULONG | RootLength, | ||
PCWSTR | Name, | ||
USHORT | NameLength | ||
) |
Definition at line 495 of file attrib.c.
Referenced by NtfsCreateDirectory().
NTSTATUS AddNewMftEntry | ( | PFILE_RECORD_HEADER | FileRecord, |
PDEVICE_EXTENSION | DeviceExt, | ||
PULONGLONG | DestinationIndex, | ||
BOOLEAN | CanWait | ||
) |
Definition at line 2022 of file mft.c.
Referenced by AddNewMftEntry(), NtfsCreateDirectory(), and NtfsCreateFileRecord().
NTSTATUS AddRun | ( | PNTFS_VCB | Vcb, |
PNTFS_ATTR_CONTEXT | AttrContext, | ||
ULONG | AttrOffset, | ||
PFILE_RECORD_HEADER | FileRecord, | ||
ULONGLONG | NextAssignedCluster, | ||
ULONG | RunLength | ||
) |
Definition at line 599 of file attrib.c.
Referenced by SetNonResidentAttributeDataLength().
NTSTATUS AddStandardInformation | ( | PFILE_RECORD_HEADER | FileRecord, |
PNTFS_ATTR_RECORD | AttributeAddress | ||
) |
Definition at line 766 of file attrib.c.
Referenced by NtfsCreateDirectory(), and NtfsCreateFileRecord().
ULONGLONG AttributeAllocatedLength | ( | PNTFS_ATTR_RECORD | AttrRecord | ) |
Definition at line 249 of file mft.c.
Referenced by NtfsGetFileSize(), NtfsGetStreamInformation(), NtfsReadFile(), NtfsSetEndOfFile(), and NtfsWriteFile().
ULONGLONG AttributeDataLength | ( | PNTFS_ATTR_RECORD | AttrRecord | ) |
Definition at line 259 of file mft.c.
Referenced by AddNewMftEntry(), AllocateIndexNode(), BrowseIndexEntries(), FreeClusters(), IncreaseMftSize(), InternalReadNonResidentAttributes(), NtfsAddFilenameToDirectory(), NtfsAllocateClusters(), NtfsGetFileSize(), NtfsGetFreeClusters(), NtfsGetStreamInformation(), NtfsGetVolumeData(), NtfsReadFCBAttribute(), NtfsReadFile(), NtfsSetEndOfFile(), NtfsWriteFile(), PrintAllVCNs(), SetAttributeDataLength(), UpdateFileNameRecord(), UpdateIndexEntryFileNameSize(), and UpdateMftMirror().
BOOLEAN CompareFileName | ( | PUNICODE_STRING | FileName, |
PINDEX_ENTRY_ATTRIBUTE | IndexEntry, | ||
BOOLEAN | DirSearch, | ||
BOOLEAN | CaseSensitive | ||
) |
Definition at line 2650 of file mft.c.
Referenced by BrowseIndexEntries(), BrowseSubNodeIndexEntries(), and UpdateIndexEntryFileNameSize().
LONG CompareTreeKeys | ( | PB_TREE_KEY | Key1, |
PB_TREE_KEY | Key2, | ||
BOOLEAN | CaseSensitive | ||
) |
Definition at line 417 of file btree.c.
Referenced by NtfsInsertKey().
NTSTATUS ConvertDataRunsToLargeMCB | ( | PUCHAR | DataRun, |
PLARGE_MCB | DataRunsMCB, | ||
PULONGLONG | pNextVBN | ||
) |
Definition at line 825 of file attrib.c.
Referenced by PrepareAttributeContext().
NTSTATUS ConvertLargeMCBToDataRuns | ( | PLARGE_MCB | DataRunsMCB, |
PUCHAR | RunBuffer, | ||
ULONG | MaxBufferSize, | ||
PULONG | UsedBufferSize | ||
) |
Definition at line 896 of file attrib.c.
Referenced by AddRun(), FreeClusters(), ReadAttribute(), and WriteAttribute().
NTSTATUS CreateBTreeFromIndex | ( | PDEVICE_EXTENSION | Vcb, |
PFILE_RECORD_HEADER | FileRecordWithIndex, | ||
PNTFS_ATTR_CONTEXT | IndexRootContext, | ||
PINDEX_ROOT_ATTRIBUTE | IndexRoot, | ||
PB_TREE * | NewTree | ||
) |
Definition at line 682 of file btree.c.
Referenced by NtfsAddFilenameToDirectory().
Definition at line 348 of file btree.c.
Referenced by NtfsCreateDirectory().
NTSTATUS CreateIndexRootFromBTree | ( | PDEVICE_EXTENSION | DeviceExt, |
PB_TREE | Tree, | ||
ULONG | MaxIndexSize, | ||
PINDEX_ROOT_ATTRIBUTE * | IndexRoot, | ||
ULONG * | Length | ||
) |
Definition at line 910 of file btree.c.
Referenced by NtfsAddFilenameToDirectory(), and NtfsCreateDirectory().
Definition at line 966 of file attrib.c.
Referenced by ConvertDataRunsToLargeMCB(), FindRun(), GetLastClusterInDataRun(), NtfsDumpDataRuns(), PrepareAttributeContext(), PrintAttributeInfo(), ReadAttribute(), and WriteAttribute().
Definition at line 1089 of file btree.c.
Referenced by NtfsAddFilenameToDirectory().
Definition at line 1542 of file btree.c.
Referenced by CreateBTreeFromIndex(), NtfsAddFilenameToDirectory(), and NtfsCreateDirectory().
VOID DestroyBTreeNode | ( | PB_TREE_FILENAME_NODE | Node | ) |
Definition at line 1511 of file btree.c.
Referenced by CreateBTreeNodeFromIndexNode(), DestroyBTree(), and DestroyBTreeKey().
Definition at line 1622 of file btree.c.
Referenced by CreateIndexRootFromBTree(), DemoteBTreeRoot(), NtfsAddFilenameToDirectory(), NtfsInsertKey(), and UpdateIndexAllocation().
VOID DumpBTreeKey | ( | PB_TREE | Tree, |
PB_TREE_KEY | Key, | ||
ULONG | Number, | ||
ULONG | Depth | ||
) |
Definition at line 1549 of file btree.c.
Referenced by DumpBTreeNode().
VOID DumpBTreeNode | ( | PB_TREE | Tree, |
PB_TREE_FILENAME_NODE | Node, | ||
ULONG | Number, | ||
ULONG | Depth | ||
) |
Definition at line 1583 of file btree.c.
Referenced by DumpBTree(), DumpBTreeKey(), and SplitBTreeNode().
VOID EnumerAttribute | ( | PFILE_RECORD_HEADER | file, |
PDEVICE_EXTENSION | Vcb, | ||
PDEVICE_OBJECT | DeviceObject | ||
) |
NTSTATUS FindAttribute | ( | PDEVICE_EXTENSION | Vcb, |
PFILE_RECORD_HEADER | MftRecord, | ||
ULONG | Type, | ||
PCWSTR | Name, | ||
ULONG | NameLength, | ||
PNTFS_ATTR_CONTEXT * | AttrCtx, | ||
PULONG | Offset | ||
) |
Definition at line 131 of file mft.c.
Referenced by AddNewMftEntry(), AllocateIndexNode(), BrowseIndexEntries(), CreateBTreeFromIndex(), tinyxml2::XMLElement::FindAttribute(), FindAttribute(), FreeClusters(), GetVolumeBitmap(), IncreaseMftSize(), NtfsAddFilenameToDirectory(), NtfsAllocateClusters(), NtfsCreateFile(), NtfsDirFindFile(), NtfsFindMftRecord(), NtfsGetFileSize(), NtfsGetFreeClusters(), NtfsGetVolumeData(), NtfsReadFCBAttribute(), NtfsReadFile(), NtfsSetEndOfFile(), NtfsWriteFile(), tinyxml2::XMLElement::QueryBoolAttribute(), tinyxml2::XMLElement::QueryDoubleAttribute(), tinyxml2::XMLElement::QueryFloatAttribute(), tinyxml2::XMLElement::QueryIntAttribute(), tinyxml2::XMLElement::QueryUnsignedAttribute(), UpdateFileNameRecord(), UpdateIndexAllocation(), UpdateIndexEntryFileNameSize(), UpdateMftMirror(), and WriteAttribute().
VOID FindCloseAttribute | ( | PFIND_ATTR_CONTXT | Context | ) |
Definition at line 1465 of file attrib.c.
Referenced by FindAttribute(), GetFileNameFromRecord(), GetNfsVolumeData(), GetStandardInformationFromRecord(), NtfsDumpFileAttributes(), NtfsGetStreamInformation(), NtfsReadFile(), and NtfsWriteFile().
NTSTATUS FindFirstAttribute | ( | PFIND_ATTR_CONTXT | Context, |
PDEVICE_EXTENSION | Vcb, | ||
PFILE_RECORD_HEADER | FileRecord, | ||
BOOLEAN | OnlyResident, | ||
PNTFS_ATTR_RECORD * | Attribute | ||
) |
Definition at line 1383 of file attrib.c.
Referenced by FindAttribute(), GetFileNameFromRecord(), GetNfsVolumeData(), GetStandardInformationFromRecord(), NtfsDumpFileAttributes(), NtfsGetStreamInformation(), NtfsReadFile(), and NtfsWriteFile().
NTSTATUS FindFirstAttributeListItem | ( | PFIND_ATTR_CONTXT | Context, |
PNTFS_ATTRIBUTE_LIST_ITEM * | Item | ||
) |
Definition at line 1307 of file attrib.c.
Referenced by FindAttribute().
NTSTATUS FindNextAttribute | ( | PFIND_ATTR_CONTXT | Context, |
PNTFS_ATTR_RECORD * | Attribute | ||
) |
Definition at line 1431 of file attrib.c.
Referenced by FindAttribute(), GetFileNameFromRecord(), GetNfsVolumeData(), GetStandardInformationFromRecord(), NtfsDumpFileAttributes(), NtfsGetStreamInformation(), NtfsReadFile(), and NtfsWriteFile().
NTSTATUS FindNextAttributeListItem | ( | PFIND_ATTR_CONTXT | Context, |
PNTFS_ATTRIBUTE_LIST_ITEM * | Item | ||
) |
Definition at line 1321 of file attrib.c.
Referenced by FindAttribute().
NTSTATUS FixupUpdateSequenceArray | ( | PDEVICE_EXTENSION | Vcb, |
PNTFS_RECORD_HEADER | Record | ||
) |
Definition at line 1965 of file mft.c.
Referenced by BrowseSubNodeIndexEntries(), CreateBTreeNodeFromIndexNode(), PrintAllVCNs(), ReadFileRecord(), UpdateFileRecord(), and UpdateIndexEntryFileNameSize().
NTSTATUS FreeClusters | ( | PNTFS_VCB | Vcb, |
PNTFS_ATTR_CONTEXT | AttrContext, | ||
ULONG | AttrOffset, | ||
PFILE_RECORD_HEADER | FileRecord, | ||
ULONG | ClustersToFree | ||
) |
Definition at line 1057 of file attrib.c.
Referenced by FatExamineFatEntries(), GetDiskFreeSpaceW(), HandleNotify(), NtfsAllocateClusters(), NtfsGetFreeClusters(), and SetNonResidentAttributeDataLength().
ULONGLONG GetAllocationOffsetFromVCN | ( | PDEVICE_EXTENSION | DeviceExt, |
ULONG | IndexBufferSize, | ||
ULONGLONG | Vcn | ||
) |
Definition at line 1630 of file btree.c.
Referenced by CreateBTreeNodeFromIndexNode(), and UpdateIndexNode().
PFILENAME_ATTRIBUTE GetBestFileNameFromRecord | ( | PDEVICE_EXTENSION | Vcb, |
PFILE_RECORD_HEADER | FileRecord | ||
) |
Definition at line 1985 of file attrib.c.
Referenced by NtfsGetBothDirectoryInformation(), NtfsGetDirectoryInformation(), NtfsGetFullDirectoryInformation(), NtfsGetNamesInformation(), NtfsMakeFCBFromDirEntry(), NtfsMoonWalkID(), NtfsSetEndOfFile(), and NtfsWriteFile().
ULONG GetFileNameAttributeLength | ( | PFILENAME_ATTRIBUTE | FileNameAttribute | ) |
Definition at line 1978 of file attrib.c.
Referenced by CreateBTreeKeyFromFilename().
PFILENAME_ATTRIBUTE GetFileNameFromRecord | ( | PDEVICE_EXTENSION | Vcb, |
PFILE_RECORD_HEADER | FileRecord, | ||
UCHAR | NameType | ||
) |
Definition at line 1809 of file attrib.c.
Referenced by GetBestFileNameFromRecord(), NtfsGetBothDirectoryInformation(), and NtfsMakeRootFCB().
ULONGLONG GetIndexEntryVCN | ( | PINDEX_ENTRY_ATTRIBUTE | IndexEntry | ) |
Definition at line 1641 of file btree.c.
Referenced by BrowseIndexEntries(), BrowseSubNodeIndexEntries(), and SplitBTreeNode().
NTSTATUS GetLastClusterInDataRun | ( | PDEVICE_EXTENSION | Vcb, |
PNTFS_ATTR_RECORD | Attribute, | ||
PULONGLONG | LastCluster | ||
) |
Definition at line 1908 of file attrib.c.
GetPackedByteCount Returns the minimum number of bytes needed to represent the value of a 64-bit number. Used to encode data runs.
Definition at line 1846 of file attrib.c.
Referenced by ConvertLargeMCBToDataRuns().
ULONG GetSizeOfIndexEntries | ( | PB_TREE_FILENAME_NODE | Node | ) |
Definition at line 855 of file btree.c.
Referenced by NtfsAddFilenameToDirectory(), and NtfsInsertKey().
PSTANDARD_INFORMATION GetStandardInformationFromRecord | ( | PDEVICE_EXTENSION | Vcb, |
PFILE_RECORD_HEADER | FileRecord | ||
) |
Definition at line 1940 of file attrib.c.
Referenced by NtfsGetBothDirectoryInformation(), NtfsGetDirectoryInformation(), NtfsGetFullDirectoryInformation(), and NtfsMakeFCBFromDirEntry().
NTSTATUS InternalSetResidentAttributeLength | ( | PDEVICE_EXTENSION | DeviceExt, |
PNTFS_ATTR_CONTEXT | AttrContext, | ||
PFILE_RECORD_HEADER | FileRecord, | ||
ULONG | AttrOffset, | ||
ULONG | DataSize | ||
) |
Definition at line 542 of file mft.c.
Referenced by NtfsAddFilenameToDirectory(), and SetResidentAttributeDataLength().
PNTFS_ATTR_RECORD MoveAttributes | ( | PDEVICE_EXTENSION | DeviceExt, |
PNTFS_ATTR_RECORD | FirstAttributeToMove, | ||
ULONG | FirstAttributeOffset, | ||
ULONG_PTR | MoveTo | ||
) |
Definition at line 512 of file mft.c.
Referenced by AddRun(), and InternalSetResidentAttributeLength().
Definition at line 209 of file fcb.c.
Referenced by NtfsMakeFCBFromDirEntry(), and NtfsMakeRootFCB().
NTSTATUS NtfsAddFilenameToDirectory | ( | PDEVICE_EXTENSION | DeviceExt, |
ULONGLONG | DirectoryMftIndex, | ||
ULONGLONG | FileReferenceNumber, | ||
PFILENAME_ATTRIBUTE | FilenameAttribute, | ||
BOOLEAN | CaseSensitive | ||
) |
Definition at line 2192 of file mft.c.
Referenced by NtfsCreateDirectory(), and NtfsCreateFileRecord().
NTSTATUS NtfsAllocateClusters | ( | PDEVICE_EXTENSION | DeviceExt, |
ULONG | FirstDesiredCluster, | ||
ULONG | DesiredClusters, | ||
PULONG | FirstAssignedCluster, | ||
PULONG | AssignedClusters | ||
) |
NtfsAllocateClusters Allocates a run of clusters. The run allocated might be smaller than DesiredClusters.
Definition at line 105 of file volinfo.c.