56 SyncStatus
sync()
override;
58 uint64_t read(
File* pFile, uint64_t location, uint64_t size, uintptr_t buffer,
59 bool bCanBlock =
true);
60 uint64_t write(
File* pFile, uint64_t location, uint64_t size, uintptr_t buffer,
61 bool bCanBlock =
true);
62 void truncate(
File* pFile);
63 void fileAttributeChanged(
File* pFile);
64 void cacheDirectoryContents(
File* pFile);
65 void extend(
File* pFile,
size_t size);
73 const String& newName,
File* replaced)
override;
80 void cacheVolumeLabel();
83 bool readCluster(uint32_t block, uintptr_t buffer)
const;
92 bool readSectorBlock(uint32_t sec,
size_t size, uintptr_t buffer)
const;
103 bool setClusterEntry(uint32_t cluster, uint32_t value,
bool bLock =
true,
bool persist =
true);
114 bool syncFat(
bool bLock =
true);
115 bool invalidateFsInfoHints();
116 bool m_FsInfoInvalidated =
false;
117 uint8_t* getFatSector(uint32_t sector);
118 bool chainExtent(
File* file, uint32_t& count, uint32_t& last);
119 uint32_t fileClusterAt(
File*,
size_t);
120 uint64_t m_ChainRevision = 1;
121 bool truncateFile(
File* file);
124 bool trimFileAllocation(
FatFile*);
125 void publishSize(
File*,
size_t);
126 void unlinkNode(
File*);
127 void retireNode(
File*);
128 void moveNode(
File*, uint32_t, uint32_t);
129 bool isNodeUnlinked(
File*)
const;
130 void writeEntryAttributes(
File*,
Dir*,
bool creating =
false);
132 bool syncNodeAttributes(
File*);
133 bool syncNode(
File*);
142 bool syncPendingAttributes();
143 void movePendingAttributes(uint32_t oldCluster, uint32_t oldOffset, uint32_t newCluster,
145 void discardPendingAttributes(uint32_t cluster, uint32_t offset);
146 void clearPendingAttributes();
148 Time::Timestamp, Time::Timestamp);
149 void releaseFileState(
FatFile*);
150 uintptr_t fileIdentifier(uint32_t cluster, uint32_t offset);
151 uintptr_t fileIdentifierLocked(uint64_t slot);
153 bool drainFileStates(
bool checked =
false);
156 uint32_t directoryCluster = 0, directoryOffset = 0;
157 bool unlinked =
false;
162 void registerNode(
File*);
163 void releaseNode(
File*);
164 void moveNonFileNode(
File*, uint32_t, uint32_t);
165 void unlinkNonFileNode(
File*);
169 uintptr_t m_NextFileIdentifier = 0x10000000;
171 bool m_IoFailed =
false;
172 bool m_ShutdownComplete =
false;
173 bool m_MountedClean =
true;
174 bool ensureCapacity(
File* file,
size_t size);
175 bool zeroRange(
File* file,
size_t begin,
size_t end);
176 bool updateFileMetadata(
File* file,
size_t size);
177 bool syncFileMetadata(
File* file);
178 uint64_t allocatedBlocks(
File* file);
195 uint32_t dirClus = 0,
bool publish =
true);
207 bool isEof(uint32_t cluster)
const {
222 Time::Timestamp getUnixTimestamp(uint16_t time, uint16_t date)
const;
223 uint16_t getFatDate(Time::Timestamp timestamp)
const;
224 uint16_t getFatTime(Time::Timestamp timestamp)
const;
237 uint32_t m_RootDirCount;
261#if THREADS || defined(STANDALONE_MUTEXES)