Kaynağa Gözat

Merge branch 'docs/nvs_add_return_error_description_for_nvs_open' into 'master'

docs: nvs_open* add ESP_ERR_INVALID_ARG to return description

Closes IDF-1528

See merge request espressif/esp-idf!26583
Martin Vychodil 2 yıl önce
ebeveyn
işleme
8cd898ebee
1 değiştirilmiş dosya ile 4 ekleme ve 2 silme
  1. 4 2
      components/nvs_flash/include/nvs.h

+ 4 - 2
components/nvs_flash/include/nvs.h

@@ -136,6 +136,7 @@ typedef struct nvs_opaque_iterator_t *nvs_iterator_t;
  *             - ESP_ERR_NVS_NOT_ENOUGH_SPACE if there is no space for a new entry or there are too many different
  *                                  namespaces (maximum allowed different namespaces: 254)
  *             - ESP_ERR_NOT_ALLOWED if the NVS partition is read-only and mode is NVS_READWRITE
+ *             - ESP_ERR_INVALID_ARG if out_handle is equal to NULL
  *             - other error codes from the underlying storage driver
  */
 esp_err_t nvs_open(const char* namespace_name, nvs_open_mode_t open_mode, nvs_handle_t *out_handle);
@@ -168,6 +169,7 @@ esp_err_t nvs_open(const char* namespace_name, nvs_open_mode_t open_mode, nvs_ha
  *             - ESP_ERR_NVS_NOT_ENOUGH_SPACE if there is no space for a new entry or there are too many different
  *                                  namespaces (maximum allowed different namespaces: 254)
  *             - ESP_ERR_NOT_ALLOWED if the NVS partition is read-only and mode is NVS_READWRITE
+ *             - ESP_ERR_INVALID_ARG if out_handle is equal to NULL
  *             - other error codes from the underlying storage driver
  */
 esp_err_t nvs_open_from_partition(const char *part_name, const char* namespace_name, nvs_open_mode_t open_mode, nvs_handle_t *out_handle);
@@ -587,7 +589,7 @@ typedef struct {
  *               Return param nvs_stats will be filled 0.
  *             - ESP_ERR_NVS_NOT_INITIALIZED if the storage driver is not initialized.
  *               Return param nvs_stats will be filled 0.
- *             - ESP_ERR_INVALID_ARG if nvs_stats equal to NULL.
+ *             - ESP_ERR_INVALID_ARG if nvs_stats is equal to NULL.
  *             - ESP_ERR_INVALID_STATE if there is page with the status of INVALID.
  *               Return param nvs_stats will be filled not with correct values because
  *               not all pages will be counted. Counting will be interrupted at the first INVALID page.
@@ -628,7 +630,7 @@ esp_err_t nvs_get_stats(const char *part_name, nvs_stats_t *nvs_stats);
  *               Return param used_entries will be filled 0.
  *             - ESP_ERR_NVS_INVALID_HANDLE if handle has been closed or is NULL.
  *               Return param used_entries will be filled 0.
- *             - ESP_ERR_INVALID_ARG if used_entries equal to NULL.
+ *             - ESP_ERR_INVALID_ARG if used_entries is equal to NULL.
  *             - Other error codes from the underlying storage driver.
  *               Return param used_entries will be filled 0.
  */