ipc: Fix struct name

s/rpsmg_mi_ctx_cfg/rpmsg_mi_ctx_cfg/

Signed-off-by: Carlo Caione <ccaione@baylibre.com>
This commit is contained in:
Carlo Caione 2021-07-29 16:20:27 +02:00 committed by Christopher Friedt
commit abb2321d6d
5 changed files with 10 additions and 10 deletions

View file

@ -87,7 +87,7 @@ struct rpmsg_mi_ept_cfg {
void *priv; void *priv;
}; };
/** @brief Struct describing the context of the RPMsg instanece. */ /** @brief Struct describing the context of the RPMsg instance. */
struct rpmsg_mi_ctx { struct rpmsg_mi_ctx {
const char *name; const char *name;
struct k_work_q ipm_work_q; struct k_work_q ipm_work_q;
@ -116,7 +116,7 @@ struct rpmsg_mi_ctx {
}; };
/** @brief Configuration of the RPMsg instance. */ /** @brief Configuration of the RPMsg instance. */
struct rpsmg_mi_ctx_cfg { struct rpmsg_mi_ctx_cfg {
/** Name of instance. */ /** Name of instance. */
const char *name; const char *name;
@ -153,7 +153,7 @@ struct rpsmg_mi_ctx_cfg {
* -ENOMEM when there is not enough memory to register virqueue. * -ENOMEM when there is not enough memory to register virqueue.
* < 0 on other negative errno code, reported by rpmsg. * < 0 on other negative errno code, reported by rpmsg.
*/ */
int rpmsg_mi_ctx_init(struct rpmsg_mi_ctx *ctx, const struct rpsmg_mi_ctx_cfg *cfg); int rpmsg_mi_ctx_init(struct rpmsg_mi_ctx *ctx, const struct rpmsg_mi_ctx_cfg *cfg);
/** @brief Register IPC endpoint. /** @brief Register IPC endpoint.
* *

View file

@ -64,7 +64,7 @@ static void received2_cb(const void *data, size_t len, void *priv)
k_sem_give(&data_rx2_sem); k_sem_give(&data_rx2_sem);
} }
static const struct rpsmg_mi_ctx_cfg cfg_1 = { static const struct rpmsg_mi_ctx_cfg cfg_1 = {
.name = "instance 1", .name = "instance 1",
.ipm_stack_area = ipm_stack_area_1, .ipm_stack_area = ipm_stack_area_1,
.ipm_stack_size = K_THREAD_STACK_SIZEOF(ipm_stack_area_1), .ipm_stack_size = K_THREAD_STACK_SIZEOF(ipm_stack_area_1),
@ -74,7 +74,7 @@ static const struct rpsmg_mi_ctx_cfg cfg_1 = {
.ipm_rx_name = CONFIG_RPMSG_MULTI_INSTANCE_0_IPM_RX_NAME, .ipm_rx_name = CONFIG_RPMSG_MULTI_INSTANCE_0_IPM_RX_NAME,
}; };
static const struct rpsmg_mi_ctx_cfg cfg_2 = { static const struct rpmsg_mi_ctx_cfg cfg_2 = {
.name = "instance 2", .name = "instance 2",
.ipm_stack_area = ipm_stack_area_2, .ipm_stack_area = ipm_stack_area_2,
.ipm_stack_size = K_THREAD_STACK_SIZEOF(ipm_stack_area_2), .ipm_stack_size = K_THREAD_STACK_SIZEOF(ipm_stack_area_2),

View file

@ -64,7 +64,7 @@ static void received2_cb(const void *data, size_t len, void *priv)
k_sem_give(&data_rx2_sem); k_sem_give(&data_rx2_sem);
} }
static const struct rpsmg_mi_ctx_cfg cfg_1 = { static const struct rpmsg_mi_ctx_cfg cfg_1 = {
.name = "instance 1", .name = "instance 1",
.ipm_stack_area = ipm_stack_area_1, .ipm_stack_area = ipm_stack_area_1,
.ipm_stack_size = K_THREAD_STACK_SIZEOF(ipm_stack_area_1), .ipm_stack_size = K_THREAD_STACK_SIZEOF(ipm_stack_area_1),
@ -74,7 +74,7 @@ static const struct rpsmg_mi_ctx_cfg cfg_1 = {
.ipm_rx_name = CONFIG_RPMSG_MULTI_INSTANCE_0_IPM_RX_NAME, .ipm_rx_name = CONFIG_RPMSG_MULTI_INSTANCE_0_IPM_RX_NAME,
}; };
static const struct rpsmg_mi_ctx_cfg cfg_2 = { static const struct rpmsg_mi_ctx_cfg cfg_2 = {
.name = "instance 2", .name = "instance 2",
.ipm_stack_area = ipm_stack_area_2, .ipm_stack_area = ipm_stack_area_2,
.ipm_stack_size = K_THREAD_STACK_SIZEOF(ipm_stack_area_2), .ipm_stack_size = K_THREAD_STACK_SIZEOF(ipm_stack_area_2),

View file

@ -125,7 +125,7 @@ static int register_ept(struct ipc_ept **ept, const struct ipc_ept_cfg *cfg)
* When registering the first endpoint for the instance. * When registering the first endpoint for the instance.
*/ */
if (!instances[i_idx].is_initialized) { if (!instances[i_idx].is_initialized) {
struct rpsmg_mi_ctx_cfg ctx_cfg = { 0 }; struct rpmsg_mi_ctx_cfg ctx_cfg = { 0 };
snprintf(instances[i_idx].name, INSTANCE_NAME_SIZE, "rpmsg_mi_%d", i_idx); snprintf(instances[i_idx].name, INSTANCE_NAME_SIZE, "rpmsg_mi_%d", i_idx);

View file

@ -100,7 +100,7 @@ static void ipm_callback(const struct device *dev, void *context, uint32_t id, v
k_work_submit_to_queue(&ctx->ipm_work_q, &ctx->ipm_work); k_work_submit_to_queue(&ctx->ipm_work_q, &ctx->ipm_work);
} }
int rpmsg_mi_configure_shm(struct rpmsg_mi_ctx *ctx, const struct rpsmg_mi_ctx_cfg *cfg) int rpmsg_mi_configure_shm(struct rpmsg_mi_ctx *ctx, const struct rpmsg_mi_ctx_cfg *cfg)
{ {
uint8_t vring_size = VRING_SIZE_GET(SHM_SIZE); uint8_t vring_size = VRING_SIZE_GET(SHM_SIZE);
uint32_t shm_addr = SHMEM_INST_ADDR_AUTOALLOC_GET(SHM_START_ADDR, SHM_SIZE, instance); uint32_t shm_addr = SHMEM_INST_ADDR_AUTOALLOC_GET(SHM_START_ADDR, SHM_SIZE, instance);
@ -193,7 +193,7 @@ static void ns_bind_cb(struct rpmsg_device *rdev, const char *name, uint32_t des
} }
} }
int rpmsg_mi_ctx_init(struct rpmsg_mi_ctx *ctx, const struct rpsmg_mi_ctx_cfg *cfg) int rpmsg_mi_ctx_init(struct rpmsg_mi_ctx *ctx, const struct rpmsg_mi_ctx_cfg *cfg)
{ {
struct metal_init_params metal_params = METAL_INIT_DEFAULTS; struct metal_init_params metal_params = METAL_INIT_DEFAULTS;
uint8_t vring_size = VRING_SIZE_GET(SHM_SIZE); uint8_t vring_size = VRING_SIZE_GET(SHM_SIZE);