Apache NuttX is a mature, real-time embedded operating system (RTOS)
Go to file
Jukka Laitinen 26b7de0f34 fs/fat: Fix number of data clusters usable for fat driver
Fix the issue where fat driver is not using the last two clusters in
the file system.

The fat parameter fs->fs_nclusters is the maximum number of data clusters;
this doesn't include the two in the beginning. Many checks in the fat driver
treat the fs->fs_nclusters-1 as being the last accessible cluster, which is not
right, the last accessible one is actually this number + 2 when the cluster
count includes the two first ones.

Normally this is not an issue when writes are being done through the same
driver, the last two clusters are just never used. But if the filesystem is
modified by external driver, for example with a populated fat created with PC,
or modifying the FS via USB-MSC, this leads to the fat driver not being able to
read anything that uses the last two clusters.

Signed-off-by: Jukka Laitinen <jukkax@ssrc.tii.ae>
2023-12-22 11:09:12 +01:00
.github build(deps): bump actions/setup-python from 4 to 5 2023-12-10 21:53:27 -08:00
Documentation risc-v: Initial support for CanMV-k230 board and K230 chip 2023-12-17 01:10:57 -08:00
arch espressif/mcuboot: Fix dependency of the Espressif's port MCUboot. 2023-12-22 17:27:58 +08:00
audio Documentation: remove all migrated READMEs 2023-10-29 21:03:54 -03:00
binfmt riscv/arch_elf.c: Handle PCREL_HI20/LO12_I/S relocations correctly 2023-12-12 17:32:36 -08:00
boards boards/esp32s2: Increase init task stack size to 3072 2023-12-20 06:59:18 -08:00
cmake Revert "cmake: restore old behavior for savedefconfig" 2023-12-20 16:05:19 +01:00
crypto sched: explicitly select the cpuload clock source configuration 2023-11-01 09:27:56 +08:00
drivers virtio-net:Fix the compile error. 2023-12-21 01:21:01 -08:00
dummy build: add initial cmake build system 2023-07-08 13:50:48 +08:00
fs fs/fat: Fix number of data clusters usable for fat driver 2023-12-22 11:09:12 +01:00
graphics poll: pollsetup should notify only one fd passd by caller 2023-11-21 09:07:17 +01:00
include drivers/net/ksz9477: Add simple port-based static VLAN configuration 2023-12-20 01:30:54 -08:00
libs cmake build file support with libcxx 17.0.6 2023-12-18 20:38:10 -08:00
mm mm: Fix some typos 2023-11-24 09:57:10 -08:00
net netdev/ipv6: Move `xxx_ipv6multicast` from arch to common code 2023-12-16 05:26:16 -08:00
openamp openamp: Add the virtio_negotiate_features interface for virtio-net. 2023-12-13 05:00:59 -08:00
pass1 passl: Author Gregory Nutt: update licenses to Apache 2021-02-09 01:21:53 -08:00
sched sched: Stop the sched timer when possible to save the power in tickless mode 2023-12-17 08:25:11 -06:00
syscall sched/semaphore: Move named semaphores to user space 2023-11-27 04:52:54 -08:00
tools tool/Config.mk:use bash with or without verbosity enabled 2023-12-21 03:45:52 -08:00
video build: add initial cmake build system 2023-07-08 13:50:48 +08:00
wireless netdev/ipv6: Move `xxx_ipv6multicast` from arch to common code 2023-12-16 05:26:16 -08:00
.asf.yaml feat: add a GitHub action to lint the YAML files 2020-12-15 09:52:04 -06:00
.gitignore Documentation: port warnings_filter Sphinx extension from Zephyr 2023-11-28 09:18:29 -08:00
.yamllint feat: add a GitHub action to lint the YAML files 2020-12-15 09:52:04 -06:00
AUTHORS AUTHORS: add Tomek CEDRO to the list 2023-03-07 14:15:55 +01:00
CMakeLists.txt cmake: NUTTX_COMMON_DIR must be set after .config definitions are included 2023-12-12 16:48:08 -03:00
CONTRIBUTING.md Remove the tail spaces from all files except Documentation 2023-02-26 13:24:24 -08:00
INVIOLABLES.md INVIOLABLES.md: Fix a simple alignment and change occurrences of Nuttx 2020-09-03 01:33:05 +08:00
Kconfig debug/assert: decouple configuration of show file name feature 2023-10-20 02:22:48 +08:00
LICENSE free disk space action added to fix docker image build issue 2023-12-08 14:42:17 +01:00
Makefile tools:fix some error use of shell command in Windows native build 2022-11-06 16:41:49 +08:00
NOTICE Remove the double blank line from source files 2022-02-20 20:10:14 +01:00
README.md Gathering community recommendations 2023-10-28 13:55:56 +08:00
ReleaseNotes Documentation: move ReleaseNotes 2023-09-26 20:41:00 +08:00

README.md

POSIX Badge License Issues Tracking Badge Contributors GitHub Build Badge Documentation Badge

Apache NuttX is a real-time operating system (RTOS) with an emphasis on standards compliance and small footprint. Scalable from 8-bit to 64-bit microcontroller environments, the primary governing standards in NuttX are POSIX and ANSI standards. Additional standard APIs from Unix and other common RTOSs (such as VxWorks) are adopted for functionality not available under these standards, or for functionality that is not appropriate for deeply-embedded environments (such as fork()).

For brevity, many parts of the documentation will refer to Apache NuttX as simply NuttX.

Getting Started

First time on NuttX? Read the Getting Started guide! If you don't have a board available, NuttX has its own simulator that you can run on terminal.

Documentation

You can find the current NuttX documentation on the Documentation Page.

Alternatively, you can build the documentation yourself by following the Documentation Build Instructions.

The old NuttX documentation is still available in the Apache wiki.

Supported Boards

NuttX supports a wide variety of platforms. See the full list on the Supported Platforms page.

Contributing

If you wish to contribute to the NuttX project, read the Contributing guidelines for information on Git usage, coding standard, workflow and the NuttX principles.

License

The code in this repository is under either the Apache 2 license, or a license compatible with the Apache 2 license. See the License Page for more information.