dpdk.git
6 years agonet/sfc: support loopback mode configuration
Andrew Rybchenko [Mon, 9 Apr 2018 11:58:58 +0000 (12:58 +0100)]
net/sfc: support loopback mode configuration

All loopback modes are listed in efx_loopback_type_t.
Available loopback modes are listed per link speed in
the enc_loopback_types member of the efx_nic_cfg_t.

Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
Reviewed-by: Andy Moreton <amoreton@solarflare.com>
Reviewed-by: Ivan Malov <ivan.malov@oktetlabs.ru>
6 years agonet/sfc/base: fix comparison always true warning
Andrew Rybchenko [Mon, 9 Apr 2018 11:58:57 +0000 (12:58 +0100)]
net/sfc/base: fix comparison always true warning

Loopback type used as bit index has efx_loopback_type_t type
which is enum. clang complains that it is always true when it
is compared with qword (64 bit) bits number boundary.

Fixes: 9ee64bd404fc ("net/sfc/base: import loopback control")
Cc: stable@dpdk.org
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
6 years agonet/bnx2x: convert to new Rx offloads API
Harish Patil [Mon, 9 Apr 2018 05:37:41 +0000 (22:37 -0700)]
net/bnx2x: convert to new Rx offloads API

Ethdev RX offloads API has changed since:
commit ce17eddefc20 ("ethdev: introduce Rx queue offloads API")

This patch makes use of DEV_RX_OFFLOAD_JUMBO_FRAME offload flag
to advertise jumbo frame support.

Signed-off-by: Harish Patil <harish.patil@cavium.com>
6 years agonet/qede: update PMD version to 2.8.0.1
Rasesh Mody [Mon, 9 Apr 2018 04:48:10 +0000 (21:48 -0700)]
net/qede: update PMD version to 2.8.0.1

Signed-off-by: Rasesh Mody <rasesh.mody@cavium.com>
6 years agonet/qede/base: support packet pacing
Rasesh Mody [Mon, 9 Apr 2018 04:48:09 +0000 (21:48 -0700)]
net/qede/base: support packet pacing

Add packet pacing support for PFs.
ecore client can request for enabling packet pacing at init time,
if requested then ecore is going to skip MCoS and SRIOV configurations.

Signed-off-by: Rasesh Mody <rasesh.mody@cavium.com>
6 years agonet/qede/base: fix to support OVLAN mode
Rasesh Mody [Mon, 9 Apr 2018 04:48:08 +0000 (21:48 -0700)]
net/qede/base: fix to support OVLAN mode

This fix allows driver to program NIC configuration to support OVLAN
mode in multi-function scenario

Signed-off-by: Rasesh Mody <rasesh.mody@cavium.com>
6 years agonet/qede/base: add APIs for xcvr
Rasesh Mody [Mon, 9 Apr 2018 04:48:07 +0000 (21:48 -0700)]
net/qede/base: add APIs for xcvr

Add API to query transceiver info and to retrieve link speed.

Signed-off-by: Rasesh Mody <rasesh.mody@cavium.com>
6 years agonet/qede/base: add stats counter for link state
Rasesh Mody [Mon, 9 Apr 2018 04:48:06 +0000 (21:48 -0700)]
net/qede/base: add stats counter for link state

Add link_change_count counter to track number of link state transitions

Signed-off-by: Rasesh Mody <rasesh.mody@cavium.com>
6 years agonet/qede/base: refine error handling
Rasesh Mody [Mon, 9 Apr 2018 04:48:05 +0000 (21:48 -0700)]
net/qede/base: refine error handling

Adjust the verbosity of the log messages and add preventive checks for
errors.

Signed-off-by: Rasesh Mody <rasesh.mody@cavium.com>
6 years agonet/qede/base: support MFW for driver load timeout
Rasesh Mody [Mon, 9 Apr 2018 04:48:04 +0000 (21:48 -0700)]
net/qede/base: support MFW for driver load timeout

Add SPQ timeout base driver parameter support management FW timeout values
other than default and none. Have fallback mechanism for old MFWs.
Reduce the default timeout to 1 sec.

Signed-off-by: Rasesh Mody <rasesh.mody@cavium.com>
6 years agonet/qede/base: allow changing VF MAC address
Rasesh Mody [Mon, 9 Apr 2018 04:48:03 +0000 (21:48 -0700)]
net/qede/base: allow changing VF MAC address

This patch allows VF to change its own MAC address regardless of MAC set
by PF

Signed-off-by: Rasesh Mody <rasesh.mody@cavium.com>
6 years agonet/qede/base: add new chain API
Rasesh Mody [Mon, 9 Apr 2018 04:48:02 +0000 (21:48 -0700)]
net/qede/base: add new chain API

Add new API ecore_chain_set_cons() and fix page index setting in
ecore_chain_set_prod(). The new API is for future use.

Signed-off-by: Rasesh Mody <rasesh.mody@cavium.com>
6 years agonet/qede/base: semantic changes
Rasesh Mody [Mon, 9 Apr 2018 04:48:01 +0000 (21:48 -0700)]
net/qede/base: semantic changes

The changes included in this patch are for
 - formatting
 - comment rework/additions
 - relocate FW info, version related code
 - convert:
    __le16 to u16
    __le32 to u32 etc.

Signed-off-by: Rasesh Mody <rasesh.mody@cavium.com>
6 years agonet/qede/base: upgrade FW to 8.33.12.0
Rasesh Mody [Mon, 9 Apr 2018 04:48:00 +0000 (21:48 -0700)]
net/qede/base: upgrade FW to 8.33.12.0

This patch adds changes to support new firmware 8.33.12.0. The changes
consist of FW bug fixes and enhancements.

Signed-off-by: Rasesh Mody <rasesh.mody@cavium.com>
6 years agonet/qede/base: add DMAE sanity check
Rasesh Mody [Mon, 9 Apr 2018 04:47:59 +0000 (21:47 -0700)]
net/qede/base: add DMAE sanity check

Add DMA engine sanity check during the engine initialization and before
PF initialization

Signed-off-by: Rasesh Mody <rasesh.mody@cavium.com>
6 years agonet/qede/base: protect DMAE transactions
Rasesh Mody [Mon, 9 Apr 2018 04:47:58 +0000 (21:47 -0700)]
net/qede/base: protect DMAE transactions

Protect DMAE transactions with a spinlock instead of a mutex

Signed-off-by: Rasesh Mody <rasesh.mody@cavium.com>
6 years agonet/qede/base: use path ID for HW init
Rasesh Mody [Mon, 9 Apr 2018 04:47:57 +0000 (21:47 -0700)]
net/qede/base: use path ID for HW init

Use the path ID as the phase ID when running the engine phase of the
HW init

Signed-off-by: Rasesh Mody <rasesh.mody@cavium.com>
6 years agonet/bnxt: switch to the new offload API
Ajit Khaparde [Sat, 7 Apr 2018 17:40:55 +0000 (10:40 -0700)]
net/bnxt: switch to the new offload API

Update bnxt PMD to new ethdev offloads API.

Signed-off-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
6 years agonet/bnxt: fix Rx drop setting
Ajit Khaparde [Sat, 7 Apr 2018 17:40:54 +0000 (10:40 -0700)]
net/bnxt: fix Rx drop setting

If Rx descriptors are not available, pkts are dropped by default.
Fix rx_drop_en setting in bnxt_dev_info_get_op to reflect it.

Fixes: 0a6d2a720078 ("net/bnxt: get device infos")
Cc: stable@dpdk.org
Signed-off-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
6 years agodoc: add timestamp offload to mlx5 features
Yongseok Koh [Mon, 2 Apr 2018 17:01:22 +0000 (10:01 -0700)]
doc: add timestamp offload to mlx5 features

Fixes: 78c7406b7b5a ("net/mlx5: add Rx HW timestamp")
Cc: stable@dpdk.org
Signed-off-by: Yongseok Koh <yskoh@mellanox.com>
Acked-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
6 years agonet/mlx5: add parameter for Netlink support in VF
Nélio Laranjeiro [Thu, 5 Apr 2018 15:07:21 +0000 (17:07 +0200)]
net/mlx5: add parameter for Netlink support in VF

All Netlink request the PMD will do can also be done by a iproute2 command
line interface, enabling VF behavior configuration without having to modify
the application nor reaching PMD limits (e.g. MAC address number limit).

Signed-off-by: Nelio Laranjeiro <nelio.laranjeiro@6wind.com>
Acked-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
6 years agonet/mlx5: use Netlink to enable promisc/allmulti mode
Nélio Laranjeiro [Thu, 5 Apr 2018 15:07:20 +0000 (17:07 +0200)]
net/mlx5: use Netlink to enable promisc/allmulti mode

VF devices are not able to receive promisc or allmulti traffic unless it
fully requests it though Netlink.  This will cause the request to be
processed by the PF which will handle the request and enable it.

This requires the VF to be trusted by the PF.

Signed-off-by: Nelio Laranjeiro <nelio.laranjeiro@6wind.com>
Acked-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
6 years agonet/mlx5: use Netlink to add/remove MAC addresses
Nélio Laranjeiro [Thu, 5 Apr 2018 15:07:19 +0000 (17:07 +0200)]
net/mlx5: use Netlink to add/remove MAC addresses

VF devices are not able to receive traffic unless it fully requests it
though Netlink.  This will cause the request to be processed by the PF
which will add/remove the MAC address to the VF table if the VF is trusted.

Signed-off-by: Nelio Laranjeiro <nelio.laranjeiro@6wind.com>
Acked-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
6 years agonet/ixgbe: update link status on start
Chas Williams [Tue, 13 Feb 2018 22:56:18 +0000 (17:56 -0500)]
net/ixgbe: update link status on start

dev->data->eth_link isn't updated until the first interrupt. If a
link is carrier down, then this interrupt may never happen. Before we
finished starting the PMD, call ixgbe_dev_link_update() to ensure we
have a valid status.

Signed-off-by: Chas Williams <chas3@att.com>
Acked-by: Qi Zhang <qi.z.zhang@intel.com>
6 years agonet/ixgbe: fix busy wait during checking link status
Chas Williams [Thu, 1 Feb 2018 22:39:07 +0000 (17:39 -0500)]
net/ixgbe: fix busy wait during checking link status

If we haven't set wait_to_complete, there is no need to busy wait
until we have a link status.  Applications, like bonding, use the
wait_to_complete flag to indicate that they will be doing their own
busy wait and will likely be polling again shortly.

Fixes: dc66e5fd01b9 ("net/ixgbe: improve link state check on VF")
Cc: stable@dpdk.org
Signed-off-by: Chas Williams <chas3@att.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
6 years agonet/i40e: fix flow RSS queue index check
Wei Zhao [Wed, 4 Apr 2018 08:06:03 +0000 (16:06 +0800)]
net/i40e: fix flow RSS queue index check

There need a queue index check for RSS queue region
in order to aviod error from configuration.

Fixes: ecad87d22383 ("net/i40e: move RSS to flow API")
Cc: stable@dpdk.org
Signed-off-by: Wei Zhao <wei.zhao1@intel.com>
Tested-by: Yuan Peng <yuan.peng@intel.com>
Acked-by: Qi Zhang <qi.z.zhang@intel.com>
6 years agonet/i40e: fix flow RSS queue region
Wei Zhao [Tue, 3 Apr 2018 06:09:08 +0000 (14:09 +0800)]
net/i40e: fix flow RSS queue region

Queue region comparison error in configuration parameters.

Fixes: ecad87d22383 ("net/i40e: move RSS to flow API")
Cc: stable@dpdk.org
Signed-off-by: Wei Zhao <wei.zhao1@intel.com>
Tested-by: Yuan Peng <yuan.peng@intel.com>
Acked-by: Qi Zhang <qi.z.zhang@intel.com>
6 years agonet/e1000: add MAC address set to em
Chas Williams [Mon, 19 Feb 2018 00:39:55 +0000 (19:39 -0500)]
net/e1000: add MAC address set to em

Based on the equivalent code in the igb driver.

Signed-off-by: Chas Williams <chas3@att.com>
Reviewed-by: David Marchand <david.marchand@6wind.com>
Acked-by: Wei Zhao <wei.zhao1@intel.com>
6 years agodoc: sort qede feature list
Ferruh Yigit [Thu, 22 Mar 2018 18:17:46 +0000 (18:17 +0000)]
doc: sort qede feature list

Sort list to be same order as default.ini. No value changed.

Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com>
6 years agonet/sfc: support choice of FW subvariant without Tx checksum
Andrew Rybchenko [Wed, 4 Apr 2018 14:23:57 +0000 (15:23 +0100)]
net/sfc: support choice of FW subvariant without Tx checksum

If running FW variant supports subvariant without checksumming
on transmit and all transmit queues do not use checksumming,
it may be disabled.

Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
6 years agonet/sfc/base: support FW subvariant choice
Andrew Rybchenko [Wed, 4 Apr 2018 14:23:56 +0000 (15:23 +0100)]
net/sfc/base: support FW subvariant choice

If DPDK application or OS does not need checksumming on transmit,
it may be disabled in firmware to achieve higher packet rates.
Choice must be done before VIS allocation and is allowed if
no other non-preboot and firmware subvariant-unaware drivers are
attached.

Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
Reviewed-by: Andy Moreton <amoreton@solarflare.com>
Reviewed-by: Andrew Lee <alee@solarflare.com>
6 years agonet/sfc/base: report no Tx checksum FW subvariant support
Andrew Rybchenko [Wed, 4 Apr 2018 14:23:55 +0000 (15:23 +0100)]
net/sfc/base: report no Tx checksum FW subvariant support

Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
Reviewed-by: Andy Moreton <amoreton@solarflare.com>
Reviewed-by: Andrew Lee <alee@solarflare.com>
6 years agonet/sfc/base: add firmware subvariant aware driver option
Andrew Rybchenko [Wed, 4 Apr 2018 14:23:54 +0000 (15:23 +0100)]
net/sfc/base: add firmware subvariant aware driver option

FW subvariants allow to tweak NIC global features. For example,
if no drivers require checksumming on transmit, it may be disabled
in FW to increase packet rate.

Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
Reviewed-by: Andy Moreton <amoreton@solarflare.com>
Reviewed-by: Andrew Lee <alee@solarflare.com>
6 years agonet/sfc/base: update MCDI headers
Andrew Rybchenko [Wed, 4 Apr 2018 14:23:53 +0000 (15:23 +0100)]
net/sfc/base: update MCDI headers

Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
6 years agonet/tap: add tun log and documentation
Vipin Varghese [Mon, 2 Apr 2018 21:37:48 +0000 (03:07 +0530)]
net/tap: add tun log and documentation

The changes add TUN|TAP specific logs and documentation support.

Signed-off-by: Vipin Varghese <vipin.varghese@intel.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
Acked-by: Pascal Mazon <pascal.mazon@6wind.com>
6 years agonet/tap: support tun
Vipin Varghese [Mon, 2 Apr 2018 21:37:47 +0000 (03:07 +0530)]
net/tap: support tun

The change adds functional TUN PMD logic to the existing TAP PMD.
TUN PMD can be initialized with 'net_tunX' where 'X' represents unique id.
PMD supports argument interface, while MAC address and remote are not
supported.

Signed-off-by: Vipin Varghese <vipin.varghese@intel.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
Acked-by: Pascal Mazon <pascal.mazon@6wind.com>
6 years agodoc: update enic guide and features
Hyong Youb Kim [Wed, 4 Apr 2018 23:54:55 +0000 (16:54 -0700)]
doc: update enic guide and features

Documentation updates including for 1400 series VIC adapters.

Remove VLAN filter from the features file as the driver does not
support that API. Hardware does support VLAN filtering, but it is not
controlled through the driver.

Signed-off-by: Hyong Youb Kim <hyonkim@cisco.com>
Reviewed-by: John Daley <johndale@cisco.com>
6 years agonet/enic: support drop flow action
Hyong Youb Kim [Wed, 4 Apr 2018 23:54:54 +0000 (16:54 -0700)]
net/enic: support drop flow action

1330 and 1400 series adapters support the drop action. Check for its
availability and set the necessary flag when creating NIC filters.

Signed-off-by: Hyong Youb Kim <hyonkim@cisco.com>
Reviewed-by: John Daley <johndale@cisco.com>
6 years agonet/enic: fix crash on MTU update with non-setup queues
John Daley [Wed, 4 Apr 2018 23:54:53 +0000 (16:54 -0700)]
net/enic: fix crash on MTU update with non-setup queues

The enic code called from rte_eth_dev_set_mtu() was assuming that the
Rx queues are already set up via a call to rte_eth_tx_queue_setup().
OVS calls rte_eth_dev_set_mtu() before rte_eth_rx_queue_setup() and
a null pointer was dereferenced.

Fixes: c3e09182bcd6 ("net/enic: support scatter Rx in MTU update")
Cc: stable@dpdk.org
Signed-off-by: John Daley <johndale@cisco.com>
Reviewed-by: Hyong Youb Kim <hyonkim@cisco.com>
6 years agonet/enic: support UDP RSS on 1400 series adapters
John Daley [Wed, 4 Apr 2018 23:54:52 +0000 (16:54 -0700)]
net/enic: support UDP RSS on 1400 series adapters

Recent models support IPv4/IPv6 UDP RSS. There is no control bit to
enable UDP RSS alone. Instead, the NIC enables/disables TCP and UDP
RSS together.

Signed-off-by: John Daley <johndale@cisco.com>
Reviewed-by: Hyong Youb Kim <hyonkim@cisco.com>
6 years agonet/enic: do not flush descriptor cache when opening vNIC
Hyong Youb Kim [Wed, 4 Apr 2018 23:54:50 +0000 (16:54 -0700)]
net/enic: do not flush descriptor cache when opening vNIC

The firmware on new hardware models flushes the global descriptor
cache by default. Use CMD_OPENF_IG_DESCCACHE to avoid cache
flushing. This flag has no effect on older models.

Suggested-by: Govindarajulu Varadarajan <gvaradar@cisco.com>
Signed-off-by: Hyong Youb Kim <hyonkim@cisco.com>
Reviewed-by: John Daley <johndale@cisco.com>
6 years agonet/axgbe: support meson build
Ravi Kumar [Fri, 6 Apr 2018 12:36:51 +0000 (08:36 -0400)]
net/axgbe: support meson build

Signed-off-by: Ravi Kumar <ravi1.kumar@amd.com>
6 years agonet/axgbe: add workaround for ethernet training
Ravi Kumar [Fri, 6 Apr 2018 12:36:50 +0000 (08:36 -0400)]
net/axgbe: add workaround for ethernet training

Signed-off-by: Ravi Kumar <ravi1.kumar@amd.com>
6 years agonet/axgbe: support 32-bit build mode
Ravi Kumar [Fri, 6 Apr 2018 12:36:49 +0000 (08:36 -0400)]
net/axgbe: support 32-bit build mode

Signed-off-by: Ravi Kumar <ravi1.kumar@amd.com>
6 years agonet/axgbe: support generic Rx/Tx stats
Ravi Kumar [Fri, 6 Apr 2018 12:36:48 +0000 (08:36 -0400)]
net/axgbe: support generic Rx/Tx stats

This patch adds support for port statistics api defined
for ethernet PMDs.

Signed-off-by: Ravi Kumar <ravi1.kumar@amd.com>
6 years agonet/axgbe: support promiscuous mode
Ravi Kumar [Fri, 6 Apr 2018 12:36:47 +0000 (08:36 -0400)]
net/axgbe: support promiscuous mode

This patch enables promiscuous and multicast support for AXGBE PMD.

Signed-off-by: Ravi Kumar <ravi1.kumar@amd.com>
6 years agonet/axgbe: add configure flow control while link adjustment
Ravi Kumar [Fri, 6 Apr 2018 12:36:46 +0000 (08:36 -0400)]
net/axgbe: add configure flow control while link adjustment

Signed-off-by: Ravi Kumar <ravi1.kumar@amd.com>
6 years agonet/axgbe: add link status update
Ravi Kumar [Fri, 6 Apr 2018 12:36:45 +0000 (08:36 -0400)]
net/axgbe: add link status update

Added support to update device link status atomically.

Signed-off-by: Ravi Kumar <ravi1.kumar@amd.com>
6 years agodoc: add guide for AMD axgbe Ethernet PMD
Ravi Kumar [Fri, 6 Apr 2018 12:36:44 +0000 (08:36 -0400)]
doc: add guide for AMD axgbe Ethernet PMD

Signed-off-by: Ravi Kumar <ravi1.kumar@amd.com>
6 years agonet/axgbe: add Rx/Tx data path
Ravi Kumar [Fri, 6 Apr 2018 12:36:43 +0000 (08:36 -0400)]
net/axgbe: add Rx/Tx data path

Supported scalar implementation for RX data path.
Supported scalar and vector implementation for TX data path.

Signed-off-by: Ravi Kumar <ravi1.kumar@amd.com>
6 years agonet/axgbe: add DMA programming and start/stop
Ravi Kumar [Fri, 6 Apr 2018 12:36:42 +0000 (08:36 -0400)]
net/axgbe: add DMA programming and start/stop

This patch adds support to program DMA and DPDK device start
and stop apis.

Signed-off-by: Ravi Kumar <ravi1.kumar@amd.com>
6 years agonet/axgbe: add Rx/Tx setup
Ravi Kumar [Fri, 6 Apr 2018 12:36:41 +0000 (08:36 -0400)]
net/axgbe: add Rx/Tx setup

Add support for data path setup apis defined for PMDs.

Signed-off-by: Ravi Kumar <ravi1.kumar@amd.com>
6 years agonet/axgbe: add interrupt handler for autonegotiation
Ravi Kumar [Fri, 6 Apr 2018 12:36:40 +0000 (08:36 -0400)]
net/axgbe: add interrupt handler for autonegotiation

Signed-off-by: Ravi Kumar <ravi1.kumar@amd.com>
6 years agonet/axgbe: add phy programming APIs
Ravi Kumar [Fri, 6 Apr 2018 12:36:39 +0000 (08:36 -0400)]
net/axgbe: add phy programming APIs

Signed-off-by: Ravi Kumar <ravi1.kumar@amd.com>
6 years agonet/axgbe: add phy init and related APIs
Ravi Kumar [Fri, 6 Apr 2018 12:36:38 +0000 (08:36 -0400)]
net/axgbe: add phy init and related APIs

Added device phy initialization, read/write and other
maintenance apis to be used within PMD.

Signed-off-by: Ravi Kumar <ravi1.kumar@amd.com>
6 years agonet/axgbe: add structs for MAC init and reset
Ravi Kumar [Fri, 6 Apr 2018 12:36:37 +0000 (08:36 -0400)]
net/axgbe: add structs for MAC init and reset

Signed-off-by: Ravi Kumar <ravi1.kumar@amd.com>
6 years agonet/axgbe: add phy register map and helper macros
Ravi Kumar [Fri, 6 Apr 2018 12:36:36 +0000 (08:36 -0400)]
net/axgbe: add phy register map and helper macros

Added phy related register definitions.

Signed-off-by: Ravi Kumar <ravi1.kumar@amd.com>
6 years agonet/axgbe: add register map and related macros
Ravi Kumar [Fri, 6 Apr 2018 12:36:35 +0000 (08:36 -0400)]
net/axgbe: add register map and related macros

Added DMA and MAC related register definitions.

Signed-off-by: Ravi Kumar <ravi1.kumar@amd.com>
6 years agonet/axgbe: add minimal init and uninit support
Ravi Kumar [Fri, 6 Apr 2018 12:36:34 +0000 (08:36 -0400)]
net/axgbe: add minimal init and uninit support

Add ethernet poll mode driver for AMD 10G devices embedded in
AMD EPYC™ EMBEDDED 3000 family processors.

Signed-off-by: Ravi Kumar <ravi1.kumar@amd.com>
6 years agonet/tap: fix memcpy with incorrect size
Pavan Nikhilesh [Fri, 6 Apr 2018 11:30:31 +0000 (17:00 +0530)]
net/tap: fix memcpy with incorrect size

Fix incorrect sizeof operation being used for getting mac addr size.

Found while compiling with arm64 clang.
drivers/net/tap/rte_eth_tap.c:1410:40: error: argument to 'sizeof' in
    'memcpy' call is the same pointer type 'struct ether_addr *' as the
    destination; expected 'struct ether_addr' or an explicit length
    [-Werror,-Wsizeof-pointer-memaccess]
       rte_memcpy(&pmd->eth_addr, mac_addr, sizeof(mac_addr));
                  ~~~~~~~~~~~~~~            ^~~~~~~~~~~~~~~~

Fixes: bcab6c1d27fa ("net/tap: allow user MAC to be passed as args")

Signed-off-by: Pavan Nikhilesh <pbhagavatula@caviumnetworks.com>
Acked-by: Zhiyong Yang <zhiyong.yang@intel.com>
6 years agonet/nfp: support new HW offloads API
Alejandro Lucero [Thu, 15 Mar 2018 14:30:37 +0000 (14:30 +0000)]
net/nfp: support new HW offloads API

In next 18.05 the old hw offload API will be removed. This patch adds
support for just the new hw offload API.

Signed-off-by: Alejandro Lucero <alejandro.lucero@netronome.com>
6 years agonet/nfp: remove files
Alejandro Lucero [Thu, 5 Apr 2018 14:42:47 +0000 (15:42 +0100)]
net/nfp: remove files

New CPP interface makes NSPU interface obsolete. These files are
not needed anymore.

Signed-off-by: Alejandro Lucero <alejandro.lucero@netronome.com>
6 years agodoc: update NFP guide
Alejandro Lucero [Thu, 5 Apr 2018 14:42:46 +0000 (15:42 +0100)]
doc: update NFP guide

New CPP interface changes the way firmware upload is managed by
the PMD. It also supports different firmware file names for
having specific firmware applications per card.

Signed-off-by: Alejandro Lucero <alejandro.lucero@netronome.com>
6 years agonet/nfp: use new CPP interface
Alejandro Lucero [Thu, 5 Apr 2018 14:42:45 +0000 (15:42 +0100)]
net/nfp: use new CPP interface

PF PMD support was based on NSPU interface. This patch changes the
PMD for using the new CPP user space interface which gives more
flexibility for adding new functionalities.

This change just affects initialization with the datapath being the
same than before.

Signed-off-by: Alejandro Lucero <alejandro.lucero@netronome.com>
6 years agonet/nfp: support CPP
Alejandro Lucero [Thu, 5 Apr 2018 14:42:44 +0000 (15:42 +0100)]
net/nfp: support CPP

CPP refers to the internal NFP Command Push Pull bus. This patch allows
to create CPP commands from user space allowing to access any single
part of the chip.

This CPP interface is the base for having other functionalities like
mutexes when accessing specific chip components, chip resources management,
firmware upload or using the NSP, an embedded arm processor which can
perform tasks on demand.

NSP was the previous only way for doing things in the chip by the PMD,
where a NSPU interface was used for commands like firmware upload or
port link configuration. CPP interface supersedes NSPU, but it is still
possible to use NSP through CPP.

CPP interface adds a great flexibility for doing things like extended
stats or firmware debugging.

Signed-off-by: Alejandro Lucero <alejandro.lucero@netronome.com>
6 years agonet/szedata2: implement dynamic logging
Matej Vido [Wed, 4 Apr 2018 13:46:35 +0000 (15:46 +0200)]
net/szedata2: implement dynamic logging

Signed-off-by: Matej Vido <vido@cesnet.cz>
6 years agonet/szedata2: convert license headers to SPDX tags
Matej Vido [Wed, 4 Apr 2018 13:45:47 +0000 (15:45 +0200)]
net/szedata2: convert license headers to SPDX tags

Signed-off-by: Matej Vido <vido@cesnet.cz>
6 years agonet/szedata2: fix format string for PCI address
Matej Vido [Wed, 4 Apr 2018 13:42:21 +0000 (15:42 +0200)]
net/szedata2: fix format string for PCI address

For fscanf() function SCN macros should be used but PRI macros were
wrongly used.
Also use correct sizes of variables for read values.

Fixes: 83556fd2c0fc ("szedata2: change to physical device type")
Cc: stable@dpdk.org
Signed-off-by: Matej Vido <vido@cesnet.cz>
6 years agonet/szedata2: add stat of mbuf allocation failures
Matej Vido [Wed, 4 Apr 2018 13:42:20 +0000 (15:42 +0200)]
net/szedata2: add stat of mbuf allocation failures

Signed-off-by: Matej Vido <vido@cesnet.cz>
6 years agonet/szedata2: use dynamically allocated queues
Matej Vido [Wed, 4 Apr 2018 13:42:19 +0000 (15:42 +0200)]
net/szedata2: use dynamically allocated queues

Previously the queues were the part of private data structure of the
Ethernet device.
Now the queues are allocated at setup thus numa-aware allocation is
possible.

Signed-off-by: Matej Vido <vido@cesnet.cz>
6 years agonet/szedata2: fix total stats
Matej Vido [Wed, 4 Apr 2018 13:42:18 +0000 (15:42 +0200)]
net/szedata2: fix total stats

Counters from all queues have to be summed up for total stats
even though the number of queue stats counters is not sufficient.

Fixes: 83556fd2c0fc ("szedata2: change to physical device type")
Cc: stable@dpdk.org
Signed-off-by: Matej Vido <vido@cesnet.cz>
6 years agonet/bonding: switch to new offloading API
Ferruh Yigit [Thu, 22 Mar 2018 18:13:24 +0000 (18:13 +0000)]
net/bonding: switch to new offloading API

Switch to new ethdev offloading API.

Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com>
Acked-by: Radu Nicolau <radu.nicolau@intel.com>
6 years agonet/bonding: clear started state if start fails
Chas Williams [Fri, 23 Mar 2018 17:05:32 +0000 (13:05 -0400)]
net/bonding: clear started state if start fails

There are several error paths where the bonding device may not start.
Clear dev_started before we return if we take one of these paths.

Fixes: 2efb58cbab6e ("bond: new link bonding library")
Cc: stable@dpdk.org
Signed-off-by: Chas Williams <chas3@att.com>
Acked-by: Radu Nicolau <radu.nicolau@intel.com>
6 years agonet/bonding: fix setting VLAN ID on slave ports
Chas Williams [Tue, 3 Apr 2018 16:01:22 +0000 (12:01 -0400)]
net/bonding: fix setting VLAN ID on slave ports

The pos returned is just the offset of the slab.  You need to use this
to offset the bits in the slab.

Fixes: c771e4ef38 ("net/bonding: enable slave VLAN filter")
Cc: stable@dpdk.org
Signed-off-by: Chas Williams <chas3@att.com>
Acked-by: Radu Nicolau <radu.nicolau@intel.com>
6 years agonet/octeontx: fix uninitialized speed variable
Stephen Hemminger [Thu, 5 Apr 2018 15:12:28 +0000 (08:12 -0700)]
net/octeontx: fix uninitialized speed variable

This is fix for Coverity Defect 268319 about uninitialized speed
in an error case. Also drop unnecessary assignment.

Coverity issue: 268319
Fixes: 4fac7c0a147e ("net/octeontx: add link update")
CC: stable@dpdk.org
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
6 years agonet/octeontx: remove redundant driver name update
Santosh Shukla [Mon, 2 Apr 2018 16:05:33 +0000 (16:05 +0000)]
net/octeontx: remove redundant driver name update

Cc: stable@dpdk.org
Signed-off-by: Santosh Shukla <santosh.shukla@caviumnetworks.com>
Reviewed-by: David Marchand <david.marchand@6wind.com>
6 years agoethdev: fix library version in meson build
Andrew Rybchenko [Tue, 20 Mar 2018 11:26:26 +0000 (11:26 +0000)]
ethdev: fix library version in meson build

Fixes: 653e038efc9b ("ethdev: remove versioning of filter control function")

Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
6 years agonet/cxgbe: update to Rx/Tx offload API
Shagun Agrawal [Wed, 4 Apr 2018 03:53:37 +0000 (09:23 +0530)]
net/cxgbe: update to Rx/Tx offload API

Update to new Rx/Tx offload API. Always set CRC stripping during
configuration, since it can't be disabled.

Signed-off-by: Shagun Agrawal <shaguna@chelsio.com>
Signed-off-by: Kumar Sanghvi <kumaras@chelsio.com>
Signed-off-by: Rahul Lakkireddy <rahul.lakkireddy@chelsio.com>
6 years agonet/cxgbe: add option to keep outer VLAN tag in QinQ
Shagun Agrawal [Wed, 4 Apr 2018 03:53:36 +0000 (09:23 +0530)]
net/cxgbe: add option to keep outer VLAN tag in QinQ

Add devargs option to keep outer VLAN tag in Q-in-Q packets.

Signed-off-by: Shagun Agrawal <shaguna@chelsio.com>
Signed-off-by: Kumar Sanghvi <kumaras@chelsio.com>
Signed-off-by: Rahul Lakkireddy <rahul.lakkireddy@chelsio.com>
6 years agodoc: add VF in CXGBE guide
Kumar Sanghvi [Wed, 4 Apr 2018 03:53:35 +0000 (09:23 +0530)]
doc: add VF in CXGBE guide

Add documentation on running DPDK on SR-IOV virtual functions for
Chelsio NICs.

Signed-off-by: Kumar Sanghvi <kumaras@chelsio.com>
Signed-off-by: Rahul Lakkireddy <rahul.lakkireddy@chelsio.com>
6 years agonet/szedata2: convert to new offload API
Matej Vido [Tue, 3 Apr 2018 15:06:21 +0000 (17:06 +0200)]
net/szedata2: convert to new offload API

Offload API is currently used only to setup correct receive function
for scattered packets.
Use offloads member instead of bitfield and advertise correct
capabilities.

Signed-off-by: Matej Vido <vido@cesnet.cz>
6 years agonet/bnxt: convert to SPDX license tag
Scott Branden [Mon, 2 Apr 2018 22:34:32 +0000 (15:34 -0700)]
net/bnxt: convert to SPDX license tag

Update the license header on bnxt files to be the standard
BSD-3-Clause license used for the rest of DPDK,
bring the files in compliance with the DPDK licensing policy.

Signed-off-by: Scott Branden <scott.branden@broadcom.com>
Signed-off-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
Acked-by: Hemant Agrawal <hemant.agrawal@nxp.com>
6 years agonet/octeontx: use the new offload APIs
Pavan Nikhilesh [Thu, 5 Apr 2018 13:23:32 +0000 (18:53 +0530)]
net/octeontx: use the new offload APIs

Use the new Rx/Tx offload APIs and remove the old style offloads.

Signed-off-by: Pavan Nikhilesh <pbhagavatula@caviumnetworks.com>
Acked-by: Santosh Shukla <santosh.shukla@caviumnetworks.com>
6 years agonet/mlx5: remove excessive data prefetch
Yongseok Koh [Mon, 12 Mar 2018 17:05:45 +0000 (10:05 -0700)]
net/mlx5: remove excessive data prefetch

In Enhanced Multi-Packet Send (eMPW), entire packet data is prefetched to
LLC if it isn't inlined. Even though this helps reducing jitter when HW
fetches data by DMA, this can thresh the LLC with evicting precious data.
And if the size of queue is large and there are many queues, this might not
be effective. Also, if application runs on a remote node from the PCIe
link, it may not be helpful and can even cause bad results.

Signed-off-by: Yongseok Koh <yskoh@mellanox.com>
Acked-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
6 years agonet/mlx5: add packet type index for TCP ack
Bin Huang [Fri, 30 Mar 2018 05:13:38 +0000 (13:13 +0800)]
net/mlx5: add packet type index for TCP ack

According to CQE format:
- l4_hdr_type:
     0 - None
     1 - TCP header was present in the packet
     2 - UDP header was present in the packet
     3 - TCP header was present in the packet with Empty
         TCP ACK indication. (TCP packet <ACK> flag is set,
         and packet carries no data)
     4 - TCP header was present in the packet with TCP ACK indication.
         (TCP packet <ACK> flag is set, and packet carries data).

A packet should be identified as TCP packet if l4_hdr_type is 1, 3 or 4.
Add corresponding idx of TCP ACK to ptype table.

previous discussion:
https://www.mail-archive.com/users@dpdk.org/msg02980.html

Signed-off-by: Bin Huang <bin.huang@hxt-semitech.com>
Acked-by: Yongseok Koh <yskoh@mellanox.com>
6 years agonet/mlx: fix warnings for unused compiler arguments
Bruce Richardson [Thu, 29 Mar 2018 13:36:20 +0000 (14:36 +0100)]
net/mlx: fix warnings for unused compiler arguments

When linking the mlx glue code libraries using CC, the linker arguments in
LDFLAGS are not prefixed with -Wl. [The EXTRA_LDFLAGS are though.] This
leads to warning messages on build:

clang-5.0: warning: argument unused during compilation: '-e xport-dynamic'

Fix this by checking for $LINK_USING_CC in the Makefiles and prefixing the
LDFLAGS appropriately if set.

Fixes: 27cea11686ff ("net/mlx4: spawn rdma-core dependency plug-in")
Fixes: 59b91bec12c6 ("net/mlx5: spawn rdma-core dependency plug-in")
Cc: stable@dpdk.org
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Yongseok Koh <yskoh@mellanox.com>
6 years agonet/mlx4: fix a typo in header file
Rami Rosen [Wed, 28 Mar 2018 01:07:09 +0000 (21:07 -0400)]
net/mlx4: fix a typo in header file

This patch fixes a trivial typo in mlx4 header file.

Fixes: 3d555728c933 ("net/mlx4: separate Rx/Tx definitions")
Cc: stable@dpdk.org
Signed-off-by: Rami Rosen <rami.rosen@intel.com>
Acked-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
6 years agonet/virtio: move to new offloads API
Tiwei Bie [Fri, 9 Mar 2018 00:32:16 +0000 (08:32 +0800)]
net/virtio: move to new offloads API

Ethdev offloads API has changed since:

commit ce17eddefc20 ("ethdev: introduce Rx queue offloads API")
commit cba7f53b717d ("ethdev: introduce Tx queue offloads API")

Signed-off-by: Tiwei Bie <tiwei.bie@intel.com>
Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com>
6 years agonet/i40e: fix flow RSS TCI use
Wei Zhao [Tue, 3 Apr 2018 06:09:36 +0000 (14:09 +0800)]
net/i40e: fix flow RSS TCI use

Vlan tci configuration from testpmd is stored in big endian, changing
it to little endian is needed before using it.

Fixes: ecad87d22383 ("net/i40e: move RSS to flow API")
Cc: stable@dpdk.org
Signed-off-by: Wei Zhao <wei.zhao1@intel.com>
Tested-by: Yuan Peng <yuan.peng@intel.com>
Acked-by: Qi Zhang <qi.z.zhang@intel.com>
6 years agonet/e1000: convert to new Tx offloads API
Wei Dai [Tue, 3 Apr 2018 02:54:56 +0000 (10:54 +0800)]
net/e1000: convert to new Tx offloads API

Ethdev Tx offloads API has changed since:
commit cba7f53b717d ("ethdev: introduce Tx queue offloads API")
This commit support the new Tx offloads API.

Signed-off-by: Wei Dai <wei.dai@intel.com>
Acked-by: Qi Zhang <qi.z.zhang@intel.com>
6 years agonet/e1000: convert to new Rx offloads API
Wei Dai [Tue, 3 Apr 2018 02:54:55 +0000 (10:54 +0800)]
net/e1000: convert to new Rx offloads API

Ethdev Rx offloads API has changed since:
commit ce17eddefc20 ("ethdev: introduce Rx queue offloads API")
This commit support the new Rx offloads API.

Signed-off-by: Wei Dai <wei.dai@intel.com>
Acked-by: Qi Zhang <qi.z.zhang@intel.com>
6 years agonet/ixgbe: convert to new Tx offloads API
Wei Dai [Thu, 22 Mar 2018 03:41:03 +0000 (11:41 +0800)]
net/ixgbe: convert to new Tx offloads API

Ethdev Tx offloads API has changed since:
commit cba7f53b717d ("ethdev: introduce Tx queue offloads API")
This commit support the new Tx offloads API.

Signed-off-by: Wei Dai <wei.dai@intel.com>
Acked-by: Qi Zhang <qi.z.zhang@intel.com>
6 years agonet/ixgbe: convert to new Rx offloads API
Wei Dai [Thu, 22 Mar 2018 03:41:02 +0000 (11:41 +0800)]
net/ixgbe: convert to new Rx offloads API

Ethdev Rx offloads API has changed since:
commit ce17eddefc20 ("ethdev: introduce Rx queue offloads API")
This commit support the new Rx offloads API.

Signed-off-by: Wei Dai <wei.dai@intel.com>
Acked-by: Qi Zhang <qi.z.zhang@intel.com>
6 years agonet/ixgbe: support VLAN strip per queue offloading in VF
Wei Dai [Thu, 22 Mar 2018 03:41:01 +0000 (11:41 +0800)]
net/ixgbe: support VLAN strip per queue offloading in VF

VLAN strip is a per queue offloading in VF. With this patch
it can be enabled or disabled on any Rx queue in VF.

Signed-off-by: Wei Dai <wei.dai@intel.com>
Acked-by: Qi Zhang <qi.z.zhang@intel.com>
6 years agonet/ixgbe: support VLAN strip per queue offloading in PF
Wei Dai [Thu, 22 Mar 2018 03:41:00 +0000 (11:41 +0800)]
net/ixgbe: support VLAN strip per queue offloading in PF

VLAN strip is a per queue offloading in PF. With this patch
it can be enabled or disabled on any Rx queue in PF.

Signed-off-by: Wei Dai <wei.dai@intel.com>
Acked-by: Qi Zhang <qi.z.zhang@intel.com>
6 years agonet/i40e: convert to new Tx offloads API
Yanglong Wu [Fri, 30 Mar 2018 08:22:12 +0000 (16:22 +0800)]
net/i40e: convert to new Tx offloads API

Ethdev Tx offloads API has changed since:
commit cba7f53b717d ("ethdev: introduce Tx queue offloads API")
This commit support the new Tx offloads API.

Signed-off-by: Yanglong Wu <yanglong.wu@intel.com>
Acked-by: Qi Zhang <qi.z.zhang@intel.com>
6 years agonet/i40e: convert to new Rx offloads API
Yanglong Wu [Fri, 30 Mar 2018 08:22:11 +0000 (16:22 +0800)]
net/i40e: convert to new Rx offloads API

Ethdev Rx offloads API has changed since:
commit cba7f53b717d ("ethdev: introduce Rx queue offloads API")
This commit support the new Rx offloads API.

Signed-off-by: Yanglong Wu <yanglong.wu@intel.com>
Acked-by: Qi Zhang <qi.z.zhang@intel.com>
6 years agonet/avf: convert to new Rx and Tx offload API
Wenzhuo Lu [Thu, 1 Mar 2018 06:41:46 +0000 (14:41 +0800)]
net/avf: convert to new Rx and Tx offload API

Ethdev Tx offloads API has changed since:
commit cba7f53b717d ("ethdev: introduce Tx queue offloads API")
This commit support the new Rx and Tx offloads API.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Acked-by: Beilei Xing <beilei.xing@intel.com>
6 years agonet/fm10k: convert to new Tx offloads API
Wei Dai [Wed, 28 Mar 2018 08:00:37 +0000 (16:00 +0800)]
net/fm10k: convert to new Tx offloads API

Ethdev Tx offloads API has changed since:
commit cba7f53b717d ("ethdev: introduce Tx queue offloads API")
This commit support the new Rx and Tx offloads API.

Signed-off-by: Wei Dai <wei.dai@intel.com>
Acked-by: Qi Zhang <qi.z.zhang@intel.com>
6 years agonet/fm10k: convert to new Rx offloads API
Wei Dai [Wed, 28 Mar 2018 08:00:36 +0000 (16:00 +0800)]
net/fm10k: convert to new Rx offloads API

Ethdev Rx offloads API has changed since:
commit ce17eddefc20 ("ethdev: introduce Rx queue offloads API")
This commit support the new Rx offloads API.

Signed-off-by: Wei Dai <wei.dai@intel.com>
Acked-by: Qi Zhang <qi.z.zhang@intel.com>