[v4,18/27] app/test-pmd: change references to master/slave

Message ID 20200701202359.17006-19-stephen@networkplumber.org (mailing list archive)
State Superseded, archived
Delegated to: Thomas Monjalon
Headers
Series Replace references to master and slave |

Checks

Context Check Description
ci/checkpatch success coding style OK
ci/Intel-compilation fail Compilation issues

Commit Message

Stephen Hemminger July 1, 2020, 8:23 p.m. UTC
  Use new API and naming convention

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
---
 app/test-pmd/config.c     | 4 ++--
 app/test-pmd/parameters.c | 2 +-
 app/test-pmd/softnicfwd.c | 2 +-
 app/test-pmd/testpmd.c    | 4 ++--
 4 files changed, 6 insertions(+), 6 deletions(-)
  

Comments

Burakov, Anatoly July 15, 2020, 12:39 p.m. UTC | #1
On 01-Jul-20 9:23 PM, Stephen Hemminger wrote:
> Use new API and naming convention
> 
> Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
> ---
>   app/test-pmd/config.c     | 4 ++--
>   app/test-pmd/parameters.c | 2 +-
>   app/test-pmd/softnicfwd.c | 2 +-
>   app/test-pmd/testpmd.c    | 4 ++--
>   4 files changed, 6 insertions(+), 6 deletions(-)
> 

I don't have softnicfwd.c in my repo, where is that?

Otherwise,

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

Patch

diff --git a/app/test-pmd/config.c b/app/test-pmd/config.c
index a7112c998bdb..816d9e2064ef 100644
--- a/app/test-pmd/config.c
+++ b/app/test-pmd/config.c
@@ -2649,9 +2649,9 @@  set_fwd_lcores_list(unsigned int *lcorelist, unsigned int nb_lc)
 			printf("lcore %u not enabled\n", lcore_cpuid);
 			return -1;
 		}
-		if (lcore_cpuid == rte_get_master_lcore()) {
+		if (lcore_cpuid == rte_get_initial_lcore()) {
 			printf("lcore %u cannot be masked on for running "
-			       "packet forwarding, which is the master lcore "
+			       "packet forwarding, which is the initial lcore "
 			       "and reserved for command line parsing only\n",
 			       lcore_cpuid);
 			return -1;
diff --git a/app/test-pmd/parameters.c b/app/test-pmd/parameters.c
index f761e14707bf..48aafa289367 100644
--- a/app/test-pmd/parameters.c
+++ b/app/test-pmd/parameters.c
@@ -88,7 +88,7 @@  usage(char* progname)
 	printf("  --nb-ports=N: set the number of forwarding ports "
 	       "(1 <= N <= %d).\n", nb_ports);
 	printf("  --coremask=COREMASK: hexadecimal bitmask of cores running "
-	       "the packet forwarding test. The master lcore is reserved for "
+	       "the packet forwarding test. The initial lcore is reserved for "
 	       "command line parsing only, and cannot be masked on for "
 	       "packet forwarding.\n");
 	printf("  --portmask=PORTMASK: hexadecimal bitmask of ports used "
diff --git a/app/test-pmd/softnicfwd.c b/app/test-pmd/softnicfwd.c
index e9d437364467..d773551845e4 100644
--- a/app/test-pmd/softnicfwd.c
+++ b/app/test-pmd/softnicfwd.c
@@ -654,7 +654,7 @@  softnic_fwd_begin(portid_t pi)
 		if (!rte_lcore_is_enabled(lcore))
 			continue;
 
-		if (lcore == rte_get_master_lcore())
+		if (lcore == rte_get_initial_lcore())
 			continue;
 
 		if (fwd_core_present == 0) {
diff --git a/app/test-pmd/testpmd.c b/app/test-pmd/testpmd.c
index 4989d22ca86c..a68ef351e37e 100644
--- a/app/test-pmd/testpmd.c
+++ b/app/test-pmd/testpmd.c
@@ -83,7 +83,7 @@ 
 uint16_t verbose_level = 0; /**< Silent by default. */
 int testpmd_logtype; /**< Log type for testpmd logs */
 
-/* use master core for command line ? */
+/* use initial core for command line ? */
 uint8_t interactive = 0;
 uint8_t auto_start = 0;
 uint8_t tx_first;
@@ -552,7 +552,7 @@  set_default_fwd_lcores_config(void)
 			}
 			socket_ids[num_sockets++] = sock_num;
 		}
-		if (i == rte_get_master_lcore())
+		if (i == rte_get_initial_lcore())
 			continue;
 		fwd_lcores_cpuids[nb_lc++] = i;
 	}