In order to check the congestion state of Egress FQs,
this qbman function will be used by the DPAA2 Ethernet PMD.
Signed-off-by: Hemant Agrawal <hemant.agrawal@nxp.com>
Typically when the PMD issues a Rx command to DPAA2 hardware,
the HW writes the available descriptors into the given memory.
The RX function then processes the frames and prepare them as
mbufs.
This patch adds support to issue another pull request to hardware
in another memory location, before we start processing the output
of the first request. This help in controlling the CPU cycles
wasted during the wait for the hardware to write the descriptors.
Signed-off-by: Hemant Agrawal <hemant.agrawal@nxp.com>
DPAA2 hardware support the option to configure
multiple memories for Rx recv buffer (DPAA2-DQRR).
Each Rx request executing is called as 'DQ' request.
This patch adds routines to get information w.r.t each DQ request.
Signed-off-by: Hemant Agrawal <hemant.agrawal@nxp.com>
The DPAA2 driver is not using the DPAA2 frame descriptor
software annotation area. This patch reduces the
PTA length to zero and adjust the RX Buffer Layout
accordingly.
Signed-off-by: Hemant Agrawal <hemant.agrawal@nxp.com>
This code in device init is not required, as the buffer
layout setting is also being programmed during queue configuration.
Signed-off-by: Hemant Agrawal <hemant.agrawal@nxp.com>
Add subsystem device id of CN23xx cards and expose speed capability of
devices. Update liquidio feature file to mark support.
Signed-off-by: Shijith Thotton <shijith.thotton@caviumnetworks.com>
Before this patch, flex_filter->index was always zero when it was read
and used after rte_zmalloc. The corresponding code was therefore moved
into the add and delete parts of the if/else statement.
Fixes: 231d43909a ("igb: migrate flex filter to new API")
Cc: stable@dpdk.org
Signed-off-by: Markus Theil <markus.theil@tu-ilmenau.de>
Acked-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
i210/i211 also support flex filters. Tested on i210.
Signed-off-by: Markus Theil <markus.theil@tu-ilmenau.de>
Acked-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Completion buffer size was computed wrongly, causing
completion polling to wraparound too early and miss entries.
Fixing it by using Direct Verbs to query the CQ info.
Fixes: 6218063b39 ("net/mlx5: refactor Rx data path")
Fixes: 1d88ba1719 ("net/mlx5: refactor Tx data path")
Cc: stable@dpdk.org
Signed-off-by: Shahaf Shuler <shahafs@mellanox.com>
Acked-by: Yongseok Koh <yskoh@mellanox.com>
Acked-by: Nelio Laranjeiro <nelio.laranjeiro@6wind.com>
On error, we also need to zero the bytes transmitted.
Fixes: f4ff17a465 ("net/af_packet: guard against buffer overruns in Tx path")
Cc: stable@dpdk.org
Signed-off-by: Chas Williams <ciwillia@brocade.com>
Required to be able to use logging in the secondary process
where Ethernet device pointer stored in sfc_adapter is invalid.
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
Reviewed-by: Andy Moreton <amoreton@solarflare.com>
Added a debug function to print enic filters and actions when
rte_validate_flow is called. Compiled in CONFIG_RTE_LIBRTE_ENIC_DEBUG_FLOW
is enabled and log level is INFO.
Signed-off-by: John Daley <johndale@cisco.com>
Reviewed-by: Nelson Escobar <neescoba@cisco.com>
5-tuple exact Flow support for 1200 series adapters. This allows:
Attributes: ingress
Items: ipv4, ipv6, udp, tcp (must exactly match src/dst IP
addresses and ports and all must be specified).
Actions: queue and void
Selectors: 'is'
Signed-off-by: John Daley <johndale@cisco.com>
Reviewed-by: Nelson Escobar <neescoba@cisco.com>
Flow support for 1300 series adapters with the 'Advanced Filter'
mode disabled via the UCS management interface. This allows:
Attributes: ingress
Items: Outer eth, ipv4, ipv6, udp, sctp, tcp, vxlan. Inner eth, ipv4,
ipv6, udp, tcp.
Actions: queue and void
Selectors: 'is', 'spec' and 'mask'. 'last' is not supported
With advanced filters disabled, an IPv4 or IPv6 item must be specified
in the pattern.
Signed-off-by: John Daley <johndale@cisco.com>
Reviewed-by: Nelson Escobar <neescoba@cisco.com>
For VICs with filter tagging, support the MARK and FLAG actions
by setting appropriate mbuf ol_flags if there is a filter match.
Signed-off-by: John Daley <johndale@cisco.com>
Reviewed-by: Nelson Escobar <neescoba@cisco.com>
Flow support for 1300 series adapters with the 'Advanced Filter'
mode enabled via the UCS management interface. This enables:
Attributes: ingress
Items: Outer eth, ipv4, ipv6, udp, sctp, tcp, vxlan. Inner eth, ipv4,
ipv6, udp, tcp.
Actions: queue, and void
Selectors: 'is', 'spec' and 'mask'. 'last' is not supported
Signed-off-by: John Daley <johndale@cisco.com>
Reviewed-by: Nelson Escobar <neescoba@cisco.com>
Stub callbacks for the generic flow API and a new FLOW debug define.
Signed-off-by: John Daley <johndale@cisco.com>
Reviewed-by: Nelson Escobar <neescoba@cisco.com>
Update the base functions for the Cisco VIC. These files are mostly
common with other VIC drivers so are left alone is as much as possible.
Includes in a new filter/action interface which is needed for Generic
Flow API PMD support. Update FDIR code to use the new interface.
Signed-off-by: John Daley <johndale@cisco.com>
Reviewed-by: Nelson Escobar <neescoba@cisco.com>
Unfortunately the datasheet has a mistake. The
address of the TX error counter is wrong.
Fixes: 8db9e2a1b2 ("i40e: base driver")
CC: stable@dpdk.org
Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
i210 and i211 also support unicast MAC filters.
The patch was tested on i210 based hw, for i211
support was looked up in the specs.
Signed-off-by: Markus Theil <markus.theil@tu-ilmenau.de>
Acked-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Previously, the FDIR programming time is +11ms on i40e.
This patch will result in an average programming time of
22usec with a max of 60usec .
Signed-off-by: Michael Lilja <ml@napatech.com>
Acked-by: Beilei Xing <beilei.xing@intel.com>
Coverity issue: 144512
Coverity issue: 144513
Fixes: 9c7188a68d ("net/ark: provide API for hardware modules pktchkr and pktgen")
Cc: stable@dpdk.org
Signed-off-by: John Miller <john.miller@atomicrules.com>
Instead of many PMD define their own macro, define a generic one in
ethdev and use that in PMDs.
Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com>
Acked-by: Allain Legacy <allain.legacy@windriver.com>
Acked-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Acked-by: Andrew Rybchenko <arybchenko@solarflare.com>
remove __rte_unused instances that are not required.
Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com>
Acked-by: Allain Legacy <allain.legacy@windriver.com>
Acked-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Check for the current MAC address on both the remote and the tap
netdevices before setting a new value.
While there, remove wrong empty lines and ensure tap_ioctl() return
value is negative, just like what is done throughout this code.
Fixes: 2bc06869cd ("net/tap: add remote netdevice traffic capture")
Signed-off-by: Pascal Mazon <pascal.mazon@6wind.com>
This has three main benefits:
- tun_alloc is now generic again for any queue,
- mtu no longer needs to be handled in tap_setup_queue(),
- an actual netdevice is created as soon as the device is probed.
On top of it, code in eth_dev_tap_create() has been reworked to have a
more logical behavior; initialization can now fail if a remote is
requested but cannot be set up.
Fixes: 2bc06869cd ("net/tap: add remote netdevice traffic capture")
Signed-off-by: Pascal Mazon <pascal.mazon@6wind.com>
Print a detailed debug message inside tap_ioctl() directly. The caller
now only needs to check for return value.
Signed-off-by: Pascal Mazon <pascal.mazon@6wind.com>
Support for a fixed MAC address for testing with the last octet
incrementing by one for each interface defined with the new 'mac=fixed'
string on the --vdev option. The default option is still to randomize
the MAC address for each tap interface.
Signed-off-by: Keith Wiles <keith.wiles@intel.com>
Signed-off-by: Pascal Mazon <pascal.mazon@6wind.com>
Acked-by: Keith Wiles <keith.wiles@intel.com>
mbuf next and nb_segs fields already have the default values when get
from mempool, no need to update them in PMD.
See: 8f094a9ac5 ("mbuf: set mbuf fields while in pool")
Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com>
Reviewed-by: Olivier Matz <olivier.matz@6wind.com>
See: 8f094a9ac5 ("mbuf: set mbuf fields while in pool")
Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com>
Acked-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
The thunderx PMD is sensitive to the layout of the mbuf on
the RX path. Add in some compile-time checks to make sure the mbuf layout
assumptions are valid, and to provide hints to anyone changing the mbuf
where things may need to be updated.
Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
The vector PMD is very sensitive to the layout of the mbuf, especially on
the RX path. Add in some compile-time checks to make sure the mbuf layout
assumptions are valid, and to provide hints to anyone changing the mbuf
where things may need to be updated.
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
The vector PMD is very sensitive to the layout of the mbuf, especially on
the RX path. Add in some compile-time checks to make sure the mbuf layout
assumptions are valid, and to provide hints to anyone changing the mbuf
where things may need to be updated.
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
The vector PMD is very sensitive to the layout of the mbuf, especially on
the RX path. Add in some compile-time checks to make sure the mbuf layout
assumptions are valid, and to provide hints to anyone changing the mbuf
where things may need to be updated.
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
Different drivers use internal macros like force_inline for compiler
always inline feature.
Standardizing it through __rte_always_inline macro.
Verified the change by comparing the output binary file.
No difference found in the output binary file with this change.
Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
vfio is the kernel framework used by the vfio-pci kernel driver.
DPDK drivers do not rely solely on vfio, but rather on vfio-pci to gain
access to pci resources.
Fixes: 0880c40113 ("drivers: advertise kmod dependencies in pmdinfo")
Cc: stable@dpdk.org
Signed-off-by: David Marchand <david.marchand@6wind.com>
Acked-by: Olivier Matz <olivier.matz@6wind.com>
In mlx5_dev_start(), the spinlock isn't released when returning error.
Fixes: c8d4ee50cc ("net/mlx5: fix startup when flow cannot be applied")
Cc: stable@dpdk.org
Signed-off-by: Yongseok Koh <yskoh@mellanox.com>
Acked-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
With the change in base APIs the logic for 100G handling needs to be
adjusted to pass cid values instead for queue ids. The current API
works assuming its queue id.
Fixes: 69d7ba88f1 ("net/qede/base: use L2-handles for RSS configuration")
Signed-off-by: Rasesh Mody <rasesh.mody@cavium.com>
In the main loop of mlx5_tx_burst(), pointers/indexes are advanced at the
beginning. Therefore, those should be rolled back if checking resource
availability fails and breaks the loop. And some of them are even
redundant.
Signed-off-by: Yongseok Koh <yskoh@mellanox.com>
Acked-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
In case of resource deficiency on Tx, mlx5_tx_burst() breaks the loop
without rolling back consumed resources (txq->wqes[] and txq->elts[]). This
can make application crash because unposted mbufs can be freed while
processing completions. Other Tx functions don't have this issue.
Fixes: 3f13f8c23a ("net/mlx5: support hardware TSO")
Fixes: f04f1d5156 ("net/mlx5: fix Tx WQE corruption caused by starvation")
Cc: stable@dpdk.org
Reported-by: Hanoch Haim <hhaim@cisco.com>
Signed-off-by: Yongseok Koh <yskoh@mellanox.com>
Acked-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
There is a bug in previous fix for lsc interrupt.
lsc interrupt is not disabled before delayed handler,
that cause the delayed handler be re-entered.
Fixes: 9b66721070 ("net/ixgbe: fix blocked interrupts")
Cc: stable@dpdk.org
Signed-off-by: Qi Zhang <qi.z.zhang@intel.com>
Acked-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
hw->mac.ops.get_media-type() of ixgbe VF is NULL and should not
be called directly. It had better be replaced by calling
ixgbe_get_media_type( ) to avoid crash.
Fixes: c12d22f65b ("net/ixgbe: ensure link status is updated")
Signed-off-by: Wei Dai <wei.dai@intel.com>
Acked-by: Laurent Hardy <laurent.hardy@6wind.com>
Add a comment documenting explicitly that we are falling through the case
statements to the next one.
Fixes: f9072f8b90 ("ixgbe: migrate flow director filtering to new API")
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Add in a comment for each switch fall-through indicating that it is
intentional. This will fix compiler warnings with GCC 7.
Fixes: b5bf771922 ("bnx2x: driver support routines")
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
GCC 7 flags a value as uninitialized before used. While it's a false
positive, there is little harm in providing an initial value for the
variable.
Fixes: bb1d14b87f ("vmxnet3: fix link state handling")
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
For base code in drivers shared with other projects, disable the new
warnings from gcc 7 about unlabelled fall-through in switch statements.
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
strncpy may left destination buffer not NULL terminated, switched using
snprintf to be sure destination buffer is NULL terminated.
Coverity issue: 1407495
Coverity issue: 1407498
Fixes: cc68ac4847 ("net/af_packet: support MTU change")
Fixes: 218259590e ("net/af_packet: support promiscuous")
Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com>
If mlx5_dev_start() fails, it tries to rollback data structures related to
rte_flow including drop queue. The destruction code doesn't assume the
structures are created but priv_flow_delete_drop_queue() never does sanity
check. This can cause a crash.
Fixes: 028761059a ("net/mlx5: use an RSS drop queue")
Signed-off-by: Yongseok Koh <yskoh@mellanox.com>
Acked-by: Nelio Laranjeiro <nelio.laranjeiro@6wind.com>
When TSO is enabled, Verbs layer aggregates the TSO
inline size with the txq inline size for the Tx creation,
while the PMD takes the maximum among them.
Fixing it by adjusting the max inline parameter before
passing to to Verbs.
Fixes: 3f13f8c23a ("net/mlx5: support hardware TSO")
Signed-off-by: Shahaf Shuler <shahafs@mellanox.com>
Acked-by: Yongseok Koh <yskoh@mellanox.com>
Acked-by: Nelio Laranjeiro <nelio.laranjeiro@6wind.com>
Return mbuf points of _recv_raw_pkts_vec are modified out of bound.
Fixes: 8e109464c0 ("i40e: allow vector Rx and Tx usage")
Cc: stable@dpdk.org
Signed-off-by: Qi Zhang <qi.z.zhang@intel.com>
Return mbuf points of _recv_raw_pkts_vec are modified out of bound.
Fixes: c95584dc2b ("ixgbe: new vectorized functions for Rx/Tx")
Cc: stable@dpdk.org
Signed-off-by: Qi Zhang <qi.z.zhang@intel.com>
When counting max packet length from MTU, count
VLAN tag length twice for QinQ packets.
Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
There exists case that software sets mtu (i.e jumbo frame) of
ixgbe device when it's stopped. Before the fix, scattered_rx
is cleared during device stop, and setting jumbo frame mtu
after device stop will always fail as scattered_rx is 0.
Signed-off-by: Jia Yu <jyu@vmware.com>
Acked-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Some customers find that 82599 NIC DPDK VF PMD can't receive any
broadcast packets when it is bound to igb_uio in the first time
to run a DPDK application like testpmd. But when the application
is quited and run again, the DPDK VF PMD can receive broadcast
packets again. The associated PF is run by kernel driver when
the VF is driven by DPDK PMD.
Fixes: 260e2e22e2 ("net/ixgbe/base: move multicast mode update")
Fixes: 72dec9e37a ("ixgbe: support multicast promiscuous mode on VF")
Cc: stable@dpdk.org
Signed-off-by: Wei Dai <wei.dai@intel.com>
Acked-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Pool 0 is not PF, it's VF 0. So the MAC is set for VF 0
but not PF.
The code introduced a weird issue. In the scenario PF + VF,
when only starting PF, the default PF MAC address is working.
But after starting a VF, the default PF MAC address becomes
the VF's address.
Use the pool which is not occupied by VFs for PF to fix it.
Fixes: 8164fe8284 ("ixgbe: add default mac address modifier")
Cc: stable@dpdk.org
Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
We find that VF receive address register is not set
if MAC address is assigned by PF. This patch fixes it.
Fixes: d82170d279 ("igb: add VF support")
Cc: stable@dpdk.org
Signed-off-by: Qiming Yang <qiming.yang@intel.com>
Acked-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
VF default MAC address be added in PF Mac address list
instead of VF MAC address list, makes VF can't receive
packets. This patch fixes this issue.
Fixes: be2d648a2d ("igb: add PF support")
Cc: stable@dpdk.org
Signed-off-by: Qiming Yang <qiming.yang@intel.com>
Acked-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Some customers find adding MAC addr to VF sometimes can fail,
but it is still stored in dev->data->mac_addrs[ ]. So this
can lead to some errors that assumes the non-zero entry in
dev->data->mac_addrs[ ] is valid.
Following acknowledgements are from specific NIC PMD
maintainer for their managing part.
This patch changes the ethdev internal API, it should not be
backported to a stable/LTS release so far.
Fixes: af75078fec ("first public release")
Signed-off-by: Wei Dai <wei.dai@intel.com>
Acked-by: Nelio Laranjeiro <nelio.laranjeiro@6wind.com>
Acked-by: Yuanhan Liu <yuanhan.liu@linux.intel.com>
Acked-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
The VDEV code will move to the bus drivers directory.
Rename functions from rte_eal_vdev_ to rte_vdev_
to prepare the move of the driver out of EAL.
The prefix rte_eal_vdrv_ is also renamed to rte_vdev_.
It was used for registration of vdev drivers.
Signed-off-by: Thomas Monjalon <thomas@monjalon.net>
Acked-by: Stephen Hemminger <stephen@networkplumber.org>
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>
To achieve functionality of retrieving only specific statistics
given by application there are two new functions added:
ixgbe_dev_xstats_get_by_ids() which retrieve
values of statistics specified by ids array
and ixgbe_dev_xstats_get_names_by_ids() which retrieve
names of statistics specified by ids array.
Signed-off-by: Kuba Kozak <kubax.kozak@intel.com>
To achieve functionality of retrieving only specific statistics
given by application there are two new functions added:
eth_igb_xstats_get_by_id() which retrieve
values of statistics specified by ids array
and eth_igb_xstats_get_names_by_id() which retrieve
names of statistics specified by ids array.
Signed-off-by: Kuba Kozak <kubax.kozak@intel.com>
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>
Rx queues configured with more than 1023 descriptors cause readv() calls to
fail due to more iovec entries than permitted by the kernel. As a result,
no packets can be received.
Quietly limit internal Rx queue size to the maximum number of iovec entries
to fix this issue.
Fixes: 0781f5762c ("net/tap: support segmented mbufs")
Signed-off-by: Pascal Mazon <pascal.mazon@6wind.com>
RBDR buffers are refilled when SW consumes the buffers from CQ.
This creates deadlock case when CQ buffers exhausted due to lack
of RBDR buffers. Fix is to refill the RBDR when rx_free_thresh
meet, irrespective of the number of CQ buffers consumed.
Fixes: e2d7fc9f0a ("net/thunderx: add single and multi-segment Rx")
Cc: stable@dpdk.org
Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
Fix aad capabilities for AES-GCM authtentication, aad is changed from
range 8-12 to 0-65535
Fixes: 8a9867a635 ("crypto/openssl: rename libcrypto to openssl")
Cc: stable@dpdk.org
Signed-off-by: Arek Kusztal <arkadiuszx.kusztal@intel.com>
Acked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
This commit fixs segment fault when rte_eth_dev_close() is called on
a virtio dev more than once. Assigning zero after free to avoids
freed memory to be accessed again.
Fixes: 69c80d4ef8 ("net/virtio: allocate queue at init stage")
Cc: stable@dpdk.org
Signed-off-by: Huanle Han <hanxueluo@gmail.com>
Acked-by: Yuanhan Liu <yuanhan.liu@linux.intel.com>
Segfault happens when using virtio-user after commit 7f0a669e7b
("ethdev: add allocation helper for virtual drivers").
It's due to we use ethdev->device to recognize physical devices,
but after above commit, this field is also filled for virtual
devices. Then we obtain the wrong pci_dev pointer and accessing
its field when copying pci info results in segfault.
To fix it, we use hw->virtio_user_dev to differentiate physical
devices from virtual devices.
Fixes: 6a7c0dfcdf ("net/virtio: do not depend on PCI device of ethdev")
Signed-off-by: Jianfeng Tan <jianfeng.tan@intel.com>
Acked-by: Yuanhan Liu <yuanhan.liu@linux.intel.com>
The virtio port link status will always be DOWN:
The commit aa9f060617 ("net/virtio: fix link status always being up")
introduces a flag to help checking the status. If this flag is not set,
status will be always down. However, in dev start, this flag is set
after link status update, then we miss the chance to change the status
to UP in dev start.
To fix this bug, we simply move the link status update after the flag
setting so that the status can be correctly updated.
Fixes: aa9f060617 ("net/virtio: fix link status always being up")
Cc: stable@dpdk.org
Signed-off-by: Jianfeng Tan <jianfeng.tan@intel.com>
Acked-by: Yuanhan Liu <yuanhan.liu@linux.intel.com>
As we already change to use capability list to detect MSI-X, remove
the redundant MSI-X detection in legacy devices.
Signed-off-by: Jianfeng Tan <jianfeng.tan@intel.com>
Acked-by: Yuanhan Liu <yuanhan.liu@linux.intel.com>
LSC flag is set in several places, but only the last one takes effect;
so we remove the redundant ones and just keep the last one.
This also fixes the bug that dev_flags being overwritten by
rte_eth_copy_pci_info(), which resets it to 0 unconditionally.
Cc: stable@dpdk.org
Signed-off-by: Jianfeng Tan <jianfeng.tan@intel.com>
Acked-by: Yuanhan Liu <yuanhan.liu@linux.intel.com>
The field, use_msix, in struct virtio_hw is not updated for modern
device, and is always zero. And now we depend on the status feature
and MSI-X to report LSC support (which is also not a correct
behavior). As a result, LSC is always disabled for modern devices.
To fix this, we just recognize MSI-X capability when going through
capability list, and update the info in virtio.
Fixes: 6ba1f63b5a ("virtio: support specification 1.0")
Cc: stable@dpdk.org
Signed-off-by: Jianfeng Tan <jianfeng.tan@intel.com>
Acked-by: Yuanhan Liu <yuanhan.liu@linux.intel.com>
Add the support of RTE_FLOW_ITEM_TYPE_SCTP type packet for
ixgbe ntuple filter.
Fixes: 672be56d76 ("net/ixgbe: parse n-tuple filter")
Cc: stable@dpdk.org
Signed-off-by: Wei Zhao <wei.zhao1@intel.com>
Acked-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
In case of fiber and link speed set to 1Gb at peer side (with autoneg
or with defined speed), link status could be not properly updated at
time cable is plugged-in.
Indeed if cable was not plugged when device has been configured and
started then link status will not be updated properly with new speed
as no link setup will be triggered.
To avoid this issue, IXGBE_FLAG_NEED_LINK_CONFIG is set to try a link
setup each time link_update() is triggered and current link status is
down. When cable is plugged-in, link setup will be performed via
ixgbe_setup_link().
Signed-off-by: Laurent Hardy <laurent.hardy@6wind.com>
Acked-by: Wei Dai <wei.dai@intel.com>
We need to update dev->data->dev_link before handling LSC event.
Otherwise it will still have the initial value after the startup of
the program before interrupt callback was executed.
Fixes: 414b202343 ("bonding: fix initial link status of slave")
Cc: stable@dpdk.org
Signed-off-by: Wei Wang <lnykww@gmail.com>
Acked-by: Declan Doherty <declan.doherty@intel.com>
The type check for flow_type should be IXGBE_ATR_FLOW_TYPE_IPV4
in special card not RTE_ETH_FLOW_NONFRAG_IPV4_OTHER.
Fixes: dc0c16105d ("ixgbe: fix X550 flow director check")
Cc: stable@dpdk.org
Signed-off-by: Wei Zhao <wei.zhao1@intel.com>
Acked-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
If segments are used, just mbufs previously linked to head descriptor
of a mbuf chain are released. Other Tx descriptor are used for the
mbuf chain but they keep their linked mbufs without releasing them.
It is not a fatal issue because sooner or later those descriptors will
be head descriptors or just used for a single mbuf packet, then those
linked mbufs will be released.
However, this leads to apps needing bigger mbufs pools and some
confusion about memory requirements. Indeed, because larger pools, some
performance impact could also be expected due to cache misses.
With this patch all Tx descriptors will release linked mbufs inside the
xmit function, and rte_pktmbuf_seg_free is used instead of
rte_pktmbuf_free.
Fixes: 142854c621 ("nfp: fix freeing multi-mbuf packets")
Cc: stable@dpdk.org
Signed-off-by: Alejandro Lucero <alejandro.lucero@netronome.com>