mirror of
https://github.com/eledio-devices/thirdparty-littlefs.git
synced 2025-11-02 08:48:29 +01:00
Compare commits
1 Commits
debug-allo
...
fix-readme
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
ab56dc5a8b |
@@ -110,7 +110,7 @@ directory functions, with the deviation that the allocation of filesystem
|
|||||||
structures must be provided by the user.
|
structures must be provided by the user.
|
||||||
|
|
||||||
All POSIX operations, such as remove and rename, are atomic, even in event
|
All POSIX operations, such as remove and rename, are atomic, even in event
|
||||||
of power-loss. Additionally, no file updates are not actually committed to
|
of power-loss. Additionally, file updates are not actually committed to
|
||||||
the filesystem until sync or close is called on the file.
|
the filesystem until sync or close is called on the file.
|
||||||
|
|
||||||
## Other notes
|
## Other notes
|
||||||
|
|||||||
8
lfs.c
8
lfs.c
@@ -466,15 +466,9 @@ static int lfs_alloc(lfs_t *lfs, lfs_block_t *block) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// no free blocks in lookahead buffer, need to scan tree
|
|
||||||
LFS_DEBUG("Scanning for free blocks %"PRIx32"-%"PRIx32,
|
|
||||||
lfs->free.i + lfs->free.off,
|
|
||||||
(lfs->free.i + lfs->free.off + 8*lfs->cfg->lookahead_size)
|
|
||||||
% lfs->cfg->block_count);
|
|
||||||
|
|
||||||
// check if we have looked at all blocks since last ack
|
// check if we have looked at all blocks since last ack
|
||||||
if (lfs->free.ack == 0) {
|
if (lfs->free.ack == 0) {
|
||||||
LFS_ERROR("No more free space %"PRIx32,
|
LFS_ERROR("No more free space %"PRIu32,
|
||||||
lfs->free.i + lfs->free.off);
|
lfs->free.i + lfs->free.off);
|
||||||
return LFS_ERR_NOSPC;
|
return LFS_ERR_NOSPC;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user