mirror of
https://github.com/apache/nuttx.git
synced 2026-05-21 04:52:02 +08:00
rptun: Remove the unused shmemname field and argument
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
This commit is contained in:
committed by
Mateusz Szafoni
parent
6a6bd30500
commit
1e3914ec9d
@@ -93,7 +93,6 @@ struct nrf53_rptun_dev_s
|
||||
bool master;
|
||||
struct nrf53_rptun_shmem_s *shmem;
|
||||
char cpuname[RPMSG_NAME_SIZE + 1];
|
||||
char shmemname[RPMSG_NAME_SIZE + 1];
|
||||
};
|
||||
|
||||
/****************************************************************************
|
||||
@@ -456,7 +455,7 @@ static int nrf53_rptun_thread(int argc, char *argv[])
|
||||
* Public Functions
|
||||
****************************************************************************/
|
||||
|
||||
int nrf53_rptun_init(const char *shmemname, const char *cpuname)
|
||||
int nrf53_rptun_init(const char *cpuname)
|
||||
{
|
||||
struct nrf53_rptun_dev_s *dev = &g_rptun_dev;
|
||||
int ret = OK;
|
||||
@@ -488,7 +487,6 @@ int nrf53_rptun_init(const char *shmemname, const char *cpuname)
|
||||
|
||||
dev->rptun.ops = &g_nrf53_rptun_ops;
|
||||
strncpy(dev->cpuname, cpuname, RPMSG_NAME_SIZE);
|
||||
strncpy(dev->shmemname, shmemname, RPMSG_NAME_SIZE);
|
||||
|
||||
ret = rptun_initialize(&dev->rptun);
|
||||
if (ret < 0)
|
||||
|
||||
@@ -50,7 +50,7 @@ extern "C"
|
||||
* Name: nrf53_rptun_init
|
||||
****************************************************************************/
|
||||
|
||||
int nrf53_rptun_init(const char *shmemname, const char *cpuname);
|
||||
int nrf53_rptun_init(const char *cpuname);
|
||||
|
||||
#undef EXTERN
|
||||
#if defined(__cplusplus)
|
||||
|
||||
@@ -99,7 +99,6 @@ struct stm32_rptun_dev_s
|
||||
bool master;
|
||||
struct stm32_rptun_shmem_s *shmem;
|
||||
char cpuname[RPMSG_NAME_SIZE + 1];
|
||||
char shmemname[RPMSG_NAME_SIZE + 1];
|
||||
};
|
||||
|
||||
/****************************************************************************
|
||||
@@ -452,7 +451,7 @@ static int stm32_rptun_thread(int argc, char *argv[])
|
||||
* Public Functions
|
||||
****************************************************************************/
|
||||
|
||||
int stm32_rptun_init(const char *shmemname, const char *cpuname)
|
||||
int stm32_rptun_init(const char *cpuname)
|
||||
{
|
||||
struct stm32_rptun_dev_s *dev = &g_rptun_dev;
|
||||
int ret = OK;
|
||||
@@ -482,7 +481,6 @@ int stm32_rptun_init(const char *shmemname, const char *cpuname)
|
||||
|
||||
dev->rptun.ops = &g_stm32_rptun_ops;
|
||||
strncpy(dev->cpuname, cpuname, RPMSG_NAME_SIZE);
|
||||
strncpy(dev->shmemname, shmemname, RPMSG_NAME_SIZE);
|
||||
|
||||
ret = rptun_initialize(&dev->rptun);
|
||||
if (ret < 0)
|
||||
|
||||
@@ -50,7 +50,7 @@ extern "C"
|
||||
* Name: stm32_rptun_init
|
||||
****************************************************************************/
|
||||
|
||||
int stm32_rptun_init(const char *shmemname, const char *cpuname);
|
||||
int stm32_rptun_init(const char *cpuname);
|
||||
|
||||
#undef EXTERN
|
||||
#if defined(__cplusplus)
|
||||
|
||||
@@ -80,7 +80,6 @@
|
||||
/* rptun initialization names */
|
||||
|
||||
#define MPFS_RPTUN_CPU_NAME "mpfs-ihc"
|
||||
#define MPFS_RPTUN_SHMEM_NAME "mpfs-shmem"
|
||||
|
||||
/* Vring configuration parameters */
|
||||
|
||||
@@ -131,7 +130,6 @@ struct mpfs_rptun_dev_s
|
||||
struct mpfs_rptun_shmem_s *shmem;
|
||||
struct simple_addrenv_s addrenv[VRINGS];
|
||||
char cpuname[RPMSG_NAME_SIZE + 1];
|
||||
char shmemname[RPMSG_NAME_SIZE + 1];
|
||||
};
|
||||
|
||||
struct mpfs_queue_table_s
|
||||
@@ -1085,7 +1083,6 @@ static int mpfs_rptun_register_callback(struct rptun_dev_s *dev,
|
||||
* Initializes the rptun device.
|
||||
*
|
||||
* Input Parameters:
|
||||
* shmemname - Shared mempory name
|
||||
* cpuname - Local CPU name
|
||||
*
|
||||
* Returned Value:
|
||||
@@ -1093,7 +1090,7 @@ static int mpfs_rptun_register_callback(struct rptun_dev_s *dev,
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
static int mpfs_rptun_init(const char *shmemname, const char *cpuname)
|
||||
static int mpfs_rptun_init(const char *cpuname)
|
||||
{
|
||||
struct mpfs_rptun_dev_s *dev;
|
||||
int ret;
|
||||
@@ -1112,7 +1109,6 @@ static int mpfs_rptun_init(const char *shmemname, const char *cpuname)
|
||||
|
||||
dev->rptun.ops = &g_mpfs_rptun_ops;
|
||||
strlcpy(dev->cpuname, cpuname, sizeof(dev->cpuname));
|
||||
strlcpy(dev->shmemname, shmemname, sizeof(dev->shmemname));
|
||||
list_add_tail(&g_dev_list, &dev->node);
|
||||
|
||||
ret = rptun_initialize(&dev->rptun);
|
||||
@@ -1377,7 +1373,7 @@ int mpfs_ihc_init(void)
|
||||
g_shmem.rsc.rpmsg_vdev.status |= VIRTIO_CONFIG_STATUS_DRIVER_OK;
|
||||
}
|
||||
|
||||
ret = mpfs_rptun_init(MPFS_RPTUN_SHMEM_NAME, MPFS_RPTUN_CPU_NAME);
|
||||
ret = mpfs_rptun_init(MPFS_RPTUN_CPU_NAME);
|
||||
if (ret < 0)
|
||||
{
|
||||
ihcerr("ERROR: Not able to init RPTUN\n");
|
||||
|
||||
@@ -226,9 +226,9 @@ int nrf53_bringup(void)
|
||||
|
||||
#ifdef CONFIG_RPTUN
|
||||
#ifdef CONFIG_NRF53_APPCORE
|
||||
nrf53_rptun_init("nrf53-shmem", "appcore");
|
||||
nrf53_rptun_init("appcore");
|
||||
#else
|
||||
nrf53_rptun_init("nrf53-shmem", "netcore");
|
||||
nrf53_rptun_init("netcore");
|
||||
#endif
|
||||
#endif
|
||||
|
||||
|
||||
@@ -205,9 +205,9 @@ int nrf53_bringup(void)
|
||||
|
||||
#ifdef CONFIG_RPTUN
|
||||
#ifdef CONFIG_NRF53_APPCORE
|
||||
nrf53_rptun_init("nrf53-shmem", "appcore");
|
||||
nrf53_rptun_init("appcore");
|
||||
#else
|
||||
nrf53_rptun_init("nrf53-shmem", "netcore");
|
||||
nrf53_rptun_init("netcore");
|
||||
#endif
|
||||
#endif
|
||||
|
||||
|
||||
@@ -104,9 +104,9 @@ int stm32_bringup(void)
|
||||
|
||||
#ifdef CONFIG_RPTUN
|
||||
# ifdef CONFIG_ARCH_CHIP_STM32H7_CORTEXM7
|
||||
stm32_rptun_init("cm4-cm7-shmem", "cm4");
|
||||
stm32_rptun_init("cm4");
|
||||
# else
|
||||
stm32_rptun_init("cm4-cm7-shmem", "cm7");
|
||||
stm32_rptun_init("cm7");
|
||||
# endif
|
||||
#endif
|
||||
|
||||
|
||||
Reference in New Issue
Block a user