Skip to content

Is it possible to "discover" a littlefs filesystem partition? #865

Open
@BrianPugh

Description

@BrianPugh

Question

Can a littlefs partition be automatically discovered? I.e. figure out the block_count and the starting address without any other information (well, except maybe block_size).

Context

I'm working on a project where different hardware/software configurations may put the littlefs partition at different locations.

Using a probe, I'd like to be able to find the littlefs partition by scanning the entire flash. I know the superblock contains the magic header "littlefs", block size, and block count, but it doesn't look straight forward to discover the superblock in a relatively robust way.

The simplest thing would be to just scan for "littlefs", operating the assumption that "littlefs" doesn't exist anywhere else on the storage, but that seems a bit too crude/fragile.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions