Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NFFS requires 1-byte unaligned accesses to flash #1583

Closed
carlescufi opened this issue Sep 21, 2017 · 7 comments
Closed

NFFS requires 1-byte unaligned accesses to flash #1583

carlescufi opened this issue Sep 21, 2017 · 7 comments
Assignees
Labels
area: File System Enhancement Changes/Updates/Additions to existing features

Comments

@carlescufi
Copy link
Member

Documented here: https://issues.apache.org/jira/browse/MYNEWT-13

It won't work on devices that cannot access the flash at any address and with 1-byte granularity

nagineni pushed a commit to nagineni/zephyr that referenced this issue Nov 20, 2017
…s#1583)

The new linux timer port uses signals as callbacks for
timers. The signal API expects a greater than zero timeout
so in the zero timeout case we pass 1.

Signed-off-by: James Prestwood <[email protected]>
@nashif nashif added the bug The issue is a bug, or the PR is fixing a bug label Jan 30, 2018
@nashif nashif added the priority: medium Medium impact/importance bug label Feb 9, 2018
@nashif nashif added priority: low Low impact/importance bug and removed priority: medium Medium impact/importance bug labels May 15, 2018
@nashif
Copy link
Member

nashif commented May 15, 2018

lowering, a limitation rather than a bug

@carlescufi
Copy link
Member Author

CC @utzig

@nashif nashif added Enhancement Changes/Updates/Additions to existing features area: File System and removed priority: low Low impact/importance bug bug The issue is a bug, or the PR is fixing a bug labels Mar 3, 2019
@d3zd3z
Copy link
Collaborator

d3zd3z commented Dec 3, 2019

I fear this limitation is going to become more significant. I'm already seeing several devices that have a write alignment of 512. I don't know if this can be address with NFFS, or if there is possibly another filesystem that might handle these devices?

@carlescufi
Copy link
Member Author

carlescufi commented Dec 3, 2019

I fear this limitation is going to become more significant. I'm already seeing several devices that have a write alignment of 512. I don't know if this can be address with NFFS, or if there is possibly another filesystem that might handle these devices?

AFAIK NFFS hasn't seen any work recently and we should probably deprecate it. Instead, littlefs, which is already integrated into Zephyr, should be a good replacement. I assume that littlefs doesn't have this limitation @pabigot @nvlsianpu ?

@pabigot
Copy link
Collaborator

pabigot commented Dec 3, 2019

littlefs allows you to specify the size (and implied alignment) of both read and program operations. https://github.com/zephyrproject-rtos/zephyr/blob/master/tests/subsys/fs/littlefs/src/testfs_lfs.h and related files show how to configure the filesystem. The default configuration uses 16-byte transfers.

@nvlsianpu
Copy link
Collaborator

AFAIK NFFS hasn't seen any work recently and we should probably deprecate it.

That's right. NFFS should be deprecated - it has serious bugs by design.

@nvlsianpu
Copy link
Collaborator

NFFS support was removed #21793.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: File System Enhancement Changes/Updates/Additions to existing features
Projects
None yet
Development

No branches or pull requests

5 participants