[BUG] nxffs test
- Dominant language
- C
- Stars
- 4k
- Forks
- 1.7k
- Avg merge
- 1d 17h
- Merged PRs (30d)
- 237
Description
### Description / Steps to reproduce the issue
1. Using an AArch64-based SoC with SPI interface to control a W25-series Flash (e.g., W25Q128).
2. The following functions are called in sequence:
w25_initialize() (SPI Flash driver initialization)
nxffs_initialize() (NXFFS filesystem setup)
nx_mount() (mounting the filesystem)
3. Nxffs test config as follow
CONFIG_TESTING_NXFFS_NEBLOCKS=32
CONFIG_TESTING_NXFFS_MAXNAME=24
CONFIG_TESTING_NXFFS_MAXFILE=1024
CONFIG_TESTING_NXFFS_MAXIO=347
CONFIG_TESTING_NXFFS_MAXOPEN=32
CONFIG_TESTING_NXFFS_MOUNTPT="/mnt/w25a"
CONFIG_TESTING_NXFFS_NLOOPS=2
4. Running nxffs command in shell
### On which OS does this issue occur?
[OS: Linux]
### What is the version of your OS?
Ubuntu22.04
### NuttX Version
release 12.4
### Issue Architecture
[Arch: arm64]
### Issue Area
[Area: File System]
### Host information
After executing nxffs operations, there is a probabilistic occurrence where:
The first file is successfully created and written with data.
However, the file fails to be detected during nxffs_directory scanning.
Consequently, subsequent calls to nxffs_rdfile result in the error:
```ERROR: Failed to open file for reading: 2```
Through repeated testing, we've confirmed this file loss exclusively affects the first created file.


### Verification
- [x] I have verified before submitting the report.
Contributor guide
Assessment
This issue has not been assessed yet.