DPDK patches and discussions
 help / color / mirror / Atom feed
* [dpdk-dev] [PATCH] examples/l3fwd: update documentation
@ 2016-06-23  9:04 Beilei Xing
  2016-06-24 15:47 ` Mcnamara, John
  2016-06-27 14:26 ` [dpdk-dev] [PATCH v2] examples/l3fwd: update usage and documentation Beilei Xing
  0 siblings, 2 replies; 5+ messages in thread
From: Beilei Xing @ 2016-06-23  9:04 UTC (permalink / raw)
  To: john.mcnamara; +Cc: dev, Beilei Xing

Update l3fwd documentation with -E, -L and --eth-dest options.

Signed-off-by: Beilei Xing <beilei.xing@intel.com>
---
 doc/guides/sample_app_ug/l3_forward.rst | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/doc/guides/sample_app_ug/l3_forward.rst b/doc/guides/sample_app_ug/l3_forward.rst
index 491f99d..4ab5149 100644
--- a/doc/guides/sample_app_ug/l3_forward.rst
+++ b/doc/guides/sample_app_ug/l3_forward.rst
@@ -101,8 +101,14 @@ where,
 *   -P: optional, sets all ports to promiscuous mode so that packets are accepted regardless of the packet's Ethernet MAC destination address.
     Without this option, only packets with the Ethernet MAC destination address set to the Ethernet address of the port are accepted.
 
+*   -E: enable exact match
+
+*   -L: enable longest prefix match
+
 *   --config (port,queue,lcore)[,(port,queue,lcore)]: determines which queues from which ports are mapped to which cores
 
+*   --eth-dest=X,MM:MM:MM:MM:MM:MM: optional, ethernet destination for port X
+
 *   --enable-jumbo: optional, enables jumbo frames
 
 *   --max-pkt-len: optional, maximum packet length in decimal (64-9600)
@@ -113,7 +119,7 @@ where,
 
 *   --ipv6: optional, set it if running ipv6 packets
 
-*   --parse-ptype: optional, set it if use software way to analyze packet type
+*   --parse-ptype: optional, set it if use software way to analyze packet type. Without this option, HW will check packet type.
 
 For example, consider a dual processor socket platform where cores 0-7 and 16-23 appear on socket 0, while cores 8-15 and 24-31 appear on socket 1.
 Let's say that the programmer wants to use memory from both NUMA nodes, the platform has only two ports, one connected to each NUMA node,
-- 
2.5.0

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

* Re: [dpdk-dev] [PATCH] examples/l3fwd: update documentation
  2016-06-23  9:04 [dpdk-dev] [PATCH] examples/l3fwd: update documentation Beilei Xing
@ 2016-06-24 15:47 ` Mcnamara, John
  2016-06-27 14:26 ` [dpdk-dev] [PATCH v2] examples/l3fwd: update usage and documentation Beilei Xing
  1 sibling, 0 replies; 5+ messages in thread
From: Mcnamara, John @ 2016-06-24 15:47 UTC (permalink / raw)
  To: Xing, Beilei; +Cc: dev

> -----Original Message-----
> From: Xing, Beilei
> Sent: Thursday, June 23, 2016 10:05 AM
> To: Mcnamara, John <john.mcnamara@intel.com>
> Cc: dev@dpdk.org; Xing, Beilei <beilei.xing@intel.com>
> Subject: [PATCH] examples/l3fwd: update documentation
> 
> Update l3fwd documentation with -E, -L and --eth-dest options.
> 

Hi,

Thanks for the doc fixes.


The usage example just before this should also be updated to add these
(and a few other) missing options. Something like:

    ./l3fwd [EAL options] -- -p PORTMASK
                             [-P]
                             [-E]
                             [-L]
                             --config(port,queue,lcore)[,(port,queue,lcore)]
                             [--eth-dest=X,MM:MM:MM:MM:MM:MM]
                             [--enable-jumbo]
                             [--max-pkt-len PKTLEN]]
                             [--no-numa]
                             [--hash-entry-num]
                             [--ipv6]
                             [--parse-ptype]



> +*   -E: enable exact match

The options would look better in fixed width quotes:

    * ``-E:`` Enable exact match.


> +*   --parse-ptype: optional, set it if use software way to analyze packet
> type. Without this option, HW will check packet type.

Maybe better as:

    * ``--parse-ptype:`` Optional, set to use software to analyze packet type. Without this option, hardware will check the packet type.

Note, the l3fwd main.c usage should also be updated to add these options
and fix missing (and incorrect) options. I'll send you a patch for that
and you can integrate it with your changes.

John

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

* [dpdk-dev] [PATCH v2] examples/l3fwd: update usage and documentation
  2016-06-23  9:04 [dpdk-dev] [PATCH] examples/l3fwd: update documentation Beilei Xing
  2016-06-24 15:47 ` Mcnamara, John
@ 2016-06-27 14:26 ` Beilei Xing
  2016-06-27 15:47   ` Mcnamara, John
  1 sibling, 1 reply; 5+ messages in thread
From: Beilei Xing @ 2016-06-27 14:26 UTC (permalink / raw)
  To: john.mcnamara; +Cc: dev, Beilei Xing

Update l3fwd example usage and documentation with missing options.

Signed-off-by: Beilei Xing <beilei.xing@intel.com>
---
v2 changes:
 Update l3fwd main.c usage
 Update format in documentation.

 doc/guides/sample_app_ug/l3_forward.rst | 42 ++++++++++++++++++++++-----------
 examples/l3fwd/main.c                   | 40 ++++++++++++++++++++-----------
 2 files changed, 54 insertions(+), 28 deletions(-)

diff --git a/doc/guides/sample_app_ug/l3_forward.rst b/doc/guides/sample_app_ug/l3_forward.rst
index 491f99d..c885cdb 100644
--- a/doc/guides/sample_app_ug/l3_forward.rst
+++ b/doc/guides/sample_app_ug/l3_forward.rst
@@ -88,32 +88,46 @@ To compile the application:
 Running the Application
 -----------------------
 
-The application has a number of command line options:
+The application has a number of command line options::
 
-.. code-block:: console
+    ./l3fwd [EAL options] -- -p PORTMASK
+                             [-P]
+                             [-E]
+                             [-L]
+                             --config(port,queue,lcore)[,(port,queue,lcore)]
+                             [--eth-dest=X,MM:MM:MM:MM:MM:MM]
+                             [--enable-jumbo [--max-pkt-len PKTLEN]]
+                             [--no-numa]
+                             [--hash-entry-num]
+                             [--ipv6]
+                             [--parse-ptype]
+
+Where,
+
+* ``-p PORTMASK:`` Hexadecimal bitmask of ports to configure
 
-    ./build/l3fwd [EAL options] -- -p PORTMASK [-P]  --config(port,queue,lcore)[,(port,queue,lcore)] [--enable-jumbo [--max-pkt-len PKTLEN]]  [--no-numa][--hash-entry-num][--ipv6] [--parse-ptype]
+* ``-P:`` Optional, sets all ports to promiscuous mode so that packets are accepted regardless of the packet's Ethernet MAC destination address.
+  Without this option, only packets with the Ethernet MAC destination address set to the Ethernet address of the port are accepted.
 
-where,
+* ``-E:`` Optional, enable exact match.
 
-*   -p PORTMASK: Hexadecimal bitmask of ports to configure
+* ``-L:`` Optional, enable longest prefix match.
 
-*   -P: optional, sets all ports to promiscuous mode so that packets are accepted regardless of the packet's Ethernet MAC destination address.
-    Without this option, only packets with the Ethernet MAC destination address set to the Ethernet address of the port are accepted.
+* ``--config (port,queue,lcore)[,(port,queue,lcore)]:`` Determines which queues from which ports are mapped to which cores.
 
-*   --config (port,queue,lcore)[,(port,queue,lcore)]: determines which queues from which ports are mapped to which cores
+* ``--eth-dest=X,MM:MM:MM:MM:MM:MM:`` Optional, ethernet destination for port X.
 
-*   --enable-jumbo: optional, enables jumbo frames
+* ``--enable-jumbo:`` Optional, enables jumbo frames.
 
-*   --max-pkt-len: optional, maximum packet length in decimal (64-9600)
+* ``--max-pkt-len:`` Optional, under the premise of enabling jumbo, maximum packet length in decimal (64-9600).
 
-*   --no-numa: optional, disables numa awareness
+* ``--no-numa:`` Optional, disables numa awareness.
 
-*   --hash-entry-num: optional, specifies the hash entry number in hexadecimal to be setup
+* ``--hash-entry-num:`` Optional, specifies the hash entry number in hexadecimal to be setup.
 
-*   --ipv6: optional, set it if running ipv6 packets
+* ``--ipv6:`` Optional, set if running ipv6 packets.
 
-*   --parse-ptype: optional, set it if use software way to analyze packet type
+* ``--parse-ptype:`` Optional, set to use software to analyze packet type. Without this option, hardware will check the packet type.
 
 For example, consider a dual processor socket platform where cores 0-7 and 16-23 appear on socket 0, while cores 8-15 and 24-31 appear on socket 1.
 Let's say that the programmer wants to use memory from both NUMA nodes, the platform has only two ports, one connected to each NUMA node,
diff --git a/examples/l3fwd/main.c b/examples/l3fwd/main.c
index 7a79cd2..acedd20 100644
--- a/examples/l3fwd/main.c
+++ b/examples/l3fwd/main.c
@@ -311,20 +311,32 @@ init_lcore_rx_queues(void)
 static void
 print_usage(const char *prgname)
 {
-	printf ("%s [EAL options] -- -p PORTMASK -P"
-		"  [--config (port,queue,lcore)[,(port,queue,lcore]]"
-		"  [--enable-jumbo [--max-pkt-len PKTLEN]]\n"
-		"  -p PORTMASK: hexadecimal bitmask of ports to configure\n"
-		"  -P : enable promiscuous mode\n"
-		"  -E : enable exact match\n"
-		"  -L : enable longest prefix match\n"
-		"  --config (port,queue,lcore): rx queues configuration\n"
-		"  --eth-dest=X,MM:MM:MM:MM:MM:MM: optional, ethernet destination for port X\n"
-		"  --no-numa: optional, disable numa awareness\n"
-		"  --ipv6: optional, specify it if running ipv6 packets\n"
-		"  --enable-jumbo: enable jumbo frame"
-		" which max packet len is PKTLEN in decimal (64-9600)\n"
-		"  --hash-entry-num: specify the hash entry number in hexadecimal to be setup\n",
+	printf("%s [EAL options] --"
+		" -p PORTMASK"
+		" [-P]"
+		" [-E]"
+		" [-L]"
+		" --config (port,queue,lcore)[,(port,queue,lcore)]"
+		" [--eth-dest=X,MM:MM:MM:MM:MM:MM]"
+		" [--enable-jumbo [--max-pkt-len PKTLEN]]"
+		" [--no-numa]"
+		" [--hash-entry-num]"
+		" [--ipv6]"
+		" [--parse-ptype]\n\n"
+
+		"  -p PORTMASK: Hexadecimal bitmask of ports to configure\n"
+		"  -P : Enable promiscuous mode\n"
+		"  -E : Enable exact match\n"
+		"  -L : Enable longest prefix match (default)\n"
+		"  --config (port,queue,lcore): Rx queue configuration\n"
+		"  --eth-dest=X,MM:MM:MM:MM:MM:MM: Ethernet destination for port X\n"
+		"  --enable-jumbo: Enable jumbo frames\n"
+		"  --max-pkt-len: Under the premise of enabling jumbo,\n"
+		"                 maximum packet length in decimal (64-9600)\n"
+		"  --no-numa: Disable numa awareness\n"
+		"  --hash-entry-num: Specify the hash entry number in hexadecimal to be setup\n"
+		"  --ipv6: Set if running ipv6 packets\n"
+		"  --parse-ptype: Set to use software to analyze packet type\n\n",
 		prgname);
 }
 
-- 
2.5.0

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

* Re: [dpdk-dev] [PATCH v2] examples/l3fwd: update usage and documentation
  2016-06-27 14:26 ` [dpdk-dev] [PATCH v2] examples/l3fwd: update usage and documentation Beilei Xing
@ 2016-06-27 15:47   ` Mcnamara, John
  2016-07-11 14:37     ` Thomas Monjalon
  0 siblings, 1 reply; 5+ messages in thread
From: Mcnamara, John @ 2016-06-27 15:47 UTC (permalink / raw)
  To: Xing, Beilei; +Cc: dev



> -----Original Message-----
> From: Xing, Beilei
> Sent: Monday, June 27, 2016 3:27 PM
> To: Mcnamara, John <john.mcnamara@intel.com>
> Cc: dev@dpdk.org; Xing, Beilei <beilei.xing@intel.com>
> Subject: [PATCH v2] examples/l3fwd: update usage and documentation
> 
> Update l3fwd example usage and documentation with missing options.
> 
> Signed-off-by: Beilei Xing <beilei.xing@intel.com>

Acked-by: John McNamara <john.mcnamara@intel.com>

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

* Re: [dpdk-dev] [PATCH v2] examples/l3fwd: update usage and documentation
  2016-06-27 15:47   ` Mcnamara, John
@ 2016-07-11 14:37     ` Thomas Monjalon
  0 siblings, 0 replies; 5+ messages in thread
From: Thomas Monjalon @ 2016-07-11 14:37 UTC (permalink / raw)
  To: Xing, Beilei; +Cc: dev, Mcnamara, John

> > Update l3fwd example usage and documentation with missing options.
> > 
> > Signed-off-by: Beilei Xing <beilei.xing@intel.com>
> 
> Acked-by: John McNamara <john.mcnamara@intel.com>

Applied, thanks

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

end of thread, other threads:[~2016-07-11 14:37 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-06-23  9:04 [dpdk-dev] [PATCH] examples/l3fwd: update documentation Beilei Xing
2016-06-24 15:47 ` Mcnamara, John
2016-06-27 14:26 ` [dpdk-dev] [PATCH v2] examples/l3fwd: update usage and documentation Beilei Xing
2016-06-27 15:47   ` Mcnamara, John
2016-07-11 14:37     ` Thomas Monjalon

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).