The different fdir mode needs different parameters, so, the parameter *mode*
is introduced to the CLI flow_director_filter and flow_director_mask. This
parameter can pormpt the user to input the appropriate parameters for different
mode.
Please be aware, as we should set the fdir mode, the value of the parameter
pkt-filter-mode, when we start testpmd. We cannot set a different mode for
mask or filter.
The new CLIs are added for the mac vlan and tunnel modes, like this,
flow_director_mask X mode MAC-VLAN vlan XXXX mac XX,
flow_director_mask X mode Tunnel vlan XXXX mac XX tunnel-type X tunnel-id XXXX,
flow_director_filter X mode MAC-VLAN add/del/update mac XX:XX:XX:XX:XX:XX
vlan XXXX flexbytes (X,X) fwd/drop queue X fd_id X,
flow_director_filter X mode Tunnel add/del/update mac XX:XX:XX:XX:XX:XX
vlan XXXX tunnel NVGRE/VxLAN tunnel-id XXXX flexbytes (X,X) fwd/drop queue X
fd_id X.
Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Acked-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
There're fdir mask and supported flow type in the output of the CLI,
show port fdir. But not every parameter has meaning for all the fdir
modes, and the supported flow type is meaningless for mac vlan and
tunnel modes. So, we output different thing for different mode.
Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Acked-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
For testpmd CLI's parameter pkt-filter-mode, there're new values supported for
fdir new modes, perfect-mac-vlan, perfect-tunnel.
Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Acked-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
When a port is enabled, there're default values for the parameters of
fdir mask. For the new parameters, the default values also need to be
set.
Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Acked-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
This is a useful default for simple applications where the assignment
of lcores to CPUs doesn't matter. It's also useful for more complex
applications that automatically assign tasks to cores based on the
NUMA topology.
Signed-off-by: Rich Lane <rich.lane@bigswitch.com>
Currently, there is a MAX_SOCKET macro which artificially limits the
number of NUMA sockets testpmd can use. Anything on a higher socket
ends up using socket zero. This patch replaces this with a variable
set during set_default_fwd_lcores_config() and uses RTE_MAX_NUMA_NODES
where a hard-coded max number of sockets is required.
Signed-off-by: Stephen Hurd <shurd@broadcom.com>
Acked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
'virtual' is a keyword and can't be used if the code is to compile with
C++ compilers.
If rte_devargs.h was included in C++ code, compilation with clang++
failed with an error. g++ did not fail, but only because of a bug
that treats it as an anonymous struct with a decl-specifier which it
ignores.
This simply renames the member to 'virt'.
Reported-by: Ming Zhao <mzhao@luminatewireless.com>
Signed-off-by: Christoph Gysin <christoph.gysin@gmail.com>
Acked-by: Cristian Dumitrescu <cristian.dumitrescu@intel.com>
Acked-by: David Marchand <david.marchand@6wind.com>
This patch relates to ABI change proposed for librte_port. Macros to
access the packet meta-data stored within the packet buffer has been
adjusted to cover the packet mbuf structure.
The LIBABIVER number is incremented.
Signed-off-by: Fan Zhang <roy.fan.zhang@intel.com>
Acked-by: Cristian Dumitrescu <cristian.dumitrescu@intel.com>
LPM table and pipeline apps have been modified to
include name parameter of the lpm table.
Signed-off-by: Jasvinder Singh <jasvinder.singh@intel.com>
Acked-by: Cristian Dumitrescu <cristian.dumitrescu@intel.com>
The function rte_jhash2() was renamed rte_jhash_32b and
macros RTE_HASH_KEY_LENGTH_MAX and RTE_HASH_BUCKET_ENTRIES_MAX
were tagged as deprecated, so they can be removed in 2.2.
RTE_HASH_KEY_LENGTH is replaced in unit tests by an internal macro
for the memory allocation of all keys used.
The library version number is incremented.
Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Signed-off-by: Thomas Monjalon <thomas.monjalon@6wind.com>
These functions were tagged as deprecated in 2.0 so they can be
removed in 2.2.
The library version is incremented.
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Helin Zhang <helin.zhang@intel.com>
[Thomas: update doc and version]
Signed-off-by: Thomas Monjalon <thomas.monjalon@6wind.com>
Acked-by: Neil Horman <nhorman@tuxdriver.com>
The functions and structures are moved to app/test in order to keep
existing unit tests. Some minor changes were done in these functions
because of library scope restrictions.
An enum is also copied in two other applications to keep existing code.
The library version is incremented.
Signed-off-by: Thomas Monjalon <thomas.monjalon@6wind.com>
Acked-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Neil Horman <nhorman@tuxdriver.com>
Acked-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
The library version is incremented.
Signed-off-by: Thomas Monjalon <thomas.monjalon@6wind.com>
Acked-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Neil Horman <nhorman@tuxdriver.com>
The extended SCTP flow entries are now part of the standard API.
Signed-off-by: Thomas Monjalon <thomas.monjalon@6wind.com>
Acked-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Neil Horman <nhorman@tuxdriver.com>
The extended unified packet type is now part of the standard ABI.
As mbuf struct is changed, the mbuf library version is incremented.
Signed-off-by: Thomas Monjalon <thomas.monjalon@6wind.com>
Acked-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Neil Horman <nhorman@tuxdriver.com>
In table_autotest, the structures containing the parameters
to create the tables were not initialized, and therefore,
some checks could fail and so the unit test.
Also, due to this initialization, one of the tests that was
checking if the table was improperly initialized has been
removed, as it is not needed anymore (duplicated)
Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
In commit: 1129992baa checking for offset alignment was removed.
Unit tests wasn't updated to reflect that change. This patch changes
checks with unaligned offsets to make tests pass.
Fixes: 1129992baa ("port: fix unaligned access to metadata")
Signed-off-by: Maciej Gajdzica <maciejx.t.gajdzica@intel.com>
Acked-by: Daniel Mrzyglod <danielx.t.mrzyglod@intel.com>
Test failed on verification if number of bytes
transmitted on each slave is not less than 90%
and greater than 110% of mean value of bytes transmitted
thru one slave. This was verified on a real system
but is difficult to achieve using virtualpmd.
That's why for unit tests only, it is sufficient to verify that with
high load (2 seconds transmission) all slaves are transmitting
so the traffic is balanced.
Fixes: 0c8396e6d7 ("bond: unit tests for mode 5")
Signed-off-by: Michal Jastrzebski <michalx.k.jastrzebski@intel.com>
'--no-huge' option now can workable with -m option.
Unit test for eal flag should change pass criterion.
Fixes: a7de7e6beb ("eal: allow combining -m and --no-huge")
Signed-off-by: Marvin Liu <yong.liu@intel.com>
In previous setting, mempool size and cache_size were both 32.
It does not satisfy with cache_size checking rule by now.
Cache size should be less than CONFIG_RTE_MEMPOOL_CACHE_MAX_SIZE and
mempool size / 1.5.
Fixes: 462321b44a ("mempool: limit cache size")
Signed-off-by: Marvin Liu <yong.liu@intel.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
[Thomas: remove unused PKT_BURST_SZ]
Add new timer-manage race-condition test: We wrote a test to confirm
our suspicion that we could crash rte_timer_manage() under the right
circumstances. We repeatedly set several timers to expire at roughly
the same time on the master core. The master lcore just delays and runs
rte_timer_manage() about ten times per second. The slave lcores all
watch the first timer (timer-0) to see when rte_timer_manage() is
running on the master, i.e., timer-0's state is not PENDING.
At this point, each slave attempts to reset a subset of the timers to
a later expiration time. The goal here is to have the slaves moving
most of the timers to a different place in the master's pending-list,
while the master is traversing the same next-pointers (the slaves'
sl_next[0] pointers) and running callback functions. This eventually
results in the master traversing a corrupted linked-list.
In our observations, it results in an infinite loop.
Signed-off-by: Robert Sanford <rsanford@akamai.com>
Fix app/test timer stress test 2: Sometimes this test fails and
seg-faults because the slave lcores get out of phase with the master.
The master uses a single int, 'ready', to synchronize multiple slave
lcores through multiple phases of the test.
To resolve, we construct simple synchronization primitives that use one
atomic-int state variable per slave. The master tells the slaves when to
start, and then waits for all of them to finish. Each slave waits for
the master to tell it to start, and then tells the master when it has
finished.
Signed-off-by: Robert Sanford <rsanford@akamai.com>
When close one port twice, testpmd will give out wrong messagse.
testpmd> port stop 0
Stopping ports...
Checking link statuses...
Port 0 Link Up - speed 0 Mbps - full-duplex
Port 1 Link Up - speed 0 Mbps - full-duplex
Done
testpmd> port close 0
Closing ports...
Done
testpmd> port close 0
Closing ports...
Port 0 is now not stopped
Done
testpmd>
Signed-off-by: Michael Qiu <michael.qiu@intel.com>
In testpmd, when using "rx_vlan add 1 77", it will be a segment fault
Because the port ID should be less than 32.
Fixes: edab33b1c0 ("app/testpmd: support port hotplug")
Signed-off-by: Michael Qiu <michael.qiu@intel.com>
When the bonded port is started it also starts the slave port,
but the slave port status is not set. A slave_flag has been
added to struct rte_port to resolve this issue.
Signed-off-by: Bernard Iremonger <bernard.iremonger@intel.com>
Acked-by: Declan Doherty <declan.doherty@intel.com>
Signed-off-by: David Marchand <david.marchand@6wind.com>
[Thomas: move inclusion used by ixgbe bypass]
Acked-by: Thomas Monjalon <thomas.monjalon@6wind.com>
A packet is tunnelled if the tunnel type is identified or if it has
an inner part.
Fix also some typos in RTE_PTYPE_INNER_L3_MASK and IP comments.
Fixes: f295a00a2b ("mbuf: add definitions of unified packet types")
Signed-off-by: Thomas Monjalon <thomas.monjalon@6wind.com>
Acked-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
In ieee1588fwd.c, timestamp.tv_sec is a time_t variable,
which is a long int, but it was being printed with PRIu64,
causing an issue on 32 bits.
Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Acked-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
At this point the stop() and close() functions have already been called.
The rte_eth_promiscuous_disable() function does not return on the VM.
Signed-off-by: Bernard Iremonger <bernard.iremonger@intel.com>
Acked-by: Stephen Hemminger <stephen@networkplumber.org>
proc_info displays statistics information including extended stats for
given DPDK ports and dumps the memory information for DPDK.
Signed-off-by: Maryam Tahhan <maryam.tahhan@intel.com>
Acked-by: Olivier Matz <olivier.matz@6wind.com>
Implement rte_memzone_free which, as its name implies, would free a
memzone.
Currently memzone are tracked in an array and cannot be free.
To be able to reuse the same array to track memzones, we have to
change how we keep track of reserved memzones.
With this patch, any memzone with addr NULL is not used, so we also need
to change how we look for the next memzone entry free.
Add new unit test for rte_memzone_free API.
Signed-off-by: Sergio Gonzalez Monroy <sergio.gonzalez.monroy@intel.com>
Some unit test are not relevant anymore. It is the case of those malloc
UTs that checked corner cases when allocating MALLOC_MEMZONE_SIZE
chunks, and the case of those memzone UTs relaying of specific free
memsegs of rhte reserved memzone.
Other UTs just need to be update, for example, to calculate maximum free
block size available.
Signed-off-by: Sergio Gonzalez Monroy <sergio.gonzalez.monroy@intel.com>
To unify packet types among all PMDs, bit masks of packet type for
'ol_flags' are replaced by unified packet type.
To avoid breaking ABI compatibility, all the changes would be
enabled by RTE_NEXT_ABI.
Signed-off-by: Helin Zhang <helin.zhang@intel.com>
Acked-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
The cuckoo hash has a fixed number of entries per bucket, so the
configuration parameter for this is unused. We change this field in the
parameters struct to "reserved" to indicate that there is now no such
parameter value, while at the same time keeping ABI consistency.
Fixes: 48a3991196 ("hash: replace with cuckoo hash implementation")
Suggested-by: Thomas Monjalon <thomas.monjalon@6wind.com>
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
The original code mistakenly defaulted to X86 when RTE_ARCH_PPC_64 was
left undefined. This did not accommodate other non-PPC/non-X86
architectures. This patch fixes this issue.
Signed-off-by: Cyril Chemparathy <cchemparathy@ezchip.com>
Signed-off-by: Zhigang Lu <zlu@ezchip.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Since now rte_hash structure is private, a new function
has been added to let the user iterate through the hash table,
returning next key and data associated on each iteration,
plus the position where they were stored.
Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Usually hash tables not only store keys, but also data associated
to them. In order to maintain the existing API, the old functions
will still return the index where the key was stored.
The new functions will return the data associated to that key.
In the case of the lookup_bulk function, it will return also
the number of entries found and a bitmask of which entries
were found.
Unit tests have been updated to use these new functions.
As a final point, a flag has been added in rte_hash_parameters
to indicate if there are new parameters for future versions,
so there is no need to maintain multiple versions
of the existing functions in the future.
Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
[Thomas: fix || operator in a precondition check]
Added reset function to be able to empty the table,
without having to destroy and create it again.
Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
This patch replaces the existing hash library with another approach,
using the Cuckoo Hash method to resolve collisions (open addressing),
which pushes items from a full bucket when a new entry tries
to be added in it, storing the evicted entry in an alternative location,
using a secondary hash function.
This gives the user the ability to store more entries when a bucket
is full, in comparison with the previous implementation.
Therefore, the unit test has been updated, as some scenarios have changed
(such as the previous removed restriction).
Also note that the API has not been changed, although new fields
have been added in the rte_hash structure (structure is internal now).
The main change when creating a new table is that the number of entries
per bucket is fixed now, so its parameter is ignored now
(still there to maintain the same parameters structure).
The hash unit test has been updated to reflect these changes.
As a last note, the maximum burst size in lookup_burst function
hash been increased to 64, to improve performance.
Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Add new unit test for calculating the average table utilization,
using random keys, based on number of entries that can be added
until we encounter one that cannot be added (bucket if full).
Also, replace current hash_perf unit test to see performance more clearly.
The current hash_perf unit test takes too long and add keys that
may or may not fit in the table and look up/delete that may not be
in the table. This new unit test gets a set of keys that we know
that fits in the table, and then measure the time to add/look up/delete
them.
Note that performance numbers include time to take a random key
from a pre-made array of keys, plus a quick check of return value.
Also, as stated above, expect higher numbers, as all operations
in the new unit tests will be successful, which means that
it will take more time, than mixing both successful and unsuccesful
operations.
Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
rte_hash structure should not be a public structure,
and therefore it should be moved to the C file and be declared
as internal. rte_hash_hash implementation is also moved
to the C file, as it uses the structure.
This patch also removes part of a unit test that was checking
a field of the structure.
Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Refactor the ieee1588_fwd mode in testpmd to use the new ethdev
APIs to enable and read IEEE1588 PTP timestamps.
Signed-off-by: John McNamara <john.mcnamara@intel.com>
Acked-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
In test application, the default size of allocated mempool is calculated
as following:
(RTE_MAX_LCORE * (RTE_MEMPOOL_CACHE_MAX_SIZE + max_kept_objects)) - 1
The objective is to ensure that all cores can fill their cache and keep
'max_kept_objects' at the same time. As RTE_MAX_LCORE is 128 and
RTE_MEMPOOL_CACHE_MAX_SIZE is 512 in the default configuration, it can
produce very large mempools (170 MB).
We can replace the number of core by a dynamic value, which drastically
reduces the amount of memory needed for this test (5 MB with 4 cores).
Signed-off-by: Olivier Matz <olivier.matz@6wind.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
As querying hash key size in byte was supported, it can be shown
in testpmd after getting the device information if not zero.
Signed-off-by: Helin Zhang <helin.zhang@intel.com>
Acked-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
This patch extends flow director commands to support l2_payload flow type.
Test report: http://dpdk.org/ml/archives/dev/2015-June/020238.html
Signed-off-by: Jingjing Wu <jingjing.wu@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
This path renames the mirror type in rte_eth_mirror_conf and macros,
and rework the mirror set in ixgbe drivers by using new definition.
It also fixes some coding style.
Test report: http://dpdk.org/ml/archives/dev/2015-June/019118.html
Signed-off-by: Jingjing Wu <jingjing.wu@intel.com>
Acked-by: Jijiang Liu <jijiang.liu@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
Rename rte_eth_vmdq_mirror_conf to rte_eth_mirror_conf and move
the maximum rule id check from ethdev level to driver.
Signed-off-by: Jingjing Wu <jingjing.wu@intel.com>
Acked-by: Jijiang Liu <jijiang.liu@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
If double vlan is detected, its stripped flag and vlan tags can be
printed on rxonly mode. Test command of 'tx_vlan set' is expanded
to set both single and double vlan tags on TX side for each packets
to be sent out.
Signed-off-by: Helin Zhang <helin.zhang@intel.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
This patch simply applies the transform previously committed in
scripts/cocci/mtod-offset.cocci. No other modifications have been
made here.
Signed-off-by: Cyril Chemparathy <cchemparathy@ezchip.com>
Acked-by: Olivier Matz <olivier.matz@6wind.com>
Not packing this causes -Wcast-align breakage on machines that are
strict on alignment. This patch fixes this bug.
Signed-off-by: Cyril Chemparathy <cchemparathy@ezchip.com>
Acked-by: Olivier Matz <olivier.matz@6wind.com>
On machines that are strict on pointer alignment, current code breaks
on GCC's -Wcast-align checks on casts from narrower to wider types.
This patch introduces new unaligned_uint(16|32|64)_t types, which
correctly retain alignment in such cases. Strict alignment
architectures will need to define CONFIG_RTE_ARCH_STRICT_ALIGN in
order to effect these new types.
Signed-off-by: Cyril Chemparathy <cchemparathy@ezchip.com>
Acked-by: Olivier Matz <olivier.matz@6wind.com>
This patch adds a new auto-test for testing the scaling
of concurrent inserts into rte_hash when protected by
the normal spinlock vs. the spinlock with HTM lock
elision. The test also benchmarks single-threaded
access without any locks.
Signed-off-by: Roman Dementiev <roman.dementiev@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Some test rules had equal priority for the same category.
That can cause an ambiguity in build trie and test results.
Specify different priority value for each rule from the same category.
Signed-off-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
Added new test that verifies that rte_jhash_1words,
rte_jhash_2words and rte_jhash_3words return the same
values as rte_jhash.
Note that this patch has been added after the update
of the jhash function because these 3 functions did not
return the same values as rte_jhash before
Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Changed name to something more meaningful,
and mark rte_jhash2 as deprecated.
Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Jenkins hash function was developed originally in 1996,
and was integrated in first versions of DPDK.
The function has been improved in 2006,
achieving up to 35% better performance, compared to the original one.
This patch integrates that code into the rte_jhash library.
It also updates the precalculated hash values in the unit test,
as the code now returns different values (expected).
A final note has been added in release notes for stating
the changes made.
Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
In order to make sure that the hash functions are returning
the correct values, new tests have been added:
- First test compares precalculated hash values with values calculated
from the existing hash functions.
- Second test compares values returned from rte_jhash2 and rte_jhash,
expecting same return (only for multiple of 4 bytes keys)
Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
In order to see more clearly the performance difference
between different hash functions, order of the loops
have been changed, so it iterates first through initial values,
then key sizes and then the hash functions.
Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Previous key sizes used for testing did not have much purpose.
This patch substitutes them with some more meaninful
(standard multiple of 2 key sizes, plus IPv4/v6 tuple and others)
Also an arbitrary initial value has been added to increase
the test coverage, and RTE_DIM macro is used to iterate the loops.
Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Cycles per hash calculation were measured per single operation.
It is much more accurate to run several iterations between measurements
and divide by number of iterations.
Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
This patch moves hash function performance tests to a separate file,
so user can check performance of the existing hash functions quicker,
without having to run all the other hash operation performance tests,
which takes some time.
Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
This change returns a system error code if tests fail when
running any of the "make test" targets.
This allows the tests to report failures while running in
continuous integration environments.
Previously "make test" returned $? == 0 for all combinations
of success, failure and exception conditions.
Signed-off-by: John McNamara <john.mcnamara@intel.com>
Each test requires a certain minimal amount of memory.
Spreading memory on all sockets means that the test will get less memory than
what it wanted on multi sockets system.
So replace all_sockets() with per_sockets().
Also doubled memory on group_5 as current requirement is not enough.
Signed-off-by: Gaetan Rivet <gaetan.rivet@6wind.com>
Signed-off-by: David Marchand <david.marchand@6wind.com>
This variable has undefined values in some cases.
Fixes: 422a20a4e6 ("app/testpmd: fix uninitialized flow control variables")
Signed-off-by: Ding Zhi <zhi.ding@6wind.com>
Signed-off-by: David Marchand <david.marchand@6wind.com>
[Thomas: split lines to conform with guidelines]
Acked-by: Thomas Monjalon <thomas.monjalon@6wind.com>
Set the IP source and destination addresses in the IP header of the
ICMP reply as follows:
- Use the request IP source address as the reply IP destination address
- If the request IP destination address is a multicast IP address
- choose a reply IP source address different from the request IP
source address,
- re-compute the IP header checksum.
Otherwise
- switch the request IP source and destination addresses in the
reply,
- keep the IP header checksum unchanged.
Signed-off-by: Ivan Boule <ivan.boule@6wind.com>
Add the new interactive command:
mcast_addr add|remove X <mcast_addr>
to add/remove the multicast MAC address <mcast_addr> to/from the set of
multicast addresses filtered by port <X>.
Command used to test the function "rte_eth_dev_set_mc_addr_list"
that has been added to the API of PMDs.
Signed-off-by: Ivan Boule <ivan.boule@6wind.com>
Fix trailing whitespace, space before tab and empty lines at end of file.
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
[Thomas: fix indent and alignment in test_acl.h and test_sched.c]
ICMP echo replies with invalid checksums may be dropped by network nodes or
ignored by the ping utility.
Signed-off-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
Acked-by: Ivan Boule <ivan.boule@6wind.com>
In the icmpecho forwarding mode, ARP replies from testpmd contain
invalid zero-filled MAC addresses. This is broken since the commit below.
Fixes: 31db4d38de ("net: change arp header struct declaration")
Signed-off-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
Acked-by: Ivan Boule <ivan.boule@6wind.com>
Add a new top-level "drivers" directory to which all PMDs will be moved
for easier maintenance of both lib folder and drivers themselves. This
new directory is a dependency of all the apps in the app folder, so
the makefiles for each app are updated.
To the new top-level directory add a "net" subdirectory to classify
more specifically our existing PMDs as ethernet drivers
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: John McNamara <john.mcnamara@intel.com>
[Thomas: fix dependencies and merge several patches]
Acked-by: Thomas Monjalon <thomas.monjalon@6wind.com>
Latest mbuf changes (priv_size addition and related fixes)
exposed small problem with testpmd and few other sample apps:
when mbuf size is exaclty 2KB or less, that causes
ixgbe PMD to select scattered RX even for configs with 'normal'
max packet length (max_rx_pkt_len == ETHER_MAX_LEN).
To overcome that problem and unify the code, new macro was created
to represent recommended minimal buffer length for mbuf.
When appropriate, samples are updated to use that macro.
Fixes: dfb03bbe2b ("app/testpmd: use standard functions to initialize
mbufs and mbuf pool")
Signed-off-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
Acked-by: Olivier Matz <olivier.matz@6wind.com>
The distributor header file includes the mbuf header file, but it does not
need to do so as it only uses pointers to the struct rte_mbuf type, and
does not use any of the mbuf internals, nor any of the mbuf functions or
macros. Therefore the inclusion is unnecessary, and can be replaced by a
forward declaration of the mbuf type.
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Olivier Matz <olivier.matz@6wind.com>
Verify that we can attach a mbuf to another one that does not have
the same data room size and priv_size.
Signed-off-by: Olivier Matz <olivier.matz@6wind.com>
Acked-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
Check that the data in the cloned mbuf is the same than in the
reference mbuf.
Check that the reference counter is incremented for each segment.
Signed-off-by: Olivier Matz <olivier.matz@6wind.com>
Acked-by: Neil Horman <nhorman@tuxdriver.com>
Acked-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
It's better to name the mbuf 'm' instead of 'mc' as it's not a clone.
Signed-off-by: Olivier Matz <olivier.matz@6wind.com>
Acked-by: Neil Horman <nhorman@tuxdriver.com>
Acked-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
When it's possible, use the new helper to create the mbuf pools.
Most of the patch is trivial, except for the following files that
have some specifics (indirect mbufs):
- ip_fragmentation
- ip_pipeline
- ipv4_multicast
- vhost
Signed-off-by: Olivier Matz <olivier.matz@6wind.com>
Acked-by: Neil Horman <nhorman@tuxdriver.com>
Acked-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
The rte_pktmbuf_pool_init() and rte_pktmbuf_init() functions now
support to have a non-hardcoded buffer length. We can remove the
specific functions used in testpmd and replace them by the standard
ones.
Signed-off-by: Olivier Matz <olivier.matz@6wind.com>
Acked-by: Neil Horman <nhorman@tuxdriver.com>
Acked-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
Deduct the mbuf data room size from mempool->elt_size and priv_size,
instead of using an hardcoded value that is not related to the real
buffer size.
To use rte_pktmbuf_pool_init(), the user can either:
- give a NULL parameter to rte_pktmbuf_pool_init(): in this case, the
private size is assumed to be 0, and the room size is
mp->elt_size - sizeof(struct rte_mbuf).
- give the rte_pktmbuf_pool_private filled with appropriate
data_room_size and priv_size values.
Signed-off-by: Olivier Matz <olivier.matz@6wind.com>
Acked-by: Neil Horman <nhorman@tuxdriver.com>
Acked-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
The PCI device id table is immutable and should be made const
in all drivers. The pseudo drivers can initialize their local
copy as necessary.
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Neil Horman <nhorman@tuxdriver.com>
To initialize a structure with zeros, one field was explicitly set
to avoid "missing initializer" bug with old GCC (e.g. 4.4).
This warning is now disabled (commit <insertlater>) for old versions of GCC,
so the workarounds may be removed.
These initializers should not be needed for static variables but they
are still used to workaround an ICC bug (see commit b2595c4aa9).
There is one remaining exception where {0} initializer doesn't work cleanly,
even with recent GCC:
lib/librte_pmd_ixgbe/ixgbe_rxtx_vec.c:735:9:
error: missing braces around initializer [-Werror=missing-braces]
struct rte_mbuf mb_def = {0}; /* zeroed mbuf */
Tested with gcc-4.4.7 (CentOS), gcc-4.7.2 (Debian), gcc-4.9.2 (Arch),
clang-3.6.0 and icc-13.1.1.
Signed-off-by: Thomas Monjalon <thomas.monjalon@6wind.com>
Tested-by: Thomas Monjalon <thomas.monjalon@6wind.com>
Tested-by: John McNamara <john.mcnamara@intel.com>
Acked-by: John McNamara <john.mcnamara@intel.com>
Acked-by: Vlad Zolotarov <vladz@cloudius-systems.com>
The ethernet device ops function table should be made const for
safety and security.
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Neil Horman <nhorman@tuxdriver.com>
The test PMD uses a special type of eth_dev_ops to test features.
Rather allocating this separately, just put in the private data area.
This allows for next change to make dev_ops const.
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Neil Horman <nhorman@tuxdriver.com>
rte_free like Glibc free allows rte_free(NULL) as null operation.
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Neil Horman <nhorman@tuxdriver.com>
Remove useless memset, since dev_private is created by rte_zmalloc
it must already be zero.
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Neil Horman <nhorman@tuxdriver.com>
Document the functions introduced by commit 64fc36064d.
Signed-off-by: Olivier Matz <olivier.matz@6wind.com>
Acked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
After the last enabled port has been seen, and the last time we
evaluate the loop condition, there is an out of bounds read in
ports[p].enabled because p is equal to size, which is the length of
ports.
Signed-off-by: Julien Cretin <julien.cretin@trust-in-soft.com>
Acked-by: Thomas Monjalon <thomas.monjalon@6wind.com>
Option var-tracking-assignments supported in gcc from 4.4.
Add gcc version check wil fix this issue.
error: unrecognized command line option "-fno-var-tracking-assignments"
Fixes: 74adbc5ef7 ("app/test: disable variable tracking assignment for memcpy")
Signed-off-by: Marvin Liu <yong.liu@intel.com>
Build app/test will be failed for function only defined but not used.
test_prefetch.c:65: error: ‘testfn_prefetch_cmd’ defined but not used
Add attribute used in test function declaration can fix this.
static void __attribute__((used)) testfn_##t(void);
Fixes: 727909c592 ("app/test: introduce dynamic commands list")
Signed-off-by: Marvin Liu <yong.liu@intel.com>
When port id is RTE_PORT_ALL, port_id_is_invalid will also return zero.
So this function will only set ports[255] need_reconfig flag, other ports will
be skipped.
Fixes: edab33b1c0 ("app/testpmd: support port hotplug")
Signed-off-by: Marvin Liu <yong.liu@intel.com>
Acked-by: Changchun Ouyang <changchun.ouyang@intel.com>
Fix a warning when the rte_common.h header is included in a compilation
using -Wbad-function-cast, such as in Open vSwitch where the
following warning is emitted repeatedly:
../rte_common.h: In function 'rte_is_aligned':
../rte_common.h:184:9: warning: cast from function call of
type 'uintptr_t' to non-matching type 'void *' [-Wbad-function-cast]
This change fixes the issue in rte_common.h by using the RTE_ALIGN_FLOOR
macro to get the aligned floor value with generic type casting.
Also removed the rte_align_floor_int() function and replaced it with
the RTE_PTR_ALIGN_FLOOR() macro.
Signed-off-by: John McNamara <john.mcnamara@intel.com>
Acked-by: Neil Horman <nhorman@tuxdriver.com>
testpmd parameter "nb-port" mean the number of forwarding port.
It's incorrect to use function port_id_is_invalid to check number of ports.
Fixes: edab33b1c0 ("app/testpmd: support port hotplug")
Signed-off-by: Yong Liu <yong.liu@intel.com>
Acked-by: Thomas Monjalon <thomas.monjalon@6wind.com>
Ixgbe doesn't support the ipv4-frag and ipv6-frag flow types, remove them.
Ixgbe doesn't support configure flex mask on each kind of flow type, this
patch uses RTE_ETH_FLOW_UNKNOWN to specify global flex mask setting.
This patch also changes the string "raw" to "none" to indicate flex mask
setting unrelated with flow type in testpmd for ixgbe.
Signed-off-by: Jingjing Wu <jingjing.wu@intel.com>
When user quits testpmd, and there is traffic being forwarded,
that may produce a segmentation fault, due to ports being closed,
while they are still transmitting packets.
This patch prevents the issue from happening,
by stopping packet forwarding before closing the ports.
Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
There is no remaining reference to E_RTE_NO_TAILQ.
Signed-off-by: David Marchand <david.marchand@6wind.com>
Acked-by: Neil Horman <nhorman@tuxdriver.com>
This register system makes it possible to reserve a tailq for the dpdk
libraries.
The "dynamic" tailqs are right after the "static" tailqs in shared mem.
Primary process is responsible for writing the tailq names, so that secondary
processes can find them.
This is a temp commit, "static" tailqs are removed after conversion of all
users in next commits.
Signed-off-by: David Marchand <david.marchand@6wind.com>
Acked-by: Neil Horman <nhorman@tuxdriver.com>
The "reserve" macros and functions do not check if the requested entry is free.
They do nothing more than the lookup function (which itself "creates" entries
...).
The rte_tailq api is marked as "internal use" in documentation and these macros
are only used in test application, so just get rid of them.
Signed-off-by: David Marchand <david.marchand@6wind.com>
Acked-by: Neil Horman <nhorman@tuxdriver.com>
test_hash.c: In function ‘test_crc32_hash_alg_equiv’:
error: format ‘%lu’ expects argument of type ‘long unsigned int’,
but argument 2 has type ‘size_t’ [-Werror=format]
According to C99, for size_t type should use format "%zu"
Signed-off-by: Michael Qiu <michael.qiu@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
This patch enables testpmd user can config port hw_vlan with more fine granularity:
hw vlan filter, hw vlan strip, and hw vlan extend.
Don't remove the original command(hw-vlan) considering that some user still want to use
only one command to switch on/off all 3 options.
Signed-off-by: Changchun Ouyang <changchun.ouyang@intel.com>
Acked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
This patch modifies testpmd behavior when setting:
rx_vlan add all vf_port (enabling all vlanids
to be passed thru rx filter on VF).
Rx_vlan_all_filter_set() function,
checks if the next vlanid can be enabled by the driver.
Number of vlanids is limited by the NIC and thus the NIC
do not allow to enable more vlanids than it can allocate
in VFTA table.
Signed-off-by: Michal Jastrzebski <michalx.k.jastrzebski@intel.com>
Acked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
When invoking creation of bonded device using:
create bonded device mode socket in testpmd the bonded port was not
enabled at the end of cmd_create_bonded_device_parsed function.
This caused commands 'show port info' and 'show port stats' not working
properly with bonding device. This patch fixed it.
Signed-off-by: Michal Jastrzebski <michalx.k.jastrzebski@intel.com>
Acked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Currently, if try to start/stop/close one invalid port,
no error shows in testpmd.
This is a bug, need check the port number.
Signed-off-by: Michael Qiu <michael.qiu@intel.com>
Acked-by: Tetsuya Mukawa <mukawa@igel.co.jp>
As hotplug has been enabled, start the testpmd with no nic binded
will show one error log "Please stop the ports first":
Interactive-mode selected
Please stop the ports first
Done
testpmd>
This issue is cause by the logic of check link status.
Signed-off-by: Michael Qiu <michael.qiu@intel.com>
Acked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
The malloc family returns void * and therefore cast is unnecessary.
Use calloc rather than zmalloc with multiply for array.
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
If testpmd is invoked with portmask option like below, segmentation
fault will occur. This patch fixes the issue.
Reported-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Signed-off-by: Tetsuya Mukawa <mukawa@igel.co.jp>
Acked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
The patch introduces following commands.
- port attach [ident]
- port detach [port_id]
- attach: attaching a port
- detach: detaching a port
- ident: pci address of physical device.
Or device name and parameters of virtual device.
(ex. 0000:02:00.0, eth_pcap0,iface=eth0)
- port_id: port identifier
Signed-off-by: Tetsuya Mukawa <mukawa@igel.co.jp>
Acked-by: Bernard Iremonger <bernard.iremonger@intel.com>
This new parameter is needed to keep device type like PCI or virtual.
Port detaching processes are different between PCI device and virtual
device.
RTE_ETH_DEV_PCI indicates device type is PCI. RTE_ETH_DEV_VIRTUAL
indicates device is virtual.
Signed-off-by: Tetsuya Mukawa <mukawa@igel.co.jp>
New function test_crc32_hash_alg_equiv() checks whether software,
4-byte operand and 8-byte operand versions of CRC32 hash function
implementations return the same result value.
Signed-off-by: Yerden Zhumabekov <e_zhumabekov@sts.kz>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Main code changes:
1. Added more typical data points for a thorough performance test
2. Added unaligned test cases since it's common in DPDK usage
Signed-off-by: Zhihong Wang <zhihong.wang@intel.com>
Acked-by: Cunming Liang <cunming.liang@intel.com>
Acked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Removed unnecessary test cases for base move functions
since the function "func_test" covers them all.
Signed-off-by: Zhihong Wang <zhihong.wang@intel.com>
Acked-by: Cunming Liang <cunming.liang@intel.com>
Acked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
VTA is for debugging only, it increases compile time and binary size,
especially when there're a lot of inlines.
So disable it since memcpy test contains a lot of inline calls.
Signed-off-by: Zhihong Wang <zhihong.wang@intel.com>
Acked-by: Cunming Liang <cunming.liang@intel.com>
Acked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
- API rte_timer_reset() should return -1 when the timer is in the
RUNNING or CONFIG state. Instead, it ignores the return value of
internal function __rte_timer_reset() and always returns 0.
We change rte_timer_reset() to return the value returned by
__rte_timer_reset().
- Enhance timer stress test 2 to report how many timer reset
collisions occur, i.e., how many times rte_timer_reset() fails
due to a timer being in the CONFIG state.
Signed-off-by: Robert Sanford <rsanford2@gmail.com>
Acked-by: Olivier Matz <olivier.matz@6wind.com>
In test_sched, we are missing NULL pointer checks after create_mempool()
and rte_pktmbuf_alloc(). Add in these checks using TEST_ASSERT_NOT_NULL macros.
VERIFY macro was removed and replaced by standard test ASSERTS from "test.h" header.
This provides additional information to track when the failure occurred.
Signed-off-by: Daniel Mrzyglod <danielx.t.mrzyglod@intel.com>
Following commit c07691ae10, an implicit change has been done in the
devargs API.
This triggers problem in virtual pmds that did not check for parameters
validity as it was implicitely valid.
Fix this by restoring the empty argument as "" and add a note in the api.
Restore associated tests.
Fixes: c07691ae10 ("devargs: remove limit on parameters length")
Reported-by: Tetsuya Mukawa <mukawa@igel.co.jp>
Signed-off-by: David Marchand <david.marchand@6wind.com>
Tested-by: Tetsuya Mukawa <mukawa@igel.co.jp>
The 'callbacks' member of the rte_eth_dev structure has been renamed
to 'link_intr_cbs' to make it clear that it refers to callbacks from
NIC interrupts. This allows us to add other types of callbacks to
the structure without ambiguity.
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
Signed-off-by: John McNamara <john.mcnamara@intel.com>
Acked-by: Thomas Monjalon <thomas.monjalon@6wind.com>
This patch removes all references to RTE_MBUF_REFCNT, setting the refcnt
field in the mbuf struct permanently.
Signed-off-by: Sergio Gonzalez Monroy <sergio.gonzalez.monroy@intel.com>
Acked-by: Olivier Matz <olivier.matz@6wind.com>
Acked-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
Since rte_hash_crc() can now be run regardless of SSE4.2 support,
we can safely remove compile checks for RTE_MACHINE_CPUFLAG_SSE4_2
in test utilities.
Signed-off-by: Yerden Zhumabekov <e_zhumabekov@sts.kz>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Enhance csum fwd engine based on current TX checksum framework in order
to test TX Checksum offload for NVGRE packet.
It includes:
- IPv4 and IPv6 packet
- outer L3, inner L3 and L4 checksum offload for Tx side.
Signed-off-by: Jijiang Liu <jijiang.liu@intel.com>
Signed-off-by: Declan Doherty <declan.doherty@intel.com>
Extend the "tunnel_filter" command in testpmd to test the RX tunnel filter API for NVGRE packet.
Signed-off-by: Jijiang Liu <jijiang.liu@intel.com>
Signed-off-by: Declan Doherty <declan.doherty@intel.com>
RSS offloads supported 'ip' and 'udp' only, which did not demonstrate
all of the hardware capabilities. The modifications adds support of
new RSS offloads of 'tcp', 'sctp', 'ether' and 'all'.
Signed-off-by: Helin Zhang <helin.zhang@intel.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
RSS offload types were defined separately for 1/10G and 40G NICs,
and have no relationship with flow types. The modifications are to
unify all RSS offload types for all PMDs. Unified RSS offload types
have new and common names which can be used for any PMD or
applications, and decouple from specific hardwares.
Signed-off-by: Helin Zhang <helin.zhang@intel.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
[Thomas: merge with fm10k]
Signed-off-by: Thomas Monjalon <thomas.monjalon@6wind.com>
Flow types was defined actually for i40e hardware specifically,
and wasn't able to be used for defining RSS offload types of all
PMDs. It removed the enum flow types, and uses macros instead
with new names. The new macros can be used for defining RSS
offload types later. Also modifications are made in i40e and
testpmd accordingly.
Signed-off-by: Helin Zhang <helin.zhang@intel.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
[Thomas: merge with new flow director API]
Signed-off-by: Thomas Monjalon <thomas.monjalon@6wind.com>
Following commands of syn filter are removed:
- add_syn_filter (port_id) priority (high|low) queue (queue_id)
- remove_syn_filter (port_id)
- get_syn_filter (port_id)
New command is added for syn filter by using filter_ctrl API and new
syn filter structure:
- syn_filter (port_id) (add|del) priority (high|low) queue (queue_id)
Signed-off-by: Jingjing Wu <jingjing.wu@intel.com>
Following commands of flex filter are removed:
- add_flex_filter (port_id) len (len_value) bytes (bytes_string) mask (mask_value)
priority (prio_value) queue (queue_id)
- remove_flex_filter (port_id) index (idx)
- get_flex_filter (port_id) index (idx)
New command is added for flex filter by using filter_ctrl API and new flex filter structure:
- flex_filter (port_id) (add|del) len (len_value) bytes (bytes_value) mask (mask_value)
priority (prio_value) queue (queue_id)
Signed-off-by: Jingjing Wu <jingjing.wu@intel.com>
Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
This patch sets the default value of flow director's mask.
Signed-off-by: Jingjing Wu <jingjing.wu@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
This patch removes the flexbytes_offset from rte_fdir_conf, because
the flexible payload setting is done by flex_conf instead of flexbytes_offset.
Signed-off-by: Jingjing Wu <jingjing.wu@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
Added 4 unit tests checking link bonding mode 6 behavior.
Also modified virtual_pmd so it is possible to provide packets,
that should be received with rx_burst and to inspect packets
transmitted by tx_burst.
In packet_burst_generator.c function creating eth_header is
modified, so it accepts ether_type as a parameter and function
creating arp_header is added. Updated other unit tests to get
rid of compilation errors.
Signed-off-by: Maciej Gajdzica <maciejx.t.gajdzica@intel.com>
Acked-by: Declan Doherty <declan.doherty@intel.com>
This patch modify mode older name from
BONDING_MODE_ADAPTIVE_TRANSMIT_LOAD_BALANCING to BONDING_MODE_TLB
This patch also changes order of TEST_ASSERT macro in
test_tlb_verify_slave_link_status_change_failover.
Signed-off-by: Daniel Mrzyglod <danielx.t.mrzyglod@intel.com>
Acked-by: Declan Doherty <declan.doherty@intel.com>
Changed MAC address type from uint8_t[6] to struct ether_addr and IP
address type from uint8_t[4] to uint32_t to make it consistent with
other DPDK code using MAC and IP addresses. It allows us to use
is_same_ether_addr and ether_addr_copy functions on MAC addresses in ARP header. Also
removed union from arp_hdr struct to make calls to arp_data items
shorter. Updated test-pmd to match new arp_hdr version.
Signed-off-by: Maciej Gajdzica <maciejx.t.gajdzica@intel.com>
Acked-by: Declan Doherty <declan.doherty@intel.com>
[Thomas: doxygenize comments]
rx_fc_en and tx_fc_en in cmd_link_flow_ctrl_set_parsed
could be used without being initialized.
Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
This patch links test application against librte_pmd_ring.so for shared
libraries. It's required as long as librte_pmd_ring provides some additional
routines used for testing purposes and must be "hard-linked".
Signed-off-by: Tomasz Kulasek <tomaszx.kulasek@intel.com>
Acked-by: Declan Doherty <declan.doherty@intel.com>
This patch adds unit tests for mode 4. It is split into separate
file to avoid problems with other modes that does not need to
look into packets payload.
This patch includes also a modification of maximum number of ports
used in their tests for bonding modes 0-3 from 16 to 6.
Signed-off-by: Pawel Wodkowski <pawelx.wodkowski@intel.com>
Signed-off-by: Tomasz Kulasek <tomaszx.kulasek@intel.com>
Acked-by: Declan Doherty <declan.doherty@intel.com>
Adding new reorder unit test for the test app.
The command to run the unit test from the test shell is: reorder_autotest
Signed-off-by: Reshma Pattan <reshma.pattan@intel.com>
Signed-off-by: Sergio Gonzalez Monroy <sergio.gonzalez.monroy@intel.com>
Acked-by: Neil Horman <nhorman@tuxdriver.com>
Acked-by: Declan Doherty <declan.doherty@intel.com>