FAT*FindAndMarkAvailableCluster which have incorporated the setting of
EOF marker in the File Allocation Table for the returned cluster.
- Rewritten FAT32CountAvailableClusters, FAT32FindAndMarkAvailableCluster,
FAT16CountAvailableClusters and FAT16FindAndMarkAvailableCluster for
better performance. These functions were using one big loop for traversing
the FAT and had a block of code in the loop for requesting cache manger
for next chunk of FAT *if necessary* (which commonly wasn't the case).
Now it's changed to request always a whole FAT chunk and process it at once
in a nested loop.
- Cache last offset + cluster pair while reading/writing from/to file. This
ensures almost linear times when doing sequential reads/writes, because the
whole FAT traversing for the file is not done again for every request.
Previously there was code for this, but it was neither correctly used
nor working. It stored the last offset + cluster pair in file CCB structure
(that is unique for each opened file handle) and not FCB structure (which
is shared among all instances of the same file). This resulted in
inconsistent cluster + offset number when the file allocation chain was
changed (eg. by enlarging/shrinking the file), but since the cached offsets
weren't actully used it went unnoticed.
- Remove old hack from NextCluster and fix the call to it in VfatAddEntry.
Not much to say about it, there was an temporary hack in NextCluster and
with fixed VfatAddEntry it's now no longer needed.
- Add pointers to WriteCluster, FindAndMarkAvailableCluster and
GetNextCluster functions to device extension (set during mount) and use
them at appropriate locations. This avoids some nasty if's in the code
and causes some unnoticable performance improvment in the low-level
FAT code.
- Lock the directory FCB in VfatAddEntry while modifying it. This should
propably be done on more places, but it needs more investigations.
- Increase the file cache allocation size in VfatRead/VfatWrite. It boosts
the overall speed of the driver a lot.
svn path=/trunk/; revision=10344
- Allowed MmCreateVirtualMapping to create mappings for more than one page.
- Used invplg to invalidate a single tlb entry.
- Simplified the access to the page tables/directories.
svn path=/trunk/; revision=10332
Fixed subtle bug in miniport.c: if exactly one protocol is registered we
would skip it in MiniIndicateData because we took the .Flink value from the
list head, then compared CurrentEntry->Flink to the list head address.
svn path=/trunk/; revision=10307