subsys/mgmt/mcumgr: Add SMP Zephyr specific storage erase command

The commit adds support for Zephyr basic mgmt group to mcumgr.
The first command added to the group is storage erase command.

Authored-by: Sigvart Hovland <sigvart.hovland@nordicsemi.no>
Signed-off-by: Dominik Ermel <dominik.ermel@nordicsemi.no>
This commit is contained in:
Dominik Ermel 2021-07-12 11:57:40 +00:00 committed by Carles Cufí
commit 6617af02c4
5 changed files with 128 additions and 0 deletions

View file

@ -0,0 +1,27 @@
/*
* Copyright (c) 2021 Nordic Semiconductor ASA
*
* SPDX-License-Identifier: Apache-2.0
*/
#ifndef ZEPHYR_INCLUDE_ZEPHYR_MCUMGR_GRP_H_
#define ZEPHYR_INCLUDE_ZEPHYR_MCUMGR_GRP_H_
#include <kernel.h>
#ifdef __cplusplus
extern "C" {
#endif
/* The file contains definitions of Zephyr specific mgmt commands */
#define ZEPHYR_MGMT_GRP_BASE MGMT_GROUP_ID_PERUSER
/* Basic group */
#define ZEPHYR_MGMT_GRP_BASIC ZEPHYR_MGMT_GRP_BASE
#define ZEPHYR_MGMT_GRP_BASIC_CMD_ERASE_STORAGE 0 /* Command to erase storage partition */
#ifdef __cplusplus
}
#endif
#endif /* ZEPHYR_INCLUDE_ZEPHYR_MCUMGR_GRP_H_ */