Commit Graph

5113 Commits

Author SHA1 Message Date
Wei Zhao
088aed4b89 net/i40e: fix flow RSS key array error
This is a bug introduced into RSS key array span.

Fixes: ac8d22de23 ("ethdev: flatten RSS configuration in flow API")

Signed-off-by: Wei Zhao <wei.zhao1@intel.com>
Acked-by: Qi Zhang <qi.z.zhang@intel.com>
2018-05-14 22:31:48 +01:00
Yanglong Wu
956ef01f50 net/i40e: fix missing some offload capabilities
MULTI_SEGS and JUMBO_FRAME offload capability should be exposed
both VF and PF since i40e does support it.

Fixes: c3ac7c5b0b ("net/i40e: convert to new Rx offloads API")
Fixes: 7497d3e2f7 ("net/i40e: convert to new Tx offloads API")

Signed-off-by: Yanglong Wu <yanglong.wu@intel.com>
Acked-by: Qi Zhang <qi.z.zhang@intel.com>
2018-05-14 22:31:48 +01:00
Chas Williams
03f518d040 net/e1000: add minimum support for Broadcom 54616 PHY
If we find a Broadcom 54616, handle as a e1000_phy_none assuming that
the NIC reset has initialized the PHY to a sane state.

Signed-off-by: Chas Williams <chas3@att.com>
Acked-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
2018-05-14 22:31:48 +01:00
Rosen Xu
cae18d2b0f net/i40e: add workaround promiscuous disable
In scenario of Kernel Driver runs on PF and PMD runs on VF, PMD exit
doesn't disable promiscuous mode, this will cause vlan filter set by
Kernel Driver will not take effect.

This patch will fix it, add promiscuous disable at device disable.

Signed-off-by: Rosen Xu <rosen.xu@intel.com>
Acked-by: Qi Zhang <qi.z.zhang@intel.com>
2018-05-14 22:31:48 +01:00
Shweta Choudaha
c2071c19ad net/ixgbe: add API to update SBP bit
Add ixgbe API to enable SBP bit in FCTRL register
to allow receiving packets that may otherwise be
considered length errors by ixgbe and dropped

Signed-off-by: Shweta Choudaha <shweta.choudaha@att.com>
Reviewed-by: Chas Williams <chas3@att.com>
Reviewed-by: Luca Boccassi <bluca@debian.org>
Acked-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
2018-05-14 22:31:47 +01:00
Jianfeng Tan
169a9da64a net/virtio-user: fix hugepage files enumeration
After the commit 2a04139f66 ("eal: add single file segments option"),
one hugepage file could contain multiple hugepages which are further
mapped to different memory regions.

Original enumeration implementation cannot handle this situation.

This patch filters out the duplicated files; and adjust the size after
the enumeration.

Fixes: 6a84c37e39 ("net/virtio-user: add vhost-user adapter layer")

Signed-off-by: Jianfeng Tan <jianfeng.tan@intel.com>
Acked-by: Maxime Coquelin <maxime.coquelin@redhat.com>
2018-05-14 22:31:47 +01:00
Ciara Loftus
aee6c97f00 net/vhost: initialise device as inactive
rte_eth_vhost_get_vid_from_port_id returns a value of 0 if
called before the first call to the new_device callback.
A vid value >=0 suggests the device is active which is not
the case in this instance. Initialise vid to a negative
value to prevent this.

Fixes: ee584e9710 ("vhost: add driver on top of the library")
Cc: stable@dpdk.org

Signed-off-by: Ciara Loftus <ciara.loftus@intel.com>
Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com>
2018-05-14 22:31:37 +01:00
Pavan Nikhilesh
28abade0a7 net/thunderx: remove deprecated Txq flags
Signed-off-by: Pavan Nikhilesh <pbhagavatula@caviumnetworks.com>
2018-05-14 22:26:36 +01:00
Pavan Nikhilesh
2fd41a152e net/octeontx: fix missing offload flags
Fix missing DEV_RX_OFFLOAD_CHECKSUM flag in RX offloads.
Remove depricated txq_flags field.

Fixes: a92870896b ("net/octeontx: use the new offload APIs")

Signed-off-by: Pavan Nikhilesh <pbhagavatula@caviumnetworks.com>
2018-05-14 22:26:36 +01:00
Ajit Khaparde
ac0ba3e151 net/bnxt: remove unused Txq flags
We are still using the txq_flags which is no longer needed with the
new offload API. Cleaning it up.

Signed-off-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
2018-05-14 22:26:36 +01:00
Qi Zhang
1778ef67e2 net/fm10k: remove dependence on Tx queue flags
Since we move to new offload APIs, txq_flags is no long needed.
This patch remove the dependence on that.

Fixes: 30f3ce999e ("net/fm10k: convert to new Tx offloads API")

Signed-off-by: Qi Zhang <qi.z.zhang@intel.com>
Acked-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
2018-05-14 22:26:36 +01:00
Qi Zhang
2b64a8e3e0 net/e1000: remove dependence on Tx queue flags
Since we move to new offload APIs, txq_flags is no long needed.
This patch remove the dependence on that.

Fixes: e5c05e6590 ("net/e1000: convert to new Tx offloads API")

Signed-off-by: Qi Zhang <qi.z.zhang@intel.com>
Acked-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
2018-05-14 22:26:36 +01:00
Qi Zhang
2999456952 net/ixgbe: remove dependence on Tx queue flags
Since we move to new offload APIs, txq_flags is no long needed.
This patch remove the dependence on that.

Fixes: 51215925a3 ("net/ixgbe: convert to new Tx offloads API")

Signed-off-by: Qi Zhang <qi.z.zhang@intel.com>
Acked-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
2018-05-14 22:26:36 +01:00
Andrew Rybchenko
c8f24b8a9e net/sfc: rely on ethdev mapping of Tx offloads to TxQ flags
There is no necessity to fill in TxQ flags since ethdev maps
Tx offloads to TxQ flags on device info get for apps which are
not converted yet to Tx offloads API.

Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
2018-05-14 22:26:36 +01:00
Qi Zhang
aed545af1b net/i40e: fix Tx queue info get
Add missing Tx queue offload assignment in i40e_txq_info_get.

Fixes: 7497d3e2f7 ("net/i40e: convert to new Tx offloads API")

Signed-off-by: Qi Zhang <qi.z.zhang@intel.com>
2018-05-14 22:26:36 +01:00
Ferruh Yigit
04db1d0da7 lib: clear experimental version tag in linker scripts
Remove version tag from experimental block in linker version scripts
(.map files).

That label is not used by linker and information only. It is useful
for version blocks but not useful for experimental block but confusing.
Removing those labels.

Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com>
Acked-by: Neil Horman <nhorman@tuxdriver.com>
2018-05-14 03:37:28 +02:00
Hemant Agrawal
339c1025a8 net/dpaa: fix xstats implementation
Some of the applications are expecting that if n is 0, it shall
return the supported number of stats. e.g. VPP

Fixes: b21ed3e2a1 ("net/dpaa: support extended statistics")
Cc: stable@dpdk.org

Signed-off-by: Hemant Agrawal <hemant.agrawal@nxp.com>
Acked-by: Shreyansh Jain <shreyansh.jain@nxp.com>
2018-05-14 00:36:38 +02:00
Hemant Agrawal
627b677014 bus/fslmc: improve debug logging
Signed-off-by: Hemant Agrawal <hemant.agrawal@nxp.com>
Acked-by: Shreyansh Jain <shreyansh.jain@nxp.com>
2018-05-14 00:35:53 +02:00
Bruce Richardson
776d64ffb7 net/i40e: fix missing defines for non-AVX build
For non-AVX builds, the cflags used for compiling the i40e driver files
are not passed to the call to build the AVX-specific code path. This can
cause build failures.

../drivers/net/i40e/i40e_ethdev.h:888:42: error: ‘I40E_PFQF_HKEY_MAX_INDEX’ undeclared here (not in a function)

Fixes: e940646b20 ("drivers/net: build Intel NIC PMDs with meson")

Reported-by: Shreyansh Jain <shreyansh.jain@nxp.com>
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
Tested-by: Shreyansh Jain <shreyansh.jain@nxp.com>
2018-05-08 22:14:07 +02:00
Nikhil Rao
2fcf2f104f ethdev: support WRED thresholds in bytes
WRED thresholds can be specified in bytes if the TM leaf
node supports it. Also extend WRED thresholds to 32 bits from 16.

TM capability (port/level/queue) fields cman_wred_packet_mode_supported and
cman_wred_byte_mode_supported, when non-zero, indicate support for WRED
thresholds in packets and bytes respectively.

The packet_mode member of struct rte_tm_wred_params, when non-zero,
indicates that the min and max thresholds are specified in
packets and when zero, indicates that the min and max thresholds
are specified in bytes.

Signed-off-by: Nikhil Rao <nikhil.rao@intel.com>
2018-05-04 16:23:19 +02:00
Declan Doherty
a34506b3a5 net/ixgbe: check probing error
Add NULL parameter check for rte_eth_dev_allocated() API call to
eth_ixgbe_pci_probe().

Coverity Issue: 277216
Fixes: cf80ba6e20 ("net/ixgbe: add support for representor ports")

Signed-off-by: Declan Doherty <declan.doherty@intel.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
2018-05-02 19:28:48 +02:00
Declan Doherty
07d27b971b net/ixgbe: fix probe with no devargs
Initialise rte_ethdev_args parameters to zero to handle
the case where no devargs are passed to the IXGBE PF on
device probe, so that there is no invalid attempts to create
representor ports.

Coverity Issue: 277231
Fixes: cf80ba6e20 ("net/ixgbe: add support for representor ports")

Signed-off-by: Declan Doherty <declan.doherty@intel.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
2018-05-02 19:28:48 +02:00
Declan Doherty
040ddce28a net/ixgbe: revert default PF device name
Changes introduced by cf80ba6e20 modified the default name generated
for the IXGBE PF PMD, this patch reverts the default name to the
original PCI BDBF.

Fixes: cf80ba6e20 ("net/ixgbe: add support for representor ports")

Signed-off-by: Declan Doherty <declan.doherty@intel.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
2018-05-02 19:28:48 +02:00
Ravi Kumar
95b08d94ee net/axgbe: fix jumbo setting overwritten
Stored register value to enable jumbo frame was always
overwritten. Assigning value based on rx_buf_size.

Coverity issue: 277239
Fixes: 7c4158a5b5 ("net/axgbe: add DMA programming and start/stop")

Signed-off-by: Ravi Kumar <ravi1.kumar@amd.com>
2018-05-02 19:28:48 +02:00
Qi Zhang
7d1daae8c7 net/i40e: remove dependence on Tx queue flags
Since we move to new offload APIs, txq_flags is no long needed.
This patch remove the dependence on that.

Fixes: 7497d3e2f7 ("net/i40e: convert to new Tx offloads API")

Signed-off-by: Qi Zhang <qi.z.zhang@intel.com>
2018-05-02 19:28:48 +02:00
Qi Zhang
4ab54673af net/i40e: fix queue offload initialization
Add missing queue offload initialization.

Fixes: 7497d3e2f7 ("net/i40e: convert to new Tx offloads API")
Fixes: c3ac7c5b0b ("net/i40e: convert to new Rx offloads API")

Signed-off-by: Qi Zhang <qi.z.zhang@intel.com>
2018-05-02 19:28:48 +02:00
Louis Luo
95e4a96ccb net/vmxnet3: convert to new Rx offload API
Ethdev RX offloads API has changed since: commit ce17eddefc
("ethdev: introduce Rx queue offloads API")

This patch adopts the new RX Offload API in vmxnet3 driver.

Signed-off-by: Louis Luo <llouis@vmware.com>
Acked-by: Yong Wang <yongwang@vmware.com>
2018-05-02 19:28:48 +02:00
Hemant Agrawal
762b275f20 net/dpaa2: add missing device info fields
Add the hashed RSS support info and other fields in device info.

Signed-off-by: Hemant Agrawal <hemant.agrawal@nxp.com>
2018-05-02 19:28:48 +02:00
Hemant Agrawal
1475ad99a0 net/dpaa: fix RSS hash support
Fixes: 4fa5e0bbc5 ("net/dpaa: support hashed RSS")
Cc: stable@dpdk.org

Signed-off-by: Hemant Agrawal <hemant.agrawal@nxp.com>
2018-05-02 19:28:48 +02:00
Bruce Richardson
c66724bdeb net/i40e: fix Tx function selection with new offloads
The Tx function selection code in the driver only used the older txq
flags values to check whether the scalar or vector functions should be
used. This caused performance regressions with testpmd io-fwd as the
scalar path rather than the vector one was being used in the default
case. Fix this by changing the code to take account of new offloads and
deleting the defines used for the old ones.

Fixes: 7497d3e2f7 ("net/i40e: convert to new Tx offloads API")

Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
2018-05-02 19:28:48 +02:00
Declan Doherty
8c56e4089b net/i40e: revert default PF device name
Changes introduced by e0cb96204b modified the default name generated
for the i40e PF PMD, this patch reverts the default name to the
original PCI BDF.

Fixes: e0cb96204b ("net/i40e: add support for representor ports")

Signed-off-by: Declan Doherty <declan.doherty@intel.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
2018-05-02 19:28:48 +02:00
Adrien Mazarguil
828a4ce3c9 net/mlx4: fix inner RSS support for broken kernels
Linux 4.15 and 4.16 may report inner RSS as a supported capability of the
device, however it can't be used due to missing code in the kernel.

This triggers an error when creating the default hash QP and prevents this
PMD from starting up without a prior call to rte_flow_isolate().

Fixes: 55e8991e31 ("net/mlx4: restore inner VXLAN RSS support")
Cc: stable@dpdk.org

Signed-off-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
2018-05-02 19:28:48 +02:00
Adrien Mazarguil
1d173da83e net/mlx4: fix default RSS hash fields
Using special types value -1 with mlx4_conv_rss_types() is supposed to
return a supported set of Verbs RSS hash fields, that is, priv->hw_rss_sup
unmodified.

Due to the way this function is written and because it is also used to
initially populate priv->hw_rss_sup however, this special value works
properly only once and fails with ENOTSUP errors afterward.

This problem can be seen when re-creating default flows (e.g. by entering
and leaving isolated mode).

Fixes: 024e87bef4 ("net/mlx4: restore UDP RSS by probing capabilities")
Cc: stable@dpdk.org

Signed-off-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
2018-05-02 19:28:48 +02:00
Adrien Mazarguil
84a684862f net/mlx4: fix Rx resource leak in case of error
When creation of a flow rule fails during dev_start(), the usage count of
the common RSS context is not decremented, which triggers an assertion
failure in debug mode during dev_close().

This is addressed by tracking the initialization status of the common RSS
context in order to add missing cleanup code.

A similar issue exists in mlx4_rxq_attach(), where usage count is
incremented on a Rx queue but not released in case of error. This may lead
to the above issue since RSS contexts created by flow rules attach
themselves to Rx queues, incrementing their usage count.

Fixes: 5697a41421 ("net/mlx4: relax Rx queue configuration order")
Cc: stable@dpdk.org

Signed-off-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
2018-05-02 19:28:48 +02:00
Adrien Mazarguil
6f2f4948b2 net/mlx5: fix flow director rule deletion crash
Flow director rules matching traffic properties above layer 2 do not
target a fixed hash Rx queue (HASH_RXQ_ETH), it actually depends on the
highest protocol layer specified by each flow rule.

mlx5_fdir_filter_delete() makes this wrong assumption and causes a crash
when attempting to destroy flow rules with L3/L4 specifications.

Fixes: 4c3e9bcdd5 ("net/mlx5: support flow director")
Cc: stable@dpdk.org

Signed-off-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
Acked-by: Nelio Laranjeiro <nelio.laranjeiro@6wind.com>
2018-05-02 19:28:48 +02:00
Yanglong Wu
a6d1117e9e net/i40e: fix checking offload
Missing "return -ENOTSUP" will always lead to illegal offload
passing through offload checking.

Fixes: 7497d3e2f7 ("net/i40e: convert to new Tx offloads API")

Signed-off-by: Yanglong Wu <yanglong.wu@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
2018-04-27 18:01:00 +01:00
Yanglong Wu
1c251e7bf0 net/i40e: fix missing jumbo frame offload capability
JUMBO_FRAME offload capability should be exposed since i40e
does support it

Fixes: c3ac7c5b0b ("net/i40e: convert to new Rx offloads API")

Signed-off-by: Yanglong Wu <yanglong.wu@intel.com>
Acked-by: Qi Zhang <qi.z.zhang@intel.com>
2018-04-27 18:01:00 +01:00
Stephen Hemminger
d7f4562ab1 net/bonding: convert to dynamic logging
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
2018-04-27 18:00:59 +01:00
Stephen Hemminger
81f1491a9a net/vhost: implement dynamic logging
Use dynamic log type (instead of PMD) in vhost.

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
2018-04-27 18:00:59 +01:00
Stephen Hemminger
20dae1aac6 net/pcap: support dynamic logging
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
2018-04-27 18:00:59 +01:00
Stephen Hemminger
4420fd0781 net/kni: support dynamic logging
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
2018-04-27 18:00:59 +01:00
Stephen Hemminger
ebeb72ecc4 net/failsafe: convert to dynamic logging
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
2018-04-27 18:00:59 +01:00
Stephen Hemminger
aec982dd40 net/softnic: convert to dynamic logging
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
2018-04-27 18:00:59 +01:00
Stephen Hemminger
5ff5bb7c5f net/ring: convert to dynamic logging
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
2018-04-27 18:00:59 +01:00
Stephen Hemminger
eb16afb9b5 net/null: convert to dynamic logging
Convert null device to use dynamic logging.

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
2018-04-27 18:00:59 +01:00
Stephen Hemminger
8c54a3c693 net/af_packet: convert to dynamic log level
Convert this driver to use dynamic log level support.

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
2018-04-27 18:00:59 +01:00
Stephen Hemminger
1b3b7caeb1 net/tap: convert to dynamic logging
Use new logging macro to convert all calls to RTE_LOG() into
new dynamic log type.

Also fix whitespace.

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
2018-04-27 18:00:59 +01:00
Roman Zhukov
5f78af5239 net/sfc: support MARK and FLAG actions in flow API
Signed-off-by: Roman Zhukov <roman.zhukov@oktetlabs.ru>
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
2018-04-27 18:00:59 +01:00
Roman Zhukov
cc70e8f207 net/sfc: make processing of flow rule actions more uniform
Prepare function that parse flow rule actions to support not
fate-deciding actions.

Signed-off-by: Roman Zhukov <roman.zhukov@oktetlabs.ru>
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
2018-04-27 18:00:59 +01:00
Roman Zhukov
0f22fe3a5c net/sfc/base: get max supported value for action MARK
The mark value for MATCH_ACTION_MARK has a maximum value.
Requesting a value larger than the maximum will cause the
filter insertion to fail with EINVAL. This patch allows the
driver to check the value at the filter validation.

Signed-off-by: Roman Zhukov <roman.zhukov@oktetlabs.ru>
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
2018-04-27 18:00:59 +01:00