Skip to content

Crash at lfs_fs_traverse() #1158

@liconghui628

Description

@liconghui628

Hello everyone,
I'm encountering a program crash issue, call stack as follows:
[
exception_entry 于 bl_irq.c:397
is_exception 于 portable/GCC/RISC-V/portASM.S:355
?? ??:0
lfs_fs_traverse 于 littlefs/littlefs/lfs.c:3755 (dicriminator 1) // Line 3755 is lfs_dir_fetch()
lfs_alloc 于 littlefs/littlefs/lfs.c:484
lfs_ctz_extend 于 littlefs/littlefs/lfs.c:2174
log_write 于 littlefs/log/miio_log.c:116 //This is the interface I implemented myself
]

The version I am using is 2.1. At the beginning, it was normal, but after the problem occurred, even every time the power was turned on and restarted, it would crash here. Here are some configurations for Littlefs.

const struct lfs_config lfscfg = {
// block device operations
.read = milfs_flash_read,
.prog = milfs_flash_prog,
.erase = milfs_flash_erase,
.sync = milfs_flash_sync,

// block device configuration
.block_size = 4096,
.block_count = 20,
.read_size = 512,
.prog_size = 16,
.cache_size = 512,
.lookahead_size = 16,
.block_cycles = 500,

};

Can anyone help me? Thank you very much.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions