Skip to content

Minimizing latency #891

@hattesen

Description

@hattesen

I have a large number of projects that use littlefs for storing configuration and logging.

Some projects use internal NAND flash, others use external (QSPI) NOR flash for storage.

Keeping worst-case write latency to a minimum will minimize the risk of buffer overruns and resulting data corruption.

Q1 In littlefs, what are the (normally occurring) situations that result in high latency during write operations?

Q2 Are there any general recommendations on how to reduce worst-case write latency in littlefs?

Q2: Is there any type of housekeeping that can be performed by an idle-loop task to reduce the worst-case write-latency of littlefs?

Thank you in advance for any guidance in this matter.

PS: I am in the process of building a USB MTP (Media Transfer Protocol) device handler for TinyUSB, allowing a "live" littlefs file system to be accessed by a USB host without risking file system corruption associated with accessing a "live" (FAT) file system using a USB MSD (Mass Storage Device) connection. It will provide great benefits allowing dynamically updating configuration files, downloading log files etc, completely transparently, from any USB Host (Although MacOS will need an MTP driver, as their default implementation is restricted to downloading photos and videos).

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