littlefs-project / littlefs

A little fail-safe filesystem designed for microcontrollers
BSD 3-Clause "New" or "Revised" License
5.23k stars 801 forks source link

LFS_ASSERT(pcache->block == LFS_BLOCK_NULL) #1035

Closed xiaohuozi-jiayou closed 3 weeks ago

xiaohuozi-jiayou commented 1 month ago

Hi,

Currently working on getting Littlefs running on a NOR Flash. Littlefs version is 2.9.3. After power off and restart, an assertion error occurred when writing a file. When this assert fails, this is the current call stack:

lfs_bd_prog(assert failed) lfs_file_relocate lfs_file_outline lfs_file_flushedwrite lfs_filewrite

What is the possible cause?

Best regards

xiaohuozi-jiayou commented 3 weeks ago

opne the lock