Pablo de Lara [Thu, 13 Oct 2016 19:21:53 +0000 (20:21 +0100)]
doc: how to build KASUMI as shared library
Libsso KASUMI library has to be built with specific
parameters to make the KASUMI PMD be built as
a shared library, so a note has been added in
its documentation.
Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Pablo de Lara [Thu, 13 Oct 2016 18:48:15 +0000 (19:48 +0100)]
doc: add ZUC shared library limitation
ZUC PMD cannot be built as a shared library, due to
the fact that some assembly code in the underlying libsso
library is not relocatable.
This will be fixed in the future, but for the moment,
it is added as a limitationof the PMD.
Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Pablo de Lara [Tue, 11 Oct 2016 01:15:05 +0000 (02:15 +0100)]
crypto/libcrypto: fix init function names
All init/uninit function names in the virtual devices have been renamed,
so they finish with probe or remove, so to keep consistency,
same thing should be done in this PMD.
Fixes: d61f70b4c918 ("crypto/libcrypto: add driver for OpenSSL library") Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com> Acked-by: Fiona Trahe <fiona.trahe@intel.com>
Pablo de Lara [Tue, 11 Oct 2016 01:14:52 +0000 (02:14 +0100)]
crypto/zuc: fix init function names
All init/uninit function names in the virtual devices have been renamed,
so they finish with probe or remove, so to keep consistency,
same thing should be done in this PMD.
Fixes: cf7685d68f00 ("crypto/zuc: add driver for ZUC library") Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com> Acked-by: Fiona Trahe <fiona.trahe@intel.com>
Piotr Azarewicz [Tue, 11 Oct 2016 10:06:53 +0000 (12:06 +0200)]
app/test: fix crypto mbuf pool size
The created pool for crypto mbufs may be too big in some
environments.
To avoid this issue, mbuf pool is reverted to its previous size.
Moreover, here is added additional small pool with one large mbuf,
that is needed in large data test scenarios.
Fixes: ffbe3be0d4b5 ("app/test: add libcrypto") Signed-off-by: Piotr Azarewicz <piotrx.t.azarewicz@intel.com> Acked-by: Michal Jastrzebski <michalx.k.jastrzebski@intel.com>
Marcin Kerlin [Mon, 10 Oct 2016 08:07:50 +0000 (10:07 +0200)]
app/test: reduce libcrypto operations number
This patch reduce the number of total operations from 1M to 10K,
because test is taking too long time now.
Fixes: ffbe3be0d4b5 ("app/test: add libcrypto") Signed-off-by: Marcin Kerlin <marcinx.kerlin@intel.com> Acked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
ethdev: add an argument to internal callback function
add cb_arg parameter to the _rte_eth_dev_callback_process function.
Adding a parameter to this function allows passing information
to the application when an eth device event occurs such as
a VF to PF message.
This allows the application to decide if a particular function
is permitted.
Signed-off-by: Bernard Iremonger <bernard.iremonger@intel.com> Signed-off-by: Alex Zelezniak <alexz@att.com>
Xiao Wang [Tue, 6 Sep 2016 01:27:29 +0000 (09:27 +0800)]
net/fm10k: implement new Rx checksum flag
Add CKSUM_GOOD flag to distinguish a good checksum from an unknown one.
Since vector Rx supports checksum offload, this patch removes the
hw_ip_checksum check in fm10k_rx_vec_condition_check().
Signed-off-by: Xiao Wang <xiao.w.wang@intel.com> Acked-by: Jing Chen <jing.d.chen@intel.com>
add test for set vf vlan anti spoof
add test for set vf mac anti spoof
add test for set vf vlan stripq
add test for set vf vlan insert
add test for set tx loopback
add test for set all queues drop enable bit
add test for set vf split drop enable bit
add test for set vf mac address
add new APIs to testpmd help command.
add new APIs to the testpmd guide
Modify Makefile, add library rte_pmd_ixgbe to _LDLIBS-y.
Signed-off-by: Bernard Iremonger <bernard.iremonger@intel.com>
Ferruh Yigit [Wed, 31 Aug 2016 16:51:11 +0000 (17:51 +0100)]
net/ring: fix ring device creation via devargs
Using nodeaction devarg lets creating multiple ring eth devices:
"eth_ring0,nodeaction=R0:0:CREATE,nodeaction=R1:0:CREATE"
Trying to create all devices with same name fails. Since first part of
the nodeaction devarg is name (in above sample R0,R1), this name field
can be used as eth dev name.
Fixes: 61934c0956d4 ("ring: convert to use of PMD_REGISTER_DRIVER and fix linking") Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com> Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Ajit Khaparde [Tue, 11 Oct 2016 21:47:50 +0000 (16:47 -0500)]
net/bnxt: support async link notification
This patch adds support to get Link notification asynchronously.
The HW sends async notifications on default completion ring. The
PMD processes these notifications and logs a message appropriately.
Chas Williams [Tue, 11 Oct 2016 23:04:59 +0000 (19:04 -0400)]
net/bnx2x: check return codes during VF mailbox operation
Refactor bnx2x_do_req4pf() to be easier to read and return errors when
the transaction fails -- Previously, it could succeed when the control
channel was down.
Chas Williams [Tue, 11 Oct 2016 23:04:56 +0000 (19:04 -0400)]
net/bnx2x: restrict Rx mask flags sent to the PF
Don't use bnx2x_fill_accept_flags() to fill the RX mask in the VF
since the PF only handles a subset of the existing flags. now,
bnx2x_fill_accept_flags() can be static.
John Daley [Wed, 24 Aug 2016 19:07:02 +0000 (12:07 -0700)]
net/enic: add ethernet VLAN packet type
Enic is capable of recognizing packets to be delivered to the
app with single VLAN tags. Advertise this with the ptype
RTE_PTYPE_L2_ETHER_VLAN and set the ptype for VLAN packets.
John W. Linville [Thu, 29 Sep 2016 17:39:36 +0000 (13:39 -0400)]
net/bnxt: fix bit shift size
Some(?) compilers will treat the unmarked constant 1 as a 32-bit
integer, but the shift operation is in a loop that could run up to
63 times -- undefined behavior!
Coverity issue: 127546 Fixes: 778b759ba10e ("net/bnxt: add MAC address") Signed-off-by: John W. Linville <linville@tuxdriver.com> Acked-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
John W. Linville [Thu, 29 Sep 2016 17:39:34 +0000 (13:39 -0400)]
net/bnxt: ensure entry length is unsigned
Otherwise, the inherent cast when multiplying entry_length by max_vnics
in the call to rte_memzone_reserve could promote max_vnics to a signed
value, causing hilarity to ensue...
Coverity issue: 127557 Fixes: 9738793f28ec ("net/bnxt: add VNIC functions and structs") Signed-off-by: John W. Linville <linville@tuxdriver.com> Acked-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
John W. Linville [Thu, 29 Sep 2016 17:39:33 +0000 (13:39 -0400)]
net/ena: improve safety of string handling
Use sizeof dest rather than sizeof src for limiting copy length,
and replace strncpy with snprintf to ensure NULL termination.
Coverity issue: 127795 Fixes: 372c1af5ed8f ("net/ena: add dedicated memory area for extra device info") Signed-off-by: John W. Linville <linville@tuxdriver.com> Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>
Rasesh Mody [Thu, 6 Oct 2016 05:36:37 +0000 (22:36 -0700)]
net/bnx2x: fix socket id for slowpath memory
When the DMA allocation routine is invoked in the context of a non-EAL
thread, the API rte_lcore_id() returns -1 and indexing on that in
rte_lcore_to_socket_id() leads to segfault. The fix is to use
SOCKET_ID_ANY as the socket_id for all slowpath memory allocation.
John Daley [Thu, 29 Sep 2016 20:56:39 +0000 (13:56 -0700)]
net/enic: extend flow director support for 1300 series
1300 series Cisco adapter firmware version 2.0(13) for UCS
C-series servers and 3.1(2) for blade servers supports more
filtering capabilities. The feature can be enabled via Cisco
CIMC or USCM with the 'advanced filters' radio button. When
enabled, the these additional flow director modes are available:
RTE_ETH_FLOW_NONFRAG_IPV4_OTHER
RTE_ETH_FLOW_NONFRAG_IPV4_SCTP
RTE_ETH_FLOW_NONFRAG_IPV6_UDP
RTE_ETH_FLOW_NONFRAG_IPV6_TCP
RTE_ETH_FLOW_NONFRAG_IPV6_SCTP
RTE_ETH_FLOW_NONFRAG_IPV6_OTHER
Changes:
- Detect and set an 'advanced filters' flag dependent on the adapter
capability.
- Implement RTE_ETH_FILTER_INFO filter op to return the flow types
available dependent on whether advanced filters are enabled.
- Use a function pointer to select how filters are added to the adapter:
copy_fltr_v1() for older firmware/adapters or copy_fltr_v2() for
adapters which support advanced filters.
- Apply fdir global masks to filters when in advanced filter mode.
- Update documentation.
Signed-off-by: John Daley <johndale@cisco.com> Reviewed-by: Nelson Escobar <neescoba@cisco.com>
John Daley [Thu, 29 Sep 2016 20:56:38 +0000 (13:56 -0700)]
net/enic/base: update VIC adapter
Update the VIC adapter file which is common with the firmware and
other VIC drivers. This is needed to support new capabilities
for 1300 adapters, including advanced filtering, which is available
in VIC firmware version 2.0(13) for UCS rack and 3.1(2).
John Daley [Thu, 29 Sep 2016 20:56:37 +0000 (13:56 -0700)]
net/enic: fix crash with removed flow director filters
When flow director filters where removed when an enic device is
stopped, the filters were freed but the pointer was not set to
NULL so the next stop would try to free them again.
Fixes: fefed3d1e62c ("enic: new driver") Signed-off-by: John Daley <johndale@cisco.com>
Nelson Escobar [Thu, 29 Sep 2016 20:55:05 +0000 (13:55 -0700)]
net/enic: document how to configure vNIC parameters
Update the enic guide to better explain how to setup vNIC parameters
on the Cisco VIC since the introduction of rx scatter, and print an
error message for the case of having 1 RQ configured in the vNIC,
referring to the documentation for more information.
Signed-off-by: Nelson Escobar <neescoba@cisco.com> Acked-by: John McNamara <john.mcnamara@intel.com>
net/thunderx: add final bits for secondary queue support
Summary:
- add secondary qset support in device stats
- add support for releasing mbufs from RBDR for >8 queues
- add support for releasing mbufs from RX queues for >8 queues
- support >8 queues in tx_queue_setup
- support >8 queues in rx_queue_setup
- support up to 96 queues per device (dev_info->max_rx_queues)
- add secondary qset support in rbdr_rte_mempool_get
- support >8 queues in multiprocess mode (do not reconfigure VFs)
- setup periodic alarm accordingly for type of VFs:
* primary VF - handle events on queues and link status
* secondary VF - handle events on queues
- initialize hardware capabilities in secondary qsets
In case of the multiprocess mode a shared nicvf struct between processes
cannot point with the eth_dev pointer to master device, therefore remove it
along with references to it refactoring the code where needed.
This change fixes multiprocess issues detected in stats.
net/thunderx/base: add secondary queue set support
Changes:
- add new message sqs_alloc in mailbox
- add a queue container to hold secondary qsets.
- add nicvf_mbox_request_sqs
- handle new mailbox messages for secondary queue set support
- register secondary queue sets for further reuse
- register the number secondary queue sets in MSG_QS_CFG
The symbols PKT_TX_TCP_CKSUM and PKT_TX_UDP_CKSUM are not bits on a
bitmask. Set l3_offset always for TX offloads, not just for PKT_TX_IP_CKSUM
being true.
Fixes: 1c421f18e095 ("net/thunderx: add single and multi-segment Tx") Signed-off-by: Maciej Czekaj <maciej.czekaj@caviumnetworks.com> Signed-off-by: Kamil Rytarowski <kamil.rytarowski@caviumnetworks.com> Signed-off-by: Zyta Szpak <zyta.szpak@semihalf.com> Signed-off-by: Slawomir Rosek <slawomir.rosek@semihalf.com> Signed-off-by: Radoslaw Biernacki <rad@semihalf.com> Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
Refactored features:
- enable nicvf_qset_rbdr_precharge to handle secondary queue sets
- rte_free already handles NULL pointer
- check mempool flags to predict being contiguous in memory
- prohibit to use mempool with multiple memory chunks
- simplify local construct of accessing nb_rx_queues
- enable NICVF_CAP_CQE_RX2 on CN88XX PASS2.0 hardware.
- remove redundant check for RSS size in nicvf_eth_dev_init
Eric Kinzie [Thu, 4 Aug 2016 18:24:43 +0000 (11:24 -0700)]
net/bonding: enable slave VLAN filter
SR-IOV virtual functions cannot rely on promiscuous mode for the reception
of VLAN tagged frames. Program the VLAN filter for each slave when a
VLAN is configured for the bonding master.
Signed-off-by: Eric Kinzie <ehkinzie@gmail.com> Acked-by: Bernard Iremonger <bernard.iremonger@intel.com>
Eric Kinzie [Thu, 4 Aug 2016 18:24:42 +0000 (11:24 -0700)]
net/bonding: validate speed after link up
It's possible for the bonding driver to mistakenly reject an interface
based in it's, as yet, unnegotiated link speed and duplex. Always allow
the interface to be added to the bonding interface but require link
properties validation to succeed before slave is activated.
Fixes: 2efb58cbab6e ("bond: new link bonding library") Signed-off-by: Eric Kinzie <ehkinzie@gmail.com> Acked-by: Bernard Iremonger <bernard.iremonger@intel.com>
This patch adds "Limitations or Known issues" section for
i40e PMD, including two items:
1. MPLS packet classification on X710/XL710
2. 16 Byte Descriptor cannot be used on DPDK VF
3. Link down with i40e kernel driver after DPDK application exist
Signed-off-by: Jingjing Wu <jingjing.wu@intel.com> Acked-by: John McNamara <john.mcnamara@intel.com>
Wei Dai [Mon, 8 Aug 2016 06:42:37 +0000 (14:42 +0800)]
lpm: remove redundant check when adding rule
When a rule with depth > 24 is added into an existing
rule with depth <=24, a new tbl8 is allocated, the existing
rule first fulfill whole new tbl8, so the filed valid of
each entry in this tbl8 is always true and depth of each
entry is always <= 24 before adding the new rule with depth > 24.
Signed-off-by: Wei Dai <wei.dai@intel.com> Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Wei Dai [Mon, 8 Aug 2016 06:39:51 +0000 (14:39 +0800)]
lpm: fix freeing unused sub-table on rule delete
When all rules with depth > 24 are deleted in a same sub-table
(tlb8 group) and only a rule with depth <=24 is left in it,
this sub-table (tlb8 group) should be recycled.
Fixes: dc81ebbacaeb ("lpm: extend IPv4 next hop field") Fixes: af75078fece3 ("first public release") Signed-off-by: Wei Dai <wei.dai@intel.com> Acked-by: Bruce Richardson <bruce.richardson@intel.com>
John Ousterhout [Wed, 12 Oct 2016 19:38:32 +0000 (12:38 -0700)]
log: respect logger configured before EAL init
Before this patch, application-specific loggers could not be
installed before rte_eal_init completed (the initialization process
called rte_openlog_stream, overwriting any previously installed
logger). This made it impossible for an application to capture the
initial log messages generated during rte_eal_init. This patch changes
initialization so that information from a previous call to
rte_openlog_stream is not lost. Specifically:
* The default log stream is now maintained separately from an
application-specific log stream installed with rte_openlog_stream.
* rte_eal_common_log_init has been renamed to eal_log_set_default,
since this is all it does. It no longer invokes rte_openlog_stream; it
just updates the default stream. Also, this method now returns void,
rather than int, since there are no errors.
This patch also removes the "early log" mechanism and cleans up the
log initialization mechanism:
* The default log stream defaults to stderr on all platforms if
eal_log_set_default hasn't been invoked (Linux used to use stdout
during the first part of initialization).
* Removed rte_eal_log_early_init; all of the desired functionality can
be achieved by calling eal_log_set_default.
* Removed lib/librte_eal/bsdapp/eal/eal_log.c: it contained only one
function, rte_eal_log_init, which is not needed or invoked for BSD.
* Removed declaration for eal_default_log_stream in rte_log.h (it's now
private to eal_common_log.c).
* Moved call to rte_eal_log_init earlier in rte_eal_init for Linux, so
that it starts using the preferrred log ASAP.
Signed-off-by: John Ousterhout <ouster@cs.stanford.edu>
Olivier Matz [Thu, 13 Oct 2016 14:16:06 +0000 (16:16 +0200)]
mbuf: add flag for LRO
When receiving coalesced packets in virtio, the original size of the
segments is provided. This is a useful information because it allows to
resegment with the same size.
Add a RX new flag in mbuf, that can be set when packets are coalesced by
a hardware or virtual driver when the m->tso_segsz field is valid and is
set to the segment size of original packets.
This flag is used in next commits in the virtio pmd.
Signed-off-by: Olivier Matz <olivier.matz@6wind.com> Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com> Reviewed-by: Yuanhan Liu <yuanhan.liu@linux.intel.com>