Commit Graph

921 Commits

Author SHA1 Message Date
Beilei Xing
18872f511c app/testpmd: add TCP flags in flow rules
This commit adds TCP flags support in flow API as
some drivers have SYN filter.

Signed-off-by: Beilei Xing <beilei.xing@intel.com>
Tested-by: Wei Zhao <wei.zhao1@intel.com>
Acked-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
2017-06-08 23:12:13 +02:00
Beilei Xing
0f01a7e383 app/testpmd: fix creating E-Tag and NVGRE flow rules
Application fails to create NVGRE and E-Tag flows with
current configuration, this commit fixes the issue by
adding flow items for E_TAG and NVGRE.

Fixes: e4840ef268 ("ethdev: fix incomplete items in flow API")
Cc: stable@dpdk.org

Signed-off-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
2017-06-08 23:10:20 +02:00
Ferruh Yigit
0eb8b19bc9 app/testpmd: remove duplicated license
Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com>
2017-06-04 13:18:06 +02:00
Michal Jastrzebski
08dd403dbd app/procinfo: fix xstats by ID on 32-bit
Coverity reported that an argument for sizeof was used improperly.
We should allocate memory for value size that pointer points to,
instead of pointer size itself.

Coverity issue: 144523, 144521
Fixes: 7ac16a3660 ("app/proc-info: support xstats by ID and by name")

Signed-off-by: Michal Jastrzebski <michalx.k.jastrzebski@intel.com>
Acked-by: Harry van Haaren <harry.van.haaren@intel.com>
2017-05-10 18:49:59 +02:00
Gaetan Rivet
b6b63dfd0f app/testpmd: print all or no events
Adds the "all" option to the print-event and mask-event parameters. This
option will enable or disable all event notifications from being
displayed.

Signed-off-by: Gaetan Rivet <gaetan.rivet@6wind.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
2017-05-10 18:44:55 +02:00
Shahaf Shuler
c9cafcc82d app/testpmd: fix mempool creation by socket id
The test assumes the socket ids are contiguous. This
is not necessarily the case on all servers and may cause
mempool creation to fail.

Fixing it by detecting the list of valid socket ids and
use it for the mempool creation.

Fixes: 7acf894d07 ("app/testpmd: detect numa socket count")
Cc: stable@dpdk.org

Signed-off-by: Shahaf Shuler <shahafs@mellanox.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
2017-05-10 18:39:50 +02:00
Gaetan Rivet
3af72783d1 app/testpmd: configure event display
Add two parameters to testpmd:

  --print-event <event name>
  --mask-event <event name>

To enable or disable to printing of events. This display is configured
on a per-event basis. By default, all except VF_MBOX are displayed.

Fixes: 76ad4a2d82 ("app/testpmd: add generic event handler")

Signed-off-by: Gaetan Rivet <gaetan.rivet@6wind.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
2017-05-06 10:39:31 +02:00
Yulong Pei
487f9a592a app/testpmd: fix NUMA structures initialization
Previous numa_support = 0 by default, it need to add --numa to testpmd
command line to enable numa, so port_numa and ring_numa were initialized
at function launch_args_parse(), now testpmd change numa_support = 1 as
default, so port_numa and ring_numa also need to initialize by default,
otherwise port->socket_id will be probed to wrong value.

Fixes: 999b2ee0fe ("app/testpmd: enable NUMA support by default")

Signed-off-by: Yulong Pei <yulong.pei@intel.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
2017-05-06 10:22:58 +02:00
Adrien Mazarguil
09a670e871 app/testpmd: fix MAC endian in flow command
MAC addresses are implicitly handled in network order since they are
actually byte strings, however this is not properly enforced with MAC masks
provided as prefix lengths, which end up inverted on little endian
systems.

Fixes: 6df81b325f ("app/testpmd: add items eth/vlan to flow command")
Cc: stable@dpdk.org

Signed-off-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
2017-05-06 10:16:10 +02:00
Adrien Mazarguil
138ae2481e app/testpmd: fix stack overwriting by flow command
The parameter type parser function stores a stack-local address in the
global parser context when parsing a "prefix" keyword.

This usually translates to "Bad arguments" errors even for correct flow
rules as stack gets overwritten by subsequent function calls.

Fixes: d3f61b7bad ("app/testpmd: add flow item spec prefix length")
Cc: stable@dpdk.org

Signed-off-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
2017-05-06 10:00:44 +02:00
Pablo de Lara
65eb1e544d app/testpmd: disable latency stats by default
Disable latency stats gathering by default,
so there is not performance degradation if user
is not interested in them.

Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
2017-05-06 10:00:41 +02:00
Pablo de Lara
30bcc68cc8 app/testpmd: fix build without bitrate lib
Fixes: e25e6c70fb ("app/testpmd: add --bitrate-stats option")

Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Acked-by: Remy Horton <remy.horton@intel.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
2017-05-06 10:00:38 +02:00
Bruce Richardson
0f5e6759fd app/testpmd: add switch fall-through comments
This fixes compiler warnings with GCC 7.

Fixes: 28d62131a1 ("app/testpmd: extend flow director input set commands")

Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
2017-05-05 18:36:55 +02:00
Thomas Monjalon
3dcfe0390c pci: remove eal prefix
The PCI code will move to the bus drivers directory.
Rename functions from rte_eal_pci_ to rte_pci_
to prepare the move of the driver out of EAL.

Signed-off-by: Thomas Monjalon <thomas@monjalon.net>
Acked-by: Stephen Hemminger <stephen@networkplumber.org>
2017-05-05 14:38:17 +02:00
Kuba Kozak
7ac16a3660 app/proc-info: support xstats by ID and by name
There are new arguments --xstats-ids and --xstats-name
in proc_info command line to retrieve statistics given by ids
and by name.
E.g. --xstats-ids="1,3,5,7,8"
E.g. --xstats-name rx_errors

Signed-off-by: Kuba Kozak <kubax.kozak@intel.com>
2017-05-01 23:48:39 +02:00
Kuba Kozak
0a5beecf46 ethdev: revert xstats by ID
Revert patches to provide clear view for
upcoming changes. Reverted patches are listed below:
commit ea85e7d711 ("ethdev: retrieve xstats by ID")
commit a954495245 ("ethdev: get xstats ID by name")
commit 1223608adb ("app/proc-info: support xstats by ID")
commit 25e38f09af ("net/e1000: support xstats by ID")
commit 923419333f ("net/ixgbe: support xstats by ID")

Signed-off-by: Kuba Kozak <kubax.kozak@intel.com>
2017-05-01 23:38:00 +02:00
Allain Legacy
a8c6a1ae12 app/testpmd: load commands from file at runtime
Adds support to testpmd to load a set of cmdline CLI commands at runtime.
This can be helpful when needing to cut-n-paste many commands where
cut-n-paste may not be practical.

   testpmd> load /home/ubuntu/somefile.txt

Signed-off-by: Allain Legacy <allain.legacy@windriver.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
2017-05-01 16:05:23 +02:00
Allain Legacy
81ef862b51 app/testpmd: load commands from file at startup
Adds support to testpmd to load a set of cmdline CLI commands at startup.
This can be helpful when needing to cut-n-paste many commands each time
testpmd is restarted.  This option will work in both interactive and
non-interactive modes.

   ./testpmd -n4 -c3 ... -- --cmdline-file=/home/ubuntu/somefile.txt

Signed-off-by: Allain Legacy <allain.legacy@windriver.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
2017-05-01 16:00:37 +02:00
Remy Horton
e25e6c70fb app/testpmd: add --bitrate-stats option
Bit-rate collation should only be done by one core. This patch adds
an option to select which core performs the bit-rate calculation,
which is also disabled by default.

Fixes: 7e4441c8ef ("app/testpmd: add bitrate statistics calculation")

Signed-off-by: Remy Horton <remy.horton@intel.com>
Acked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
2017-05-01 15:49:58 +02:00
Jiayu Hu
0de738cfc1 app/testpmd: fix exit without freeing resources
When testpmd exits, it frees the acquired resources (e.g. stop ports).
However, when we terminate it by Ctrl-d, testpmd exits directly without
releasing the resources. In this patch, we fix this exit issue.

Fixes: af75078fec ("first public release")
Cc: stable@dpdk.org

Signed-off-by: Jiayu Hu <jiayu.hu@intel.com>
Reviewed-by: Jianfeng Tan <jianfeng.tan@intel.com>
2017-05-01 15:40:08 +02:00
Olivier Matz
3ab64341da app/testpmd: fix number of mbufs in pool
The number of mbufs in pools is not consistent depending on the
options passed by the user and the number of ports, especially
in numa mode, when the number of mbuf is specified by the user.

When the user specifies the number of mbuf (per pool), it should
overrides the default value.

- before the patch

./build/app/testpmd -- -i
  <mbuf_pool_socket_0>: n=331456, size=2176, socket=0
  <mbuf_pool_socket_1>: n=331456, size=2176, socket=1

./build/app/testpmd -- --total-num-mbufs=8000 -i
  <mbuf_pool_socket_0>: n=256000, size=2176, socket=0
  <mbuf_pool_socket_1>: n=256000, size=2176, socket=1
  # BAD, should be n=8000 for each socket

./build/app/testpmd -- --no-numa -i
  <mbuf_pool_socket_0>: n=331456, size=2176, socket=0

./build/app/testpmd -- --no-numa --total-num-mbufs=8000 -i
  <mbuf_pool_socket_0>: n=8000, size=2176, socket=0

./build/app/testpmd --vdev=eth_null0 --vdev=eth_null1 -- -i
  <mbuf_pool_socket_0>: n=331456, size=2176, socket=0
  <mbuf_pool_socket_1>: n=331456, size=2176, socket=1

./build/app/testpmd --vdev=eth_null0 --vdev=eth_null1 -- \
     --total-num-mbufs=8000 -i
  <mbuf_pool_socket_0>: n=128000, size=2176, socket=0
  <mbuf_pool_socket_1>: n=128000, size=2176, socket=1
  # BAD, should be n=8000 for each socket

./build/app/testpmd --vdev=eth_null0 --vdev=eth_null1 -- --no-numa -i
  <mbuf_pool_socket_0>: n=331456, size=2176, socket=0

./build/app/testpmd --vdev=eth_null0 --vdev=eth_null1 -- --no-numa \
     --total-num-mbufs=8000 -i
  <mbuf_pool_socket_0>: n=8000, size=2176, socket=0

- after the patch

./build/app/testpmd -- -i
  <mbuf_pool_socket_0>: n=331456, size=2176, socket=0
  <mbuf_pool_socket_1>: n=331456, size=2176, socket=1

./build/app/testpmd -- --total-num-mbufs=8000 -i
  <mbuf_pool_socket_0>: n=8000, size=2176, socket=0
  <mbuf_pool_socket_1>: n=8000, size=2176, socket=1

./build/app/testpmd -- --no-numa -i
  <mbuf_pool_socket_0>: n=331456, size=2176, socket=0

./build/app/testpmd -- --no-numa --total-num-mbufs=8000 -i
  <mbuf_pool_socket_0>: n=8000, size=2176, socket=0

./build/app/testpmd --vdev=eth_null0 --vdev=eth_null1 -- -i
  <mbuf_pool_socket_0>: n=331456, size=2176, socket=0
  <mbuf_pool_socket_1>: n=331456, size=2176, socket=1

./build/app/testpmd --vdev=eth_null0 --vdev=eth_null1 -- \
     --total-num-mbufs=8000 -i
  <mbuf_pool_socket_0>: n=8000, size=2176, socket=0
  <mbuf_pool_socket_1>: n=8000, size=2176, socket=1

./build/app/testpmd --vdev=eth_null0 --vdev=eth_null1 -- --no-numa -i
  <mbuf_pool_socket_0>: n=331456, size=2176, socket=0

./build/app/testpmd --vdev=eth_null0 --vdev=eth_null1 -- --no-numa \
     --total-num-mbufs=8000 -i
  <mbuf_pool_socket_0>: n=8000, size=2176, socket=0

Fixes: b6ea6408fb ("ethdev: store numa_node per device")
Cc: stable@dpdk.org

Signed-off-by: Olivier Matz <olivier.matz@6wind.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
2017-05-01 15:14:42 +02:00
Olivier Matz
3c1a5444d4 app/testpmd: fix crash at mbuf pool creation
Since
commit 999b2ee0fe ("app/testpmd: enable NUMA support by default"),
testpmd is started with numa enabled by default. This highlights a
floating point exception when started with --total-num-mbufs without any
port (division by 0). This bug was already triggered before this commit
if the --no-numa option was given.

This commit adds a check of the nb_ports value before doing the
division. By looking at this code, it appears that the creation of the
mbuf pool is not consistent for the number of mbufs depending on the
configuration. This is fixed in the next commit.

Fixes: b6ea6408fb ("ethdev: store numa_node per device")
Cc: stable@dpdk.org

Signed-off-by: Olivier Matz <olivier.matz@6wind.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
2017-05-01 15:14:31 +02:00
Adrien Mazarguil
e4840ef268 ethdev: fix incomplete items in flow API
E-Tag and NVGRE pattern items have been added hastily without updating
documentation nor testpmd.

This commit also adds default masks for these items based on the ixgbe
implementation.

Fixes: 99e7003831 ("net/ixgbe: parse L2 tunnel filter")
Cc: stable@dpdk.org

Signed-off-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
Acked-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
2017-05-01 00:13:15 +02:00
Michal Jastrzebski
a11595045e app/procinfo: fix description of --xstats-name option
fix proc-info xstats-name description string

Fixes: 1223608adb ("app/proc-info: support xstats by ID")

Signed-off-by: Michal Jastrzebski <michalx.k.jastrzebski@intel.com>
Acked-by: Harry van Haaren <harry.van.haaren@intel.com>
2017-04-21 15:13:02 +02:00
Bruce Richardson
999b2ee0fe app/testpmd: enable NUMA support by default
There is little reason for NUMA support in testpmd to be off by default, so
enable it, and add in a new commandline parameter to disable it, if that is
wanted by users.

Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
2017-04-21 01:19:56 +02:00
Rami Rosen
0f58f01393 app/testpmd: consolidate duplicate ifdefs into one
Cnsolidate the duplicate #ifdef RTE_TEST_PMD_RECORD_CORE_CYCLES
into one #ifdef.

Signed-off-by: Rami Rosen <rami.rosen@intel.com>
2017-04-21 01:19:14 +02:00
Pascal Mazon
2eaef2b915 app/testpmd: fix duplicated metrics header include
Fixes: 62d3216d61 ("app/testpmd: add latency statistics calculation")

Signed-off-by: Pascal Mazon <pascal.mazon@6wind.com>
Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>
2017-04-21 01:11:21 +02:00
Gaetan Rivet
284c908cc5 app/testpmd: request device removal interrupt
Enable device removal event for PMD supporting it.
Add the --no-rmv-interrupt parameter to explicitly disable it.

Signed-off-by: Gaetan Rivet <gaetan.rivet@6wind.com>
Signed-off-by: Elad Persiko <eladpe@mellanox.com>
2017-04-21 01:02:16 +02:00
Gaetan Rivet
8ea656f8c3 app/testpmd: request link status interrupt
For drivers supporting the LSC event, enable it.
This allows to test LSC event support.

Add the --no-lsc-interrupt parameter to explicitly disable the link status
change interrupt.

Signed-off-by: Gaetan Rivet <gaetan.rivet@6wind.com>
2017-04-21 01:02:11 +02:00
Gaetan Rivet
76ad4a2d82 app/testpmd: add generic event handler
This is a rather simple handler that prints a message with the name of
the current event. It can be used to check PMD callback registration and
triggers.

Signed-off-by: Gaetan Rivet <gaetan.rivet@6wind.com>
2017-04-21 01:01:59 +02:00
Kuba Kozak
1223608adb app/proc-info: support xstats by ID
There is a new argument --xstats-ids and --xstats-name
in proc_info command line to retrieve statistics given by ids
and by name.
E.g. --xstats-ids="1,3,5,7,8"
E.g. --xstats-name rx_errors

ethdev: mark functions as deprecated

Functions rte_eth_xstats_get_all and rte_eth_xstats_get_names_all
are marked as deprecated

Signed-off-by: Kuba Kozak <kubax.kozak@intel.com>
Acked-by: Harry van Haaren <harry.van.haaren@intel.com>
2017-04-20 22:30:26 +02:00
Jacek Piasecki
ea85e7d711 ethdev: retrieve xstats by ID
Extended xstats API in ethdev library to allow grouping of stats
logically so they can be retrieved per logical grouping  managed
by the application.
Changed existing functions rte_eth_xstats_get_names and
rte_eth_xstats_get to use a new list of arguments: array of ids
and array of values. ABI versioning mechanism was used to
support backward compatibility.
Introduced two new functions rte_eth_xstats_get_all and
rte_eth_xstats_get_names_all which keeps functionality of the
previous ones (respectively rte_eth_xstats_get and
rte_eth_xstats_get_names) but use new API inside.

test-pmd: add support for new xstats API retrieving by id in
testpmd application: xstats_get() and
xstats_get_names() call with modified parameters.

doc: add description for modified xstats API
Documentation change for modified extended statistics API functions.
The old API only allows retrieval of *all* of the NIC statistics
at once. Given this requires a MMIO read PCI transaction per statistic
it is an inefficient way of retrieving just a few key statistics.
Often a monitoring agent only has an interest in a few key statistics,
and the old API forces wasting CPU time and PCIe bandwidth in retrieving
*all* statistics; even those that the application didn't explicitly
show an interest in.
The new, more flexible API allow retrieval of statistics per ID.
If a PMD wishes, it can be implemented to read just the required
NIC registers. As a result, the monitoring application no longer wastes
PCIe bandwidth and CPU time.

Signed-off-by: Jacek Piasecki <jacekx.piasecki@intel.com>
Signed-off-by: Kuba Kozak <kubax.kozak@intel.com>
Signed-off-by: Tomasz Kulasek <tomaszx.kulasek@intel.com>
Acked-by: Harry van Haaren <harry.van.haaren@intel.com>
2017-04-20 22:29:22 +02:00
Pablo de Lara
ad674b4d4a app/crypto-perf: fix AEAD tests when AAD is zero
For AEAD algorithms, additional authenticated data (AAD)
can be passed, but it is optional, so its size can be zero.
Therefore, test can be run if no memory is allocated.

Fixes: f8be1786b1 ("app/crypto-perf: introduce performance test application")
Cc: stable@dpdk.org

Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
2017-04-20 11:32:45 +02:00
Pablo de Lara
0091576132 app/crypto-perf: fix length for wireless algos
When SNOW3G/KASUMI/ZUC algorithms are used, ciphering
and authentication lengths have to be passed as bits
and not as bytes.

Fixes: f8be1786b1 ("app/crypto-perf: introduce performance test application")
Cc: stable@dpdk.org

Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
2017-04-20 11:32:45 +02:00
Fan Zhang
44e2980b70 app/crypto-perf: fix crypto operation resubmission
This patch fixes the crypto operation resubmission problem in crypto
perferformance test. Originally, when needed crypto ops amount is
smaller than the enqueued crypto ops in the last round, one or more
processed crypto operations will be re-enqueued.

Fixes: f8be1786b1 ("app/crypto-perf: introduce performance test application")
Cc: stable@dpdk.org

Signed-off-by: Fan Zhang <roy.fan.zhang@intel.com>
Acked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
2017-04-20 11:32:45 +02:00
Pablo de Lara
1e1d4fb791 app/crypto-perf: fix possible overflow
In the latency test, when number of enqueued operations
is less than the burst size, the timestamp value of the
non-enqueued operations was being stored, even though
those operations were being freed.

This could cause an array overflow, since it could store
more values than the total number of operations.

Fixes: 5d75fb09d3 ("app/crypto-perf: fix invalid latency for QAT")
Cc: stable@dpdk.org

Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
2017-04-20 11:32:45 +02:00
Qi Zhang
156a31b5ee app/testpmd: add commands for packet type mapping
Add below command line to configure ptype mapping.
ptype mapping get <port_id> <valid_only>.
ptype mapping replace <port_id> <target> <mask> <pkt_type>.
ptype mapping reset <port_id>.
ptype mapping update <port_id> <hw_ptype> <sw_ptype>.

Signed-off-by: Qi Zhang <qi.z.zhang@intel.com>
Acked-by: Jianbo Liu <jianbo.liu@linaro.org>
Acked-by: Chao Zhu <chaozhu@linux.vnet.ibm.com>
2017-04-19 15:37:37 +02:00
Jeff Guo
3c32113a1a app/testpmd: fix IPv6 tunnel checksum
When ipv6 packet is tunnel packet, "PKT_TX_OUTER_IPV6" flag must
be set, to let prepare the correct mbuf meta data for tx forward.

Fixes: 2b76648872 ("net/e1000: add Tx preparation")
Cc: stable@dpdk.org

Signed-off-by: Jeff Guo <jia.guo@intel.com>
2017-04-10 22:50:01 +02:00
Jeff Guo
79dd163fca app: enable HW CRC strip by default
Since VF can not disable/enable HW CRC strip for non-DPDK PF drivers,
and kernel driver almost default enable that feature, if disable it in
app's rxmode, VF driver will report the VF launch failure. So this
patch default to enable HW CRC strip to let VF launch successful.

Cc: stable@dpdk.org

Signed-off-by: Jeff Guo <jia.guo@intel.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
2017-04-10 22:35:48 +02:00
Ilya Maximets
5ae1274fb0 app: do not build test-crypto-perf if cryptodev disabled
This fixes build in following configuration:

	CONFIG_RTE_LIBRTE_CRYPTODEV=n
	CONFIG_RTE_APP_CRYPTO_PERF=y

Fixes: f8be1786b1 ("app/crypto-perf: introduce performance test application")
Cc: stable@dpdk.org

Signed-off-by: Ilya Maximets <i.maximets@samsung.com>
Acked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
2017-04-10 12:00:06 +02:00
Pablo de Lara
a8eb964020 app/crypto-perf: reorg options structure
Reorganize options structure, to have all the parameters
used in a single run in the first bytes of the structure,
so all fit in a single cache line.

Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Acked-by: Sergio Gonzalez Monroy <sergio.gonzalez.monroy@intel.com>
2017-04-06 00:17:44 +02:00
Pablo de Lara
fc4600fb25 app/crypto-perf: add extra option checks
When using the verify test, test name is necessary
to be passed when digest is needed.

Also, when using an block cipher algorithm (CBC, ECB),
the buffer size has to be aligned to the block size.

Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Acked-by: Sergio Gonzalez Monroy <sergio.gonzalez.monroy@intel.com>
2017-04-06 00:17:44 +02:00
Pablo de Lara
f6cefe253c app/crypto-perf: add range/list of sizes
So far, the crypto performance application was only able to
test one buffer size and one burst size.

With this commit, multiple sizes can be passed, either as a range
of values or as a list of values.

Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Acked-by: Sergio Gonzalez Monroy <sergio.gonzalez.monroy@intel.com>
2017-04-06 00:17:44 +02:00
Pablo de Lara
da40ebd6d3 app/crypto-perf: display results in test runner
Instead of printing the test results in the destructor
function, print them just after each run.
This will be useful for after the commit that allows
a range of buffer and burst sizes.

Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Acked-by: Sergio Gonzalez Monroy <sergio.gonzalez.monroy@intel.com>
2017-04-06 00:17:44 +02:00
Pablo de Lara
b2085cce60 app/crypto-perf: do not append digest if not used
When testing cipher only operations, there is no need to append digest
at the end of the buffer.

Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Acked-by: Sergio Gonzalez Monroy <sergio.gonzalez.monroy@intel.com>
2017-04-06 00:17:44 +02:00
Sergio Gonzalez Monroy
df52cb3b6e app/crypto-perf: move verify as single test type
In order to simplify throughput and latency tests,
verify option has been removed from these and moved
as a separate test.

Signed-off-by: Sergio Gonzalez Monroy <sergio.gonzalez.monroy@intel.com>
Acked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
2017-04-06 00:17:44 +02:00
Pablo de Lara
8612836d6f app/crypto-perf: fix AES CBC 128 test vectors
Ciphertext and digests for different buffer sizes
were incorrect.

Fixes: 5f1d85c5a8 ("app/crypto-perf: add test vectors files")
Cc: stable@dpdk.org

Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Acked-by: Sergio Gonzalez Monroy <sergio.gonzalez.monroy@intel.com>
2017-04-06 00:17:44 +02:00
Pablo de Lara
e40de34d6f app/crypto-perf: remove unused file
Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Acked-by: Sergio Gonzalez Monroy <sergio.gonzalez.monroy@intel.com>
2017-04-06 00:17:44 +02:00
Pablo de Lara
9f3ea3e4b9 app/crypto-perf: remove cyclecount test type
Cyclecount test was not implemented, so it is removed.

Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Acked-by: Sergio Gonzalez Monroy <sergio.gonzalez.monroy@intel.com>
2017-04-06 00:17:44 +02:00
Tomasz Kulasek
884ed3ff8e app/crypto-perf: fix uninitialized values for null ops
Some values are uninitialized for "cipher null" and "auth null"
operations. It may cause unpredictable results for some crypto pmd
drivers, or even segmentation fault.

This patch sets values for null operations to zero.

Fixes: f8be1786b1 ("app/crypto-perf: introduce performance test application")

Signed-off-by: Tomasz Kulasek <tomaszx.kulasek@intel.com>
Acked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
2017-04-06 00:17:44 +02:00