[04/15] drivers: replace master lcore with main lcore
diff mbox series

Message ID 20200911190701.29171-5-stephen@networkplumber.org
State Superseded
Headers show
Series
  • Replace terms master/slave lcore with main/worker lcore
Related show

Checks

Context Check Description
ci/checkpatch warning coding style issues

Commit Message

Stephen Hemminger Sept. 11, 2020, 7:06 p.m. UTC
Replace use of deprecated rte_master_lcore with rte_main_lcore.

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
---
 drivers/bus/dpaa/dpaa_bus.c                  | 2 +-
 drivers/net/bnxt/bnxt_ring.c                 | 4 ++--
 drivers/net/mvpp2/mrvl_ethdev.c              | 6 +++---
 drivers/net/qede/base/bcm_osal.c             | 4 ++--
 drivers/net/softnic/rte_eth_softnic_thread.c | 4 ++--
 5 files changed, 10 insertions(+), 10 deletions(-)

Comments

Burakov, Anatoly Sept. 14, 2020, 2:42 p.m. UTC | #1
On 11-Sep-20 8:06 PM, Stephen Hemminger wrote:
> Replace use of deprecated rte_master_lcore with rte_main_lcore.
> 
> Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
> ---

Acked-by: Anatoly Burakov <anatoly.burakov@intel.com>

Patch
diff mbox series

diff --git a/drivers/bus/dpaa/dpaa_bus.c b/drivers/bus/dpaa/dpaa_bus.c
index 32e872da5209..c94c72106f2c 100644
--- a/drivers/bus/dpaa/dpaa_bus.c
+++ b/drivers/bus/dpaa/dpaa_bus.c
@@ -257,7 +257,7 @@  int rte_dpaa_portal_init(void *arg)
 	BUS_INIT_FUNC_TRACE();
 
 	if ((size_t)arg == 1 || lcore == LCORE_ID_ANY)
-		lcore = rte_get_master_lcore();
+		lcore = rte_get_main_lcore();
 	else
 		if (lcore >= RTE_MAX_LCORE)
 			return -1;
diff --git a/drivers/net/bnxt/bnxt_ring.c b/drivers/net/bnxt/bnxt_ring.c
index 54f654744259..910fb11c9c38 100644
--- a/drivers/net/bnxt/bnxt_ring.c
+++ b/drivers/net/bnxt/bnxt_ring.c
@@ -429,7 +429,7 @@  int bnxt_alloc_rxtx_nq_ring(struct bnxt *bp)
 	if (!BNXT_HAS_NQ(bp) || bp->rxtx_nq_ring)
 		return 0;
 
-	socket_id = rte_lcore_to_socket_id(rte_get_master_lcore());
+	socket_id = rte_lcore_to_socket_id(rte_get_main_lcore());
 
 	nqr = rte_zmalloc_socket("nqr",
 				 sizeof(struct bnxt_cp_ring_info),
@@ -819,7 +819,7 @@  int bnxt_alloc_async_ring_struct(struct bnxt *bp)
 	if (BNXT_NUM_ASYNC_CPR(bp) == 0)
 		return 0;
 
-	socket_id = rte_lcore_to_socket_id(rte_get_master_lcore());
+	socket_id = rte_lcore_to_socket_id(rte_get_main_lcore());
 
 	cpr = rte_zmalloc_socket("cpr",
 				 sizeof(struct bnxt_cp_ring_info),
diff --git a/drivers/net/mvpp2/mrvl_ethdev.c b/drivers/net/mvpp2/mrvl_ethdev.c
index 96b27dfd309d..85deddf120b4 100644
--- a/drivers/net/mvpp2/mrvl_ethdev.c
+++ b/drivers/net/mvpp2/mrvl_ethdev.c
@@ -814,7 +814,7 @@  mrvl_flush_bpool(struct rte_eth_dev *dev)
 	unsigned int core_id = rte_lcore_id();
 
 	if (core_id == LCORE_ID_ANY)
-		core_id = rte_get_master_lcore();
+		core_id = rte_get_main_lcore();
 
 	hif = mrvl_get_hif(priv, core_id);
 
@@ -1618,7 +1618,7 @@  mrvl_fill_bpool(struct mrvl_rxq *rxq, int num)
 
 	core_id = rte_lcore_id();
 	if (core_id == LCORE_ID_ANY)
-		core_id = rte_get_master_lcore();
+		core_id = rte_get_main_lcore();
 
 	hif = mrvl_get_hif(rxq->priv, core_id);
 	if (!hif)
@@ -1768,7 +1768,7 @@  mrvl_rx_queue_release(void *rxq)
 	unsigned int core_id = rte_lcore_id();
 
 	if (core_id == LCORE_ID_ANY)
-		core_id = rte_get_master_lcore();
+		core_id = rte_get_main_lcore();
 
 	if (!q)
 		return;
diff --git a/drivers/net/qede/base/bcm_osal.c b/drivers/net/qede/base/bcm_osal.c
index 65837b53d063..4c2706ab4b90 100644
--- a/drivers/net/qede/base/bcm_osal.c
+++ b/drivers/net/qede/base/bcm_osal.c
@@ -112,7 +112,7 @@  void *osal_dma_alloc_coherent(struct ecore_dev *p_dev,
 	snprintf(mz_name, sizeof(mz_name), "%lx",
 					(unsigned long)rte_get_timer_cycles());
 	if (core_id == (unsigned int)LCORE_ID_ANY)
-		core_id = rte_get_master_lcore();
+		core_id = rte_get_main_lcore();
 	socket_id = rte_lcore_to_socket_id(core_id);
 	mz = rte_memzone_reserve_aligned(mz_name, size, socket_id,
 			RTE_MEMZONE_IOVA_CONTIG, RTE_CACHE_LINE_SIZE);
@@ -151,7 +151,7 @@  void *osal_dma_alloc_coherent_aligned(struct ecore_dev *p_dev,
 	snprintf(mz_name, sizeof(mz_name), "%lx",
 					(unsigned long)rte_get_timer_cycles());
 	if (core_id == (unsigned int)LCORE_ID_ANY)
-		core_id = rte_get_master_lcore();
+		core_id = rte_get_main_lcore();
 	socket_id = rte_lcore_to_socket_id(core_id);
 	mz = rte_memzone_reserve_aligned(mz_name, size, socket_id,
 			RTE_MEMZONE_IOVA_CONTIG, align);
diff --git a/drivers/net/softnic/rte_eth_softnic_thread.c b/drivers/net/softnic/rte_eth_softnic_thread.c
index dcfb5eb82c18..8dbb8886e30e 100644
--- a/drivers/net/softnic/rte_eth_softnic_thread.c
+++ b/drivers/net/softnic/rte_eth_softnic_thread.c
@@ -25,7 +25,7 @@  softnic_thread_free(struct pmd_internals *softnic)
 {
 	uint32_t i;
 
-	RTE_LCORE_FOREACH_SLAVE(i) {
+	RTE_LCORE_FOREACH_WORKER(i) {
 		struct softnic_thread *t = &softnic->thread[i];
 
 		/* MSGQs */
@@ -99,7 +99,7 @@  softnic_thread_init(struct pmd_internals *softnic)
 static inline int
 thread_is_valid(struct pmd_internals *softnic, uint32_t thread_id)
 {
-	if (thread_id == rte_get_master_lcore())
+	if (thread_id == rte_get_main_lcore())
 		return 0; /* FALSE */
 
 	if (softnic->params.sc && rte_lcore_has_role(thread_id, ROLE_SERVICE))