Commit Graph

13 Commits

Author SHA1 Message Date
Cody P Schafer
f2af1c5305 nvs: support iteration over namespace by index
Users of the nvs API are likely to have `nvs_handle_t` in all cases, but
not all of them carry around the partition name and namespace name (as
they aren't needed after creating an `nvs_handle_t`).

Allow this common case to use nvs iteration without them tracking
additional data by using the `nvs_handle_t` to locate the namespace
index and the partition name by introducing an alterate to
`nvs_entry_find` called `nvs_entry_find_in_handle`, which operates
similarly except that it is given a `nvs_handle_t` instead of partition
and namespace strings.

This is somewhat more limited than the `nvs_entry_find` API as one
cannot examine all keys in a given partition.
2023-08-29 13:59:34 +02:00
Martin Vychodil
e44d4260ad Merge branch 'feature/storage_host_test_nvs_flash2' into 'master'
nvs_flash: finished migration of host tests to the linux emulator of esp_partition

See merge request espressif/esp-idf!23926
2023-08-28 20:20:16 +08:00
radek.tandler
28f82d8de7 refactor(nvs_flash): Host test migrated to esp_partition emulation for linux 2023-08-09 14:14:21 +02:00
radek.tandler
ac6c03fad1 change(nvs_flash): nvs_get_stats extended, API documentation improved 2023-08-08 08:43:19 +02:00
Cody P Schafer
cbe906e53c
nvs_host_test: replace sprintf with snprintf
With some libc impls (ie: Xcode 13.1), sprintf is marked as deprecated
and causes the build with `-Werror` to fail. Switch the `sprintf` usage
in test_nvs.cpp to use `snprintf` to allow builds to complete without
warning.
2023-04-03 16:33:57 -04:00
Jakob Hasse
bed81f450d ci(nvs_flash): Increase timeout of nvs_page_test
* nvs_page_test runs into timeout in CI. According to log,
  test ran run around halfway, so increasing from 10 to 90 seconds.

* Also increased timeout of nvs_host_test, just to be sure
2023-02-13 12:35:52 +08:00
Martin Vychodil
a2b0068478 Merge branch 'bugfix/linux_build_errors' into 'master'
fix(linux): fix build errors without --skip-setting-flags

See merge request espressif/esp-idf!22063
2023-01-20 14:46:36 +08:00
Ivan Grokhotkov
cef0744299 Merge branch 'bugfix/linux_target_gen_partition_table' into 'master'
multiple fixes for linux target

Closes IDF-6641

See merge request espressif/esp-idf!21993
2023-01-18 11:57:08 +08:00
Jakob Hasse
9991862a10 fix(linux): fix build errors and warnings, remove ignore file 2023-01-18 09:24:28 +08:00
Fu Hanxi
b02687a6c4 test: migrate linux target host test jobs into pytest-embedded 2023-01-16 10:25:55 +08:00
Ivan Grokhotkov
ec8f38c9da
build system: generate the partition table by default for linux target
This fixes the issue that "idf.py partition-table" had to be run
manually in order for the partition table to be generated, when
building for linux target.
2023-01-13 08:14:56 +01:00
Jakob Hasse
91f04aa877 refactor(nvs): custom allocator for all objects allocated in NVS 2022-12-05 18:59:33 +01:00
radek.tandler
ca7f073e7b nvs_flash/host_test: migrated to the CMake build system and nvs flash Linux implementation
Host tests of nvs_flash eligible to run in Linux implementation of nvs flash were migrated. Remaining test cases
were left in original folder. Migrated test cases use CMake instead of make.
2022-11-16 14:15:23 +01:00