From: Thomas Monjalon <thomas@monjalon.net>
To: dev@dpdk.org
Subject: [dpdk-dev] [PATCH v2 2/2] devtools: allow misc options in null test
Date: Wed, 17 Jul 2019 17:52:02 +0200 [thread overview]
Message-ID: <20190717155202.1674-2-thomas@monjalon.net> (raw)
In-Reply-To: <20190717155202.1674-1-thomas@monjalon.net>
In order to ease basic testing with customized options,
EAL and testpmd options can be added as third and fourth arguments
of the "null PMD" script.
Also, the first argument becomes more flexible by accepting
the testpmd path as an alternative to the build directory.
Signed-off-by: Thomas Monjalon <thomas@monjalon.net>
---
devtools/test-null.sh | 11 +++++++----
1 file changed, 7 insertions(+), 4 deletions(-)
diff --git a/devtools/test-null.sh b/devtools/test-null.sh
index 6928a6c15..69eddc359 100755
--- a/devtools/test-null.sh
+++ b/devtools/test-null.sh
@@ -5,10 +5,13 @@
# Run a quick testpmd forwarding with null PMD without hugepage
-build=${1:-build}
+build=${1:-build} # first argument can be the build directory
+testpmd=$1 # or first argument can be the testpmd path
coremask=${2:-3} # default using cores 0 and 1
+eal_options=$3
+testpmd_options=$4
-testpmd=$build/app/dpdk-testpmd
+[ -f "$testpmd" ] || testpmd=$build/app/dpdk-testpmd
[ -f "$testpmd" ] || testpmd=$build/app/testpmd
if [ ! -f "$testpmd" ] ; then
echo 'ERROR: testpmd cannot be found' >&2
@@ -22,5 +25,5 @@ fi
(sleep 1 && echo stop) |
$testpmd -c $coremask --no-huge -m 150 \
- $libs --vdev net_null1 --vdev net_null2 -- \
- --no-mlockall --total-num-mbufs=2048 -ia
+ $libs --vdev net_null1 --vdev net_null2 $eal_options -- \
+ --no-mlockall --total-num-mbufs=2048 $testpmd_options -ia
--
2.21.0
next prev parent reply other threads:[~2019-07-17 15:53 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-07-17 11:20 [dpdk-dev] [PATCH] devtools: fix " Thomas Monjalon
2019-07-17 15:52 ` [dpdk-dev] [PATCH v2 1/2] devtools: restore " Thomas Monjalon
2019-07-17 15:52 ` Thomas Monjalon [this message]
2019-07-29 10:36 ` [dpdk-dev] [PATCH v2 2/2] devtools: allow misc options in " David Marchand
2019-07-29 12:19 ` Thomas Monjalon
2019-07-29 12:55 ` David Marchand
2019-07-29 10:35 ` [dpdk-dev] [PATCH v2 1/2] devtools: restore " David Marchand
2019-07-29 12:15 ` Thomas Monjalon
2019-07-29 12:53 ` David Marchand
2019-07-30 17:34 ` [dpdk-dev] [PATCH v3 " Thomas Monjalon
2019-07-30 17:34 ` [dpdk-dev] [PATCH v3 2/2] devtools: allow misc options in " Thomas Monjalon
2019-08-05 15:23 ` Thomas Monjalon
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20190717155202.1674-2-thomas@monjalon.net \
--to=thomas@monjalon.net \
--cc=dev@dpdk.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).