pktgen: cleanups and introducing new samples/pktgen scripts
Get series with b4
b4 am 20150521101501.15148.10609.stgit@ivyVersions newest first · linked by author and title
- v3 Latest10 patches 1 replyIn review
- v22 of 10 patches 1 replySuperseded
- v110 patches 5 repliesSuperseded
Changes in v3 from the cover letter
- Aborted v2 send due it was not generating diff stat (this is a bug in stg-mail, if not in the root directory)
Patches in v3 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/10 | pktgen: remove obsolete "max_before_softirq" from pktgen docDocumentation/ | +8 | 0 replies | |
| 2/10 | pktgen: adjust spacing in proc file interface outputnet/ | +1 | 0 replies | |
| 3/10 | pktgen: doc were missing several config optionsDocumentation/ | +24 | 0 replies | |
| 4/10 | pktgen: document ability to add same device to several threadsDocumentation/ | +50 | 0 replies | |
| 5/10 | pktgen: make /proc/net/pktgen/pgctrl report fail on invalid inputnet/ | +2 | 0 replies | |
| 6/10 | pktgen: new pktgen helper functions for samples scriptssamples/ samples/ samples/ | +261 | 0 replies | |
| 7/10 | pktgen: add sample script pktgen_sample01_simple.shDocumentation/ samples/ samples/ | +94 | 0 replies | |
| 8/10 | pktgen: add sample script pktgen_sample02_multiqueue.shDocumentation/ samples/ samples/ +1 more | +75 | 0 replies | |
| 9/10 | pktgen: add sample script pktgen_sample03_burst_single_flow.shsamples/ | +82 | 0 replies | |
| 10/10 | pktgen: add benchmark script pktgen_bench_xmit_mode_netif_receive.shsamples/ | +86 | 0 replies |
Reviews trailers per patch
1 of 10 patches has a Reviewed-by or Acked-by.
| Patch | Alexei Starovoitov |
|---|---|
| 1/10 | |
| 2/10 | |
| 3/10 | |
| 4/10 | A-b |
| 5/10 | |
| 6/10 | |
| 7/10 | |
| 8/10 | |
| 9/10 | |
| 10/10 |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [net-next PATCH v3 00/10] pktgen: cleanups and introducing new samples/pktgen scripts
v3:
- Aborted v2 send due it was not generating diff stat (this is a bug in stg-mail, if not in the root directory)
v2: address nitpicks from Cong Wang
- Remove useless cat's, but keep them for old pgset()
- Comment on: Due to pgctrl, cannot use exit code $? from grep
- Use arithmetic compare in pktgen_sample03_burst_single_flow.sh
This patchset is focused on making pktgen easier to use and better documented. It contains a number of documentation updates and minor changes to pktgen. The major contribution is introduction of common helper function for sample scripts.
Instead of the old pgset() function, three new shell functions for configuring the different components of pktgen are introduced:
pg_ctrl(), pg_thread() and pg_set().
The new functions correspond to pktgens different components.
* pg_ctrl() control "pgctrl" (/proc/net/pktgen/pgctrl)
* pg_thread() control the kernel threads and binding to devices
* pg_set() control setup of individual devices
Helpers also provide consistent parameter parsing across the sample scripts.
Usage example:
./pktgen_sample01_simple.sh -i eth41 -m 00:12:C0:02:AC:5A -d 192.168.41.2
Usage: ./pktgen_sample01_simple.sh [-vx] -i ethX
-i : ($DEV) output interface/device (required) -s : ($PKT_SIZE) packet size -d : ($DEST_IP) destination IP -m : ($DST_MAC) destination MAC-addr -t : ($THREADS) threads to start -c : ($SKB_CLONE) SKB clones send before alloc new SKB -b : ($BURST) HW level bursting of SKBs -v : ($VERBOSE) verbose -x : ($DEBUG) debug
These scripts are borrowed from:
https://github.com/netoptimizer/network-testing/tree/master/pktgen
---
Jesper Dangaard Brouer (10):
pktgen: add benchmark script pktgen_bench_xmit_mode_netif_receive.sh
pktgen: add sample script pktgen_sample03_burst_single_flow.sh
pktgen: add sample script pktgen_sample02_multiqueue.sh
pktgen: add sample script pktgen_sample01_simple.sh
pktgen: new pktgen helper functions for samples scripts
pktgen: make /proc/net/pktgen/pgctrl report fail on invalid input
pktgen: document ability to add same device to several threads
pktgen: doc were missing several config options
pktgen: adjust spacing in proc file interface output
pktgen: remove obsolete "max_before_softirq" from pktgen doc
Documentation/networking/pktgen.txt | 141 ++++++++++++++------ net/core/pktgen.c | 6 - samples/pktgen/README.rst | 43 ++++++ samples/pktgen/functions.sh | 121 +++++++++++++++++ samples/pktgen/parameters.sh | 97 ++++++++++++++ samples/pktgen/pktgen.conf-1-1 | 59 -------- samples/pktgen/pktgen.conf-2-1 | 66 --------- samples/pktgen/pktgen.conf-2-2 | 73 ---------- .../pktgen/pktgen_bench_xmit_mode_netif_receive.sh | 86 ++++++++++++ samples/pktgen/pktgen_sample01_simple.sh | 71 ++++++++++ samples/pktgen/pktgen_sample02_multiqueue.sh | 75 +++++++++++ .../pktgen/pktgen_sample03_burst_single_flow.sh | 82 ++++++++++++ 12 files changed, 678 insertions(+), 242 deletions(-) create mode 100644 samples/pktgen/README.rst create mode 100644 samples/pktgen/functions.sh create mode 100644 samples/pktgen/parameters.sh delete mode 100755 samples/pktgen/pktgen.conf-1-1 delete mode 100755 samples/pktgen/pktgen.conf-2-1 delete mode 100755 samples/pktgen/pktgen.conf-2-2 create mode 100755 samples/pktgen/pktgen_bench_xmit_mode_netif_receive.sh create mode 100755 samples/pktgen/pktgen_sample01_simple.sh create mode 100755 samples/pktgen/pktgen_sample02_multiqueue.sh create mode 100755 samples/pktgen/pktgen_sample03_burst_single_flow.sh