Commit Graph

95 Commits

Author SHA1 Message Date
Tomáš Rohlínek 3e41a5de6f feat(storage/vfs): Deprecate legacy API 2025-12-16 17:48:55 +08:00
Tomáš Rohlínek 515975d2bb feat(storage/vfs): Make lwip specific API private 2025-12-16 17:48:55 +08:00
Tomáš Rohlínek 8c9d62de98 feat(storage/vfs): Remove old API usage 2025-12-16 17:48:55 +08:00
Tomáš Rohlínek 4814f06283 feat(storage/vfs): refactor VFS calls to multiple files 2025-12-16 17:48:55 +08:00
sonika.rathi 24e42cc4a6 feat(vfs): add linux support to vfs 2025-11-05 09:49:21 +01:00
Alexey Lapshin 9281e78381 change(esp_libc): rename newlib component to esp_libc 2025-09-09 22:00:44 +08:00
Tomáš Rohlínek 67638981ec feat(storage/vfs): cleanup path prefix handling 2025-02-07 10:34:24 +01:00
Tomáš Rohlínek a45b12a68b feat(storage/vfs): improve mountpoint table memory usage 2025-01-30 09:07:51 +01:00
Tomáš Rohlínek 5e53f2975e fix(storage/vfs): incorrect log level in esp_vfs_register_fd_range
Closes https://github.com/espressif/esp-idf/issues/14327
2024-12-16 15:12:11 +01:00
Martin Vychodil f8701f1c92 Merge branch 'feat/vfs_ops_make_all_op_pointers_const' into 'master'
feat(storage/vfs): make all member pointer of vfs_ops struct const

See merge request espressif/esp-idf!35287
2024-12-13 18:01:53 +08:00
Tomáš Rohlínek 86e5039fc9 feat(storage/vfs): make all member pointer of vfs_ops struct const 2024-12-12 13:03:30 +01:00
Alexey Lapshin 888b5f7e8d feat(newlib): add picolibc support 2024-12-02 21:35:56 +07:00
Alexey Lapshin 1232759fb7 fix(vfs): fix gcc 14 analyzer warning 2024-12-02 20:26:26 +07:00
Tomáš Rohlínek 5109f08dfa feat(storage/vfs): make subcomponent pointers const 2024-11-21 07:41:40 +01:00
Tomáš Rohlínek 18e20c0bc5 feat(storage/vfs): change names related to minified vfs 2024-10-22 14:50:31 +08:00
Tomáš Rohlínek 040ad5ca20 feat(storage/vfs): add test for ESP_VFS_FLAG_STATIC 2024-10-22 14:50:31 +08:00
Tomáš Rohlínek 755adf3b4f feat(storage/vfs): impelement sparse vfs struct 2024-10-22 14:50:31 +08:00
Tomáš Rohlínek cec0525460 fix(storage/vfs): update select sanity checks 2024-10-22 14:50:31 +08:00
Tomáš Rohlínek fe0fc40049 fix(storage/vfs): incorrect registration checks 2024-10-22 14:50:31 +08:00
Tomáš Rohlínek b6a9acfc07 feat(storage/vfs): Add minified vfs implementation 2024-10-22 14:50:31 +08:00
sonika.rathi 0e5793b270 feat(vfs): Add function to dump VFS file descriptors 2024-03-05 18:03:27 +08:00
Song Ruo Jing bc09031496 refactor(uart_vfs): Move uart implementation of vfs to esp_driver_uart
Deprecated esp_vfs_dev_uart_xxx APIs
vfs_uart test case moved to esp_driver_uart test_apps
Astyle fixed for uart_vfs
2023-12-15 17:14:55 +08:00
zwx 7409f41527 fix(vfs): fix uart malloc when locates ISR context in IRAM 2023-11-21 16:36:08 +08:00
sonika.rathi 9c82ad06c3 fix(vfs/uart): add UART VFS select callback in IRAM
UART VFS select callback is placed in IRAM when CONFIG_UART_ISR_IN_IRAM is enabled
2023-11-08 11:34:22 +01:00
Adam Múdry ab1eb37fe8 feat(partition_table): Add read-only partition flag and functionality 2023-10-11 00:01:05 +02:00
Adam Múdry 58e69f2fcb vfs: select sanity NULL check
https://github.com/espressif/esp-idf/issues/9964
2023-05-23 18:02:24 +02:00
Ivan Grokhotkov fee3082d88 vfs: VFS_MAX_COUNT should be non-zero even without IO support 2023-04-13 15:37:37 +02:00
Oliver Schmidt 6beeecbbcf Allow to config the maximum number of VFS entries. 2023-03-14 17:29:11 +01:00
Ivan Grokhotkov 23e1ae1bc2 storage: fix and re-enable -Wformat warnings 2022-10-06 16:16:32 +02:00
David Cermak bf8ceae780 vfs: Fix potential select() race if both sock and other-fd trigger
This fixes a potential race condition in select() if both a socket-fd
and non-socket fd trigger simultaneously to unblock this select.
In case of both fds, we use lwip's local thread semaphore, so we only
have to try return it (if it was taken/triggered more than once) when
we exit select().

Closes https://github.com/espressif/esp-idf/issues/8896
2022-05-16 20:26:44 +02:00
morris 483149e41b global: fix some potential out-of-bounds issue
...that found by Coverity Scan
2022-04-08 11:05:43 +08:00
Vamshi Gajjela ea9f7cc370 fatfs: Add ftruncate api support for VFS and FAT-VFS
Unit test cases added to verify ftruncate within fatfs tests.

Closes https://github.com/espressif/esp-idf/issues/8279
2022-03-08 16:58:25 +05:30
David Čermák c45d34aea2 Merge branch 'bugfix/lwipopts_cleanup' into 'master'
lw-IP: Cleanup of config options and flags

Closes IDF-3594

See merge request espressif/esp-idf!15248
2022-01-17 06:46:27 +00:00
Martin Vychodil f01b9a583e Merge branch 'bugfix/vfs_open_errno' into 'master'
vfs: don't overwrite errno by a hard coded ENOENT (Github PR)

Closes IDFGH-6378

See merge request espressif/esp-idf!16790
2022-01-14 17:23:07 +00:00
David Cermak 5d7489eae4 lwip: Fix minor lwip dependency issue
Clean-up config option rename file
2022-01-14 16:41:38 +01:00
David Cermak b597dbff7c vfs: Warn aobut using deprecated select option
Add LWIP_USE_ONLY_LWIP_SELECT for compatibility, as the dependency may
break backward compatibility if LWIP_USE_ONLY_LWIP_SELECT=y.
2022-01-14 16:41:38 +01:00
hörbert 71fe41d0e0 vfs: don't overwrite errno by a hard coded ENOENT
Calling "open" in CHECK_AND_CALL sets a perfectly correct errno.
There is no need to overwrite that with a value of ENOENT, since doing
so hides lower level errors like EIO.

Closes https://github.com/espressif/esp-idf/pull/8036
2022-01-14 13:34:21 +01:00
caixf 6c3b528917 vfs: fix wrong VFS being freed when esp_vfs_register_fd_range fails
Closes https://github.com/espressif/esp-idf/pull/7413
2022-01-13 17:17:42 +01:00
Jiacheng Guo b00d6d0a95 vfs: reduce lock in vfs_select 2021-11-29 14:09:07 +08:00
Cao Sen Miao adfb7bed96 vfs_usb_serial: set secondary selection for making usb port can output under default menu 2021-11-01 15:48:36 +08:00
Omar Chebib 73303e5de0 VFS: select function's timeout is now POSIX compliant
`select` function will now round up the timeout passed as a parameter (if any).
It  makes it POSIX compliant.

* Closes https://github.com/espressif/esp-idf/issues/7514
2021-10-28 02:52:59 +00:00
Jiacheng Guo f20fb57871 vfs: fix select return value when non-permanent fd closed 2021-08-16 10:49:31 +08:00
Jiacheng Guo bbb0e7a573 vfs: fix build & ci errors 2021-04-15 15:19:00 +08:00
Jiacheng Guo 7b911e4641 vfs: add support for mutiple selects in eventfd 2021-04-15 15:18:59 +08:00
morris 753a929525 global: fix sign-compare warnings 2021-01-12 14:05:08 +08:00
Angus Gratton 420aef1ffe Updates for riscv support
* Target components pull in xtensa component directly
* Use CPU HAL where applicable
* Remove unnecessary xtensa headers
* Compilation changes necessary to support non-xtensa gcc types (ie int32_t/uint32_t is no
  longer signed/unsigned int).

Changes come from internal branch commit a6723fc
2020-11-13 07:49:11 +11:00
Ivan Grokhotkov 53f89464a3 vfs: fix invalid dereference for zero-length base_path
When base_path has len == 0, the code used to compare base_path[-1]
with '/'. Fix by correcting the length check.
Also mention the case of zero-length base_path in the API reference.

Closes https://github.com/espressif/esp-idf/issues/5514
2020-07-10 00:20:55 +02:00
Ivan Grokhotkov cadab2cbcf vfs: define all implementations as esp_vfs_, create aliases
This change allows (in the future) to test VFS on host, without having
it conflict with the host C library. On host, all aliases would be
disabled.
2020-03-20 13:43:42 +01:00
Ivan Grokhotkov a3c0bcb0a0 vfs: introduce options to turn off some features
CONFIG_VFS_SUPPORT_IO: for basic I/O functions support
CONFIG_VFS_SUPPORT_DIR: for file/directory functions support
CONFIG_VFS_SUPPORT_SELECT: for select support
2020-03-20 13:43:42 +01:00
Konstantin Kondrashov 2c793cef06 idf: Support a custom toolchain with time_t wide 64-bits
Allows resolving the Y2K38 problem.

Closes: IDF-350

Closes: https://github.com/espressif/esp-idf/issues/584
2020-01-10 12:58:54 +08:00