mesh: Replace storage_save_config with mesh_config_save_config
authorInga Stotland <inga.stotland@intel.com>
Sun, 14 Jul 2019 23:23:16 +0000 (16:23 -0700)
committerAnupam Roy <anupam.r@samsung.com>
Tue, 17 Dec 2019 16:19:01 +0000 (21:49 +0530)
commit3b58e79f142341e52f78ee1dc0f88bd4ea2e9254
treea1340e3408f023af29afd37d5ff9c9367ef22a0c
parent8af5bfb4de23843efd2dbd710069025babf2e72c
mesh: Replace storage_save_config with mesh_config_save_config

This moves writing out of node configuration from storage.c down to
mesh-config-<format-specific>.c to allow for more generic storage layout.

New generalized API in mesh-config.h:
mesh_config_save_config(struct mesh_config *cfg, bool no_wait,
mesh_config_status_func_t cb, void *user_data)

replaces the old one in storage.h:
storage_save_config(struct mesh_node *node, bool no_wait,
mesh_status_func_t cb, void *user_data)

Currently, only JSON format is supported for storing node configuration:
mesh_config_save_config is implemented in mesh-config-json.c

Change-Id: I6ecb77332911bdb6a6ae18feedb8cae40b2832ff
Signed-off-by: Anupam Roy <anupam.r@samsung.com>
mesh/mesh-config-json.c
mesh/mesh-config.h
mesh/node.c
mesh/storage.c
mesh/storage.h