patches for DPDK stable branches
 help / color / Atom feed
* [dpdk-stable] [PATCH] app/testpmd: remove duplicated support for Rx offloading
@ 2019-08-05 12:25 Flavia Musatescu
  2019-08-27  8:48 ` Ferruh Yigit
  2019-08-27 16:43 ` [dpdk-stable] [PATCH v2] " Flavia Musatescu
  0 siblings, 2 replies; 4+ messages in thread
From: Flavia Musatescu @ 2019-08-05 12:25 UTC (permalink / raw)
  To: dev, Wenzhuo Lu, Jingjing Wu, Bernard Iremonger, John McNamara,
	Marko Kovacevic
  Cc: stable, Flavia Musatescu, shahafs

The testpmd application provides two sets of commands for RX offload
flags configuration. The purpose of this patch is to eliminate this
duplication by removing the old set of commands:
“port config all crc-strip|scatter|rx-cksum|rx-timestamp|hw-vlan|
hw-vlan-filter|hw-vlan-strip|hw-vlan-extend on|off”

The other commands set that can be used instead in order to enable
or disable the same RX offloading flags on all RX queues of a port is:
"port config <port_id> rx_offload crc_strip|scatter|ipv4_cksum|
udp_cksum|tcp_cksum|timestamp|vlan_strip|vlan_filter|vlan_extend on|off"

This patch also fixes the "drop-en" command, which enables packets
dropping on all RX queues of all ports when no receive buffers available
“port config all drop-en on|off”

Fixes: 384161e00627 ("app/testpmd: adjust on the fly VLAN configuration")
Cc: shahafs@mellanox.com
Cc: stable@dpdk.org

Signed-off-by: Flavia Musatescu <flavia.musatescu@intel.com>
---
 app/test-pmd/cmdline.c                      | 120 ++++------------------------
 doc/guides/rel_notes/release_19_08.rst      |   9 +++
 doc/guides/testpmd_app_ug/testpmd_funcs.rst |  81 +------------------
 3 files changed, 25 insertions(+), 185 deletions(-)

diff --git a/app/test-pmd/cmdline.c b/app/test-pmd/cmdline.c
index a28362d..eb85548 100644
--- a/app/test-pmd/cmdline.c
+++ b/app/test-pmd/cmdline.c
@@ -778,11 +778,9 @@ static void cmd_help_long_parsed(void *parsed_result,
 			"port config all max-pkt-len (value)\n"
 			"    Set the max packet length.\n\n"
 
-			"port config all (crc-strip|scatter|rx-cksum|rx-timestamp|hw-vlan|hw-vlan-filter|"
-			"hw-vlan-strip|hw-vlan-extend|drop-en)"
-			" (on|off)\n"
-			"    Set crc-strip/scatter/rx-checksum/hardware-vlan/drop_en"
-			" for ports.\n\n"
+			"port config all drop-en (on|off)\n"
+			"    Enable or disable packet drop on all RX queues of all ports when no "
+			"receive buffers available.\n\n"
 
 			"port config all rss (all|default|ip|tcp|udp|sctp|"
 			"ether|port|vxlan|geneve|nvgre|vxlan-gpe|none|<flowtype_id>)\n"
@@ -2109,112 +2107,24 @@ cmd_config_rx_mode_flag_parsed(void *parsed_result,
 				__attribute__((unused)) void *data)
 {
 	struct cmd_config_rx_mode_flag *res = parsed_result;
-	portid_t pid;
-	int k;
 
 	if (!all_ports_stopped()) {
 		printf("Please stop all ports first\n");
 		return;
 	}
 
-	RTE_ETH_FOREACH_DEV(pid) {
-		struct rte_port *port;
-		uint64_t rx_offloads;
-
-		port = &ports[pid];
-		rx_offloads = port->dev_conf.rxmode.offloads;
-		if (!strcmp(res->name, "crc-strip")) {
-			if (!strcmp(res->value, "on")) {
-				rx_offloads &= ~DEV_RX_OFFLOAD_KEEP_CRC;
-			} else if (!strcmp(res->value, "off")) {
-				rx_offloads |= DEV_RX_OFFLOAD_KEEP_CRC;
-			} else {
-				printf("Unknown parameter\n");
-				return;
-			}
-		} else if (!strcmp(res->name, "scatter")) {
-			if (!strcmp(res->value, "on")) {
-				rx_offloads |= DEV_RX_OFFLOAD_SCATTER;
-			} else if (!strcmp(res->value, "off")) {
-				rx_offloads &= ~DEV_RX_OFFLOAD_SCATTER;
-			} else {
-				printf("Unknown parameter\n");
-				return;
-			}
-		} else if (!strcmp(res->name, "rx-cksum")) {
-			if (!strcmp(res->value, "on"))
-				rx_offloads |= DEV_RX_OFFLOAD_CHECKSUM;
-			else if (!strcmp(res->value, "off"))
-				rx_offloads &= ~DEV_RX_OFFLOAD_CHECKSUM;
-			else {
-				printf("Unknown parameter\n");
-				return;
-			}
-		} else if (!strcmp(res->name, "rx-timestamp")) {
-			if (!strcmp(res->value, "on"))
-				rx_offloads |= DEV_RX_OFFLOAD_TIMESTAMP;
-			else if (!strcmp(res->value, "off"))
-				rx_offloads &= ~DEV_RX_OFFLOAD_TIMESTAMP;
-			else {
-				printf("Unknown parameter\n");
-				return;
-			}
-		} else if (!strcmp(res->name, "hw-vlan")) {
-			if (!strcmp(res->value, "on")) {
-				rx_offloads |= (DEV_RX_OFFLOAD_VLAN_FILTER |
-						DEV_RX_OFFLOAD_VLAN_STRIP);
-			} else if (!strcmp(res->value, "off")) {
-				rx_offloads &= ~(DEV_RX_OFFLOAD_VLAN_FILTER |
-						DEV_RX_OFFLOAD_VLAN_STRIP);
-			} else {
-				printf("Unknown parameter\n");
-				return;
-			}
-		} else if (!strcmp(res->name, "hw-vlan-filter")) {
-			if (!strcmp(res->value, "on"))
-				rx_offloads |= DEV_RX_OFFLOAD_VLAN_FILTER;
-			else if (!strcmp(res->value, "off"))
-				rx_offloads &= ~DEV_RX_OFFLOAD_VLAN_FILTER;
-			else {
-				printf("Unknown parameter\n");
-				return;
-			}
-		} else if (!strcmp(res->name, "hw-vlan-strip")) {
-			if (!strcmp(res->value, "on"))
-				rx_offloads |= DEV_RX_OFFLOAD_VLAN_STRIP;
-			else if (!strcmp(res->value, "off"))
-				rx_offloads &= ~DEV_RX_OFFLOAD_VLAN_STRIP;
-			else {
-				printf("Unknown parameter\n");
-				return;
-			}
-		} else if (!strcmp(res->name, "hw-vlan-extend")) {
-			if (!strcmp(res->value, "on"))
-				rx_offloads |= DEV_RX_OFFLOAD_VLAN_EXTEND;
-			else if (!strcmp(res->value, "off"))
-				rx_offloads &= ~DEV_RX_OFFLOAD_VLAN_EXTEND;
-			else {
-				printf("Unknown parameter\n");
-				return;
-			}
-		} else if (!strcmp(res->name, "drop-en")) {
-			if (!strcmp(res->value, "on"))
-				rx_drop_en = 1;
-			else if (!strcmp(res->value, "off"))
-				rx_drop_en = 0;
-			else {
-				printf("Unknown parameter\n");
-				return;
-			}
-		} else {
+	if (!strcmp(res->name, "drop-en")) {
+		if (!strcmp(res->value, "on"))
+			rx_drop_en = 1;
+		else if (!strcmp(res->value, "off"))
+			rx_drop_en = 0;
+		else {
 			printf("Unknown parameter\n");
 			return;
 		}
-		port->dev_conf.rxmode.offloads = rx_offloads;
-		/* Apply Rx offloads configuration */
-		for (k = 0; k < port->dev_info.max_rx_queues; k++)
-			port->rx_conf[k].offloads =
-				port->dev_conf.rxmode.offloads;
+	} else {
+		printf("Unknown parameter\n");
+		return;
 	}
 
 	init_port_config();
@@ -2231,8 +2141,7 @@ cmdline_parse_token_string_t cmd_config_rx_mode_flag_all =
 	TOKEN_STRING_INITIALIZER(struct cmd_config_rx_mode_flag, all, "all");
 cmdline_parse_token_string_t cmd_config_rx_mode_flag_name =
 	TOKEN_STRING_INITIALIZER(struct cmd_config_rx_mode_flag, name,
-					"crc-strip#scatter#rx-cksum#rx-timestamp#hw-vlan#"
-					"hw-vlan-filter#hw-vlan-strip#hw-vlan-extend");
+					"drop-en");
 cmdline_parse_token_string_t cmd_config_rx_mode_flag_value =
 	TOKEN_STRING_INITIALIZER(struct cmd_config_rx_mode_flag, value,
 							"on#off");
@@ -2240,8 +2149,7 @@ cmdline_parse_token_string_t cmd_config_rx_mode_flag_value =
 cmdline_parse_inst_t cmd_config_rx_mode_flag = {
 	.f = cmd_config_rx_mode_flag_parsed,
 	.data = NULL,
-	.help_str = "port config all crc-strip|scatter|rx-cksum|rx-timestamp|hw-vlan|"
-		"hw-vlan-filter|hw-vlan-strip|hw-vlan-extend on|off",
+	.help_str = "port config all drop-en on|off",
 	.tokens = {
 		(void *)&cmd_config_rx_mode_flag_port,
 		(void *)&cmd_config_rx_mode_flag_keyword,
diff --git a/doc/guides/rel_notes/release_19_08.rst b/doc/guides/rel_notes/release_19_08.rst
index c9bd3ce..4838187 100644
--- a/doc/guides/rel_notes/release_19_08.rst
+++ b/doc/guides/rel_notes/release_19_08.rst
@@ -237,6 +237,15 @@ Removed Items
    Also, make sure to start the actual text at the margin.
    =========================================================
 
+* Removed duplicated RX offloading set of commands from app/testpmd:
+  “port config all crc-strip|scatter|rx-cksum|rx-timestamp|hw-vlan|hw-vlan-filter|
+  hw-vlan-strip|hw-vlan-extend on|off”.
+
+  The testpmd commands set that can be used instead in order to enable or disable Rx
+  offloading on all Rx queues of a port is:
+  "port config <port_id> rx_offload crc_strip|scatter|ipv4_cksum|udp_cksum|tcp_cksum|
+  timestamp|vlan_strip|vlan_filter|vlan_extend on|off"
+
 * Removed KNI ethtool, CONFIG_RTE_KNI_KMOD_ETHTOOL, support.
 
 * build: armv8 crypto extension is disabled.
diff --git a/doc/guides/testpmd_app_ug/testpmd_funcs.rst b/doc/guides/testpmd_app_ug/testpmd_funcs.rst
index 313e070..67f4339 100644
--- a/doc/guides/testpmd_app_ug/testpmd_funcs.rst
+++ b/doc/guides/testpmd_app_ug/testpmd_funcs.rst
@@ -2099,91 +2099,14 @@ Set the maximum packet length::
 
 This is equivalent to the ``--max-pkt-len`` command-line option.
 
-port config - CRC Strip
-~~~~~~~~~~~~~~~~~~~~~~~
-
-Set hardware CRC stripping on or off for all ports::
-
-   testpmd> port config all crc-strip (on|off)
-
-CRC stripping is on by default.
-
-The ``off`` option is equivalent to the ``--disable-crc-strip`` command-line option.
-
-port config - scatter
-~~~~~~~~~~~~~~~~~~~~~~~
-
-Set RX scatter mode on or off for all ports::
-
-   testpmd> port config all scatter (on|off)
-
-RX scatter mode is off by default.
-
-The ``on`` option is equivalent to the ``--enable-scatter`` command-line option.
-
-port config - RX Checksum
-~~~~~~~~~~~~~~~~~~~~~~~~~
-
-Set hardware RX checksum offload to on or off for all ports::
-
-   testpmd> port config all rx-cksum (on|off)
-
-Checksum offload is off by default.
-
-The ``on`` option is equivalent to the ``--enable-rx-cksum`` command-line option.
-
-port config - VLAN
-~~~~~~~~~~~~~~~~~~
-
-Set hardware VLAN on or off for all ports::
-
-   testpmd> port config all hw-vlan (on|off)
-
-Hardware VLAN is off by default.
-
-The ``on`` option is equivalent to the ``--enable-hw-vlan`` command-line option.
-
-port config - VLAN filter
-~~~~~~~~~~~~~~~~~~~~~~~~~
-
-Set hardware VLAN filter on or off for all ports::
-
-   testpmd> port config all hw-vlan-filter (on|off)
-
-Hardware VLAN filter is off by default.
-
-The ``on`` option is equivalent to the ``--enable-hw-vlan-filter`` command-line option.
-
-port config - VLAN strip
-~~~~~~~~~~~~~~~~~~~~~~~~
-
-Set hardware VLAN strip on or off for all ports::
-
-   testpmd> port config all hw-vlan-strip (on|off)
-
-Hardware VLAN strip is off by default.
-
-The ``on`` option is equivalent to the ``--enable-hw-vlan-strip`` command-line option.
-
-port config - VLAN extend
-~~~~~~~~~~~~~~~~~~~~~~~~~
-
-Set hardware VLAN extend on or off for all ports::
-
-   testpmd> port config all hw-vlan-extend (on|off)
-
-Hardware VLAN extend is off by default.
-
-The ``on`` option is equivalent to the ``--enable-hw-vlan-extend`` command-line option.
-
 port config - Drop Packets
 ~~~~~~~~~~~~~~~~~~~~~~~~~~
 
-Set packet drop for packets with no descriptors on or off for all ports::
+Enable or disable packet drop on all RX queues of all ports when no receive buffers available::
 
    testpmd> port config all drop-en (on|off)
 
-Packet dropping for packets with no descriptors is off by default.
+Packet dropping when no receive buffers available is off by default.
 
 The ``on`` option is equivalent to the ``--enable-drop-en`` command-line option.
 
-- 
2.7.4


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [dpdk-stable] [PATCH] app/testpmd: remove duplicated support for Rx offloading
  2019-08-05 12:25 [dpdk-stable] [PATCH] app/testpmd: remove duplicated support for Rx offloading Flavia Musatescu
@ 2019-08-27  8:48 ` Ferruh Yigit
  2019-08-27 16:43 ` [dpdk-stable] [PATCH v2] " Flavia Musatescu
  1 sibling, 0 replies; 4+ messages in thread
From: Ferruh Yigit @ 2019-08-27  8:48 UTC (permalink / raw)
  To: Flavia Musatescu, dev, Wenzhuo Lu, Jingjing Wu,
	Bernard Iremonger, John McNamara, Marko Kovacevic
  Cc: stable, shahafs

On 8/5/2019 1:25 PM, Flavia Musatescu wrote:
> The testpmd application provides two sets of commands for RX offload
> flags configuration. The purpose of this patch is to eliminate this
> duplication by removing the old set of commands:
> “port config all crc-strip|scatter|rx-cksum|rx-timestamp|hw-vlan|
> hw-vlan-filter|hw-vlan-strip|hw-vlan-extend on|off”
> 
> The other commands set that can be used instead in order to enable
> or disable the same RX offloading flags on all RX queues of a port is:
> "port config <port_id> rx_offload crc_strip|scatter|ipv4_cksum|
> udp_cksum|tcp_cksum|timestamp|vlan_strip|vlan_filter|vlan_extend on|off"
> 
> This patch also fixes the "drop-en" command, which enables packets
> dropping on all RX queues of all ports when no receive buffers available
> “port config all drop-en on|off”
> 
> Fixes: 384161e00627 ("app/testpmd: adjust on the fly VLAN configuration")
> Cc: shahafs@mellanox.com
> Cc: stable@dpdk.org
> 
> Signed-off-by: Flavia Musatescu <flavia.musatescu@intel.com>
> ---
>  app/test-pmd/cmdline.c                      | 120 ++++------------------------
>  doc/guides/rel_notes/release_19_08.rst      |   9 +++

Hi Flavia,

Can you please send a new version with the 19.11 release notes update?

>  doc/guides/testpmd_app_ug/testpmd_funcs.rst |  81 +------------------
>  3 files changed, 25 insertions(+), 185 deletions(-)

<...>


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [dpdk-stable] [PATCH v2] app/testpmd: remove duplicated support for Rx offloading
  2019-08-05 12:25 [dpdk-stable] [PATCH] app/testpmd: remove duplicated support for Rx offloading Flavia Musatescu
  2019-08-27  8:48 ` Ferruh Yigit
@ 2019-08-27 16:43 ` " Flavia Musatescu
  2019-08-28  9:29   ` Ferruh Yigit
  1 sibling, 1 reply; 4+ messages in thread
From: Flavia Musatescu @ 2019-08-27 16:43 UTC (permalink / raw)
  To: dev, Wenzhuo Lu, Jingjing Wu, Bernard Iremonger, John McNamara,
	Marko Kovacevic
  Cc: stable, Flavia Musatescu, shahafs

The testpmd application provides two sets of commands for RX offload
flags configuration. The purpose of this patch is to eliminate this
duplication by removing the old set of commands:
“port config all crc-strip|scatter|rx-cksum|rx-timestamp|hw-vlan|
hw-vlan-filter|hw-vlan-strip|hw-vlan-extend on|off”

The other commands set that can be used instead in order to enable
or disable the same RX offloading flags on all RX queues of a port is:
"port config <port_id> rx_offload crc_strip|scatter|ipv4_cksum|
udp_cksum|tcp_cksum|timestamp|vlan_strip|vlan_filter|vlan_extend on|off"

This patch also fixes the "drop-en" command, which enables packets
dropping on all RX queues of all ports when no receive buffers available
“port config all drop-en on|off”

Fixes: 384161e00627 ("app/testpmd: adjust on the fly VLAN configuration")
Cc: shahafs@mellanox.com
Cc: stable@dpdk.org

Signed-off-by: Flavia Musatescu <flavia.musatescu@intel.com>
---
 app/test-pmd/cmdline.c                      | 120 ++++------------------------
 doc/guides/rel_notes/release_19_11.rst      |   9 +++
 doc/guides/testpmd_app_ug/testpmd_funcs.rst |  81 +------------------
 3 files changed, 25 insertions(+), 185 deletions(-)

diff --git a/app/test-pmd/cmdline.c b/app/test-pmd/cmdline.c
index 56783aa..b6bc34b 100644
--- a/app/test-pmd/cmdline.c
+++ b/app/test-pmd/cmdline.c
@@ -778,11 +778,9 @@ static void cmd_help_long_parsed(void *parsed_result,
 			"port config all max-pkt-len (value)\n"
 			"    Set the max packet length.\n\n"
 
-			"port config all (crc-strip|scatter|rx-cksum|rx-timestamp|hw-vlan|hw-vlan-filter|"
-			"hw-vlan-strip|hw-vlan-extend|drop-en)"
-			" (on|off)\n"
-			"    Set crc-strip/scatter/rx-checksum/hardware-vlan/drop_en"
-			" for ports.\n\n"
+			"port config all drop-en (on|off)\n"
+			"    Enable or disable packet drop on all RX queues of all ports when no "
+			"receive buffers available.\n\n"
 
 			"port config all rss (all|default|ip|tcp|udp|sctp|"
 			"ether|port|vxlan|geneve|nvgre|vxlan-gpe|none|<flowtype_id>)\n"
@@ -2109,112 +2107,24 @@ cmd_config_rx_mode_flag_parsed(void *parsed_result,
 				__attribute__((unused)) void *data)
 {
 	struct cmd_config_rx_mode_flag *res = parsed_result;
-	portid_t pid;
-	int k;
 
 	if (!all_ports_stopped()) {
 		printf("Please stop all ports first\n");
 		return;
 	}
 
-	RTE_ETH_FOREACH_DEV(pid) {
-		struct rte_port *port;
-		uint64_t rx_offloads;
-
-		port = &ports[pid];
-		rx_offloads = port->dev_conf.rxmode.offloads;
-		if (!strcmp(res->name, "crc-strip")) {
-			if (!strcmp(res->value, "on")) {
-				rx_offloads &= ~DEV_RX_OFFLOAD_KEEP_CRC;
-			} else if (!strcmp(res->value, "off")) {
-				rx_offloads |= DEV_RX_OFFLOAD_KEEP_CRC;
-			} else {
-				printf("Unknown parameter\n");
-				return;
-			}
-		} else if (!strcmp(res->name, "scatter")) {
-			if (!strcmp(res->value, "on")) {
-				rx_offloads |= DEV_RX_OFFLOAD_SCATTER;
-			} else if (!strcmp(res->value, "off")) {
-				rx_offloads &= ~DEV_RX_OFFLOAD_SCATTER;
-			} else {
-				printf("Unknown parameter\n");
-				return;
-			}
-		} else if (!strcmp(res->name, "rx-cksum")) {
-			if (!strcmp(res->value, "on"))
-				rx_offloads |= DEV_RX_OFFLOAD_CHECKSUM;
-			else if (!strcmp(res->value, "off"))
-				rx_offloads &= ~DEV_RX_OFFLOAD_CHECKSUM;
-			else {
-				printf("Unknown parameter\n");
-				return;
-			}
-		} else if (!strcmp(res->name, "rx-timestamp")) {
-			if (!strcmp(res->value, "on"))
-				rx_offloads |= DEV_RX_OFFLOAD_TIMESTAMP;
-			else if (!strcmp(res->value, "off"))
-				rx_offloads &= ~DEV_RX_OFFLOAD_TIMESTAMP;
-			else {
-				printf("Unknown parameter\n");
-				return;
-			}
-		} else if (!strcmp(res->name, "hw-vlan")) {
-			if (!strcmp(res->value, "on")) {
-				rx_offloads |= (DEV_RX_OFFLOAD_VLAN_FILTER |
-						DEV_RX_OFFLOAD_VLAN_STRIP);
-			} else if (!strcmp(res->value, "off")) {
-				rx_offloads &= ~(DEV_RX_OFFLOAD_VLAN_FILTER |
-						DEV_RX_OFFLOAD_VLAN_STRIP);
-			} else {
-				printf("Unknown parameter\n");
-				return;
-			}
-		} else if (!strcmp(res->name, "hw-vlan-filter")) {
-			if (!strcmp(res->value, "on"))
-				rx_offloads |= DEV_RX_OFFLOAD_VLAN_FILTER;
-			else if (!strcmp(res->value, "off"))
-				rx_offloads &= ~DEV_RX_OFFLOAD_VLAN_FILTER;
-			else {
-				printf("Unknown parameter\n");
-				return;
-			}
-		} else if (!strcmp(res->name, "hw-vlan-strip")) {
-			if (!strcmp(res->value, "on"))
-				rx_offloads |= DEV_RX_OFFLOAD_VLAN_STRIP;
-			else if (!strcmp(res->value, "off"))
-				rx_offloads &= ~DEV_RX_OFFLOAD_VLAN_STRIP;
-			else {
-				printf("Unknown parameter\n");
-				return;
-			}
-		} else if (!strcmp(res->name, "hw-vlan-extend")) {
-			if (!strcmp(res->value, "on"))
-				rx_offloads |= DEV_RX_OFFLOAD_VLAN_EXTEND;
-			else if (!strcmp(res->value, "off"))
-				rx_offloads &= ~DEV_RX_OFFLOAD_VLAN_EXTEND;
-			else {
-				printf("Unknown parameter\n");
-				return;
-			}
-		} else if (!strcmp(res->name, "drop-en")) {
-			if (!strcmp(res->value, "on"))
-				rx_drop_en = 1;
-			else if (!strcmp(res->value, "off"))
-				rx_drop_en = 0;
-			else {
-				printf("Unknown parameter\n");
-				return;
-			}
-		} else {
+	if (!strcmp(res->name, "drop-en")) {
+		if (!strcmp(res->value, "on"))
+			rx_drop_en = 1;
+		else if (!strcmp(res->value, "off"))
+			rx_drop_en = 0;
+		else {
 			printf("Unknown parameter\n");
 			return;
 		}
-		port->dev_conf.rxmode.offloads = rx_offloads;
-		/* Apply Rx offloads configuration */
-		for (k = 0; k < port->dev_info.max_rx_queues; k++)
-			port->rx_conf[k].offloads =
-				port->dev_conf.rxmode.offloads;
+	} else {
+		printf("Unknown parameter\n");
+		return;
 	}
 
 	init_port_config();
@@ -2231,8 +2141,7 @@ cmdline_parse_token_string_t cmd_config_rx_mode_flag_all =
 	TOKEN_STRING_INITIALIZER(struct cmd_config_rx_mode_flag, all, "all");
 cmdline_parse_token_string_t cmd_config_rx_mode_flag_name =
 	TOKEN_STRING_INITIALIZER(struct cmd_config_rx_mode_flag, name,
-					"crc-strip#scatter#rx-cksum#rx-timestamp#hw-vlan#"
-					"hw-vlan-filter#hw-vlan-strip#hw-vlan-extend");
+					"drop-en");
 cmdline_parse_token_string_t cmd_config_rx_mode_flag_value =
 	TOKEN_STRING_INITIALIZER(struct cmd_config_rx_mode_flag, value,
 							"on#off");
@@ -2240,8 +2149,7 @@ cmdline_parse_token_string_t cmd_config_rx_mode_flag_value =
 cmdline_parse_inst_t cmd_config_rx_mode_flag = {
 	.f = cmd_config_rx_mode_flag_parsed,
 	.data = NULL,
-	.help_str = "port config all crc-strip|scatter|rx-cksum|rx-timestamp|hw-vlan|"
-		"hw-vlan-filter|hw-vlan-strip|hw-vlan-extend on|off",
+	.help_str = "port config all drop-en on|off",
 	.tokens = {
 		(void *)&cmd_config_rx_mode_flag_port,
 		(void *)&cmd_config_rx_mode_flag_keyword,
diff --git a/doc/guides/rel_notes/release_19_11.rst b/doc/guides/rel_notes/release_19_11.rst
index 8490d89..27cfbd9 100644
--- a/doc/guides/rel_notes/release_19_11.rst
+++ b/doc/guides/rel_notes/release_19_11.rst
@@ -69,6 +69,15 @@ Removed Items
    Also, make sure to start the actual text at the margin.
    =========================================================
 
+   * Removed duplicated set of commands for RX offloading configuration from app/testpmd:
+     “port config all crc-strip|scatter|rx-cksum|rx-timestamp|hw-vlan|hw-vlan-filter|
+     hw-vlan-strip|hw-vlan-extend on|off”.
+
+     The testpmd commands set that can be used instead in order to enable or disable Rx
+     offloading on all Rx queues of a port is:
+     "port config <port_id> rx_offload crc_strip|scatter|ipv4_cksum|udp_cksum|tcp_cksum|
+     timestamp|vlan_strip|vlan_filter|vlan_extend on|off"
+
 
 API Changes
 -----------
diff --git a/doc/guides/testpmd_app_ug/testpmd_funcs.rst b/doc/guides/testpmd_app_ug/testpmd_funcs.rst
index 313e070..67f4339 100644
--- a/doc/guides/testpmd_app_ug/testpmd_funcs.rst
+++ b/doc/guides/testpmd_app_ug/testpmd_funcs.rst
@@ -2099,91 +2099,14 @@ Set the maximum packet length::
 
 This is equivalent to the ``--max-pkt-len`` command-line option.
 
-port config - CRC Strip
-~~~~~~~~~~~~~~~~~~~~~~~
-
-Set hardware CRC stripping on or off for all ports::
-
-   testpmd> port config all crc-strip (on|off)
-
-CRC stripping is on by default.
-
-The ``off`` option is equivalent to the ``--disable-crc-strip`` command-line option.
-
-port config - scatter
-~~~~~~~~~~~~~~~~~~~~~~~
-
-Set RX scatter mode on or off for all ports::
-
-   testpmd> port config all scatter (on|off)
-
-RX scatter mode is off by default.
-
-The ``on`` option is equivalent to the ``--enable-scatter`` command-line option.
-
-port config - RX Checksum
-~~~~~~~~~~~~~~~~~~~~~~~~~
-
-Set hardware RX checksum offload to on or off for all ports::
-
-   testpmd> port config all rx-cksum (on|off)
-
-Checksum offload is off by default.
-
-The ``on`` option is equivalent to the ``--enable-rx-cksum`` command-line option.
-
-port config - VLAN
-~~~~~~~~~~~~~~~~~~
-
-Set hardware VLAN on or off for all ports::
-
-   testpmd> port config all hw-vlan (on|off)
-
-Hardware VLAN is off by default.
-
-The ``on`` option is equivalent to the ``--enable-hw-vlan`` command-line option.
-
-port config - VLAN filter
-~~~~~~~~~~~~~~~~~~~~~~~~~
-
-Set hardware VLAN filter on or off for all ports::
-
-   testpmd> port config all hw-vlan-filter (on|off)
-
-Hardware VLAN filter is off by default.
-
-The ``on`` option is equivalent to the ``--enable-hw-vlan-filter`` command-line option.
-
-port config - VLAN strip
-~~~~~~~~~~~~~~~~~~~~~~~~
-
-Set hardware VLAN strip on or off for all ports::
-
-   testpmd> port config all hw-vlan-strip (on|off)
-
-Hardware VLAN strip is off by default.
-
-The ``on`` option is equivalent to the ``--enable-hw-vlan-strip`` command-line option.
-
-port config - VLAN extend
-~~~~~~~~~~~~~~~~~~~~~~~~~
-
-Set hardware VLAN extend on or off for all ports::
-
-   testpmd> port config all hw-vlan-extend (on|off)
-
-Hardware VLAN extend is off by default.
-
-The ``on`` option is equivalent to the ``--enable-hw-vlan-extend`` command-line option.
-
 port config - Drop Packets
 ~~~~~~~~~~~~~~~~~~~~~~~~~~
 
-Set packet drop for packets with no descriptors on or off for all ports::
+Enable or disable packet drop on all RX queues of all ports when no receive buffers available::
 
    testpmd> port config all drop-en (on|off)
 
-Packet dropping for packets with no descriptors is off by default.
+Packet dropping when no receive buffers available is off by default.
 
 The ``on`` option is equivalent to the ``--enable-drop-en`` command-line option.
 
-- 
2.7.4


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [dpdk-stable] [PATCH v2] app/testpmd: remove duplicated support for Rx offloading
  2019-08-27 16:43 ` [dpdk-stable] [PATCH v2] " Flavia Musatescu
@ 2019-08-28  9:29   ` Ferruh Yigit
  0 siblings, 0 replies; 4+ messages in thread
From: Ferruh Yigit @ 2019-08-28  9:29 UTC (permalink / raw)
  To: Flavia Musatescu, dev, Wenzhuo Lu, Jingjing Wu,
	Bernard Iremonger, John McNamara, Marko Kovacevic
  Cc: stable, shahafs

On 8/27/2019 5:43 PM, Flavia Musatescu wrote:
> The testpmd application provides two sets of commands for RX offload
> flags configuration. The purpose of this patch is to eliminate this
> duplication by removing the old set of commands:
> “port config all crc-strip|scatter|rx-cksum|rx-timestamp|hw-vlan|
> hw-vlan-filter|hw-vlan-strip|hw-vlan-extend on|off”
> 
> The other commands set that can be used instead in order to enable
> or disable the same RX offloading flags on all RX queues of a port is:
> "port config <port_id> rx_offload crc_strip|scatter|ipv4_cksum|
> udp_cksum|tcp_cksum|timestamp|vlan_strip|vlan_filter|vlan_extend on|off"
> 
> This patch also fixes the "drop-en" command, which enables packets
> dropping on all RX queues of all ports when no receive buffers available
> “port config all drop-en on|off”
> 
> Fixes: 384161e00627 ("app/testpmd: adjust on the fly VLAN configuration")
> Cc: shahafs@mellanox.com
> Cc: stable@dpdk.org
> 
> Signed-off-by: Flavia Musatescu <flavia.musatescu@intel.com>

Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>

Applied to dpdk-next-net/master, thanks.

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, back to index

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-08-05 12:25 [dpdk-stable] [PATCH] app/testpmd: remove duplicated support for Rx offloading Flavia Musatescu
2019-08-27  8:48 ` Ferruh Yigit
2019-08-27 16:43 ` [dpdk-stable] [PATCH v2] " Flavia Musatescu
2019-08-28  9:29   ` Ferruh Yigit

patches for DPDK stable branches

Archives are clonable:
	git clone --mirror http://inbox.dpdk.org/stable/0 stable/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 stable stable/ http://inbox.dpdk.org/stable \
		stable@dpdk.org
	public-inbox-index stable


Newsgroup available over NNTP:
	nntp://inbox.dpdk.org/inbox.dpdk.stable


AGPL code for this site: git clone https://public-inbox.org/ public-inbox