dpdk.git
7 years agonet/bnx2x: use I/O device memory read/write API
Santosh Shukla [Wed, 18 Jan 2017 01:21:30 +0000 (06:51 +0530)]
net/bnx2x: use I/O device memory read/write API

Replace the raw I/O device memory read/write access with eal abstraction
for I/O device memory read/write access to fix portability issues across
different architectures.

CC: Harish Patil <harish.patil@cavium.com>
CC: Rasesh Mody <rasesh.mody@cavium.com>
Signed-off-by: Santosh Shukla <santosh.shukla@caviumnetworks.com>
Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
7 years agonet/cxgbe: use I/O device memory read/write API
Santosh Shukla [Wed, 18 Jan 2017 01:21:31 +0000 (06:51 +0530)]
net/cxgbe: use I/O device memory read/write API

Replace the raw I/O device memory read/write access with eal
abstraction for I/O device memory read/write access to fix
portability issues across different architectures.

CC: Rahul Lakkireddy <rahul.lakkireddy@chelsio.com>
Signed-off-by: Santosh Shukla <santosh.shukla@caviumnetworks.com>
Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
7 years agonet/nfp: use I/O device memory read/write API
Santosh Shukla [Wed, 18 Jan 2017 01:21:38 +0000 (06:51 +0530)]
net/nfp: use I/O device memory read/write API

Replace the raw I/O device memory read/write access with eal
abstraction for I/O device memory read/write access to fix
portability issues across different architectures.

CC: Alejandro Lucero <alejandro.lucero@netronome.com>
Signed-off-by: Santosh Shukla <santosh.shukla@caviumnetworks.com>
Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
Acked-by: Alejandro Lucero <alejandro.lucero@netronome.com>
7 years agonet/enic: use I/O device memory read/write API
Santosh Shukla [Wed, 18 Jan 2017 01:21:33 +0000 (06:51 +0530)]
net/enic: use I/O device memory read/write API

Replace the raw I/O device memory read/write access with eal
abstraction for I/O device memory read/write access to fix portability
issues across different architectures.

CC: John Daley <johndale@cisco.com>
CC: Nelson Escobar <neescoba@cisco.com>
Signed-off-by: Santosh Shukla <santosh.shukla@caviumnetworks.com>
Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
7 years agonet/fm10k: use I/O device memory read/write API
Santosh Shukla [Wed, 18 Jan 2017 01:21:35 +0000 (06:51 +0530)]
net/fm10k: use I/O device memory read/write API

Replace the raw I/O device memory read/write access with eal
abstraction for I/O device memory read/write access to fix
portability issues across different architectures.

CC: Jing Chen <jing.d.chen@intel.com>
Signed-off-by: Santosh Shukla <santosh.shukla@caviumnetworks.com>
Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
7 years agonet/i40e: use I/O device memory read/write API
Santosh Shukla [Wed, 18 Jan 2017 01:21:36 +0000 (06:51 +0530)]
net/i40e: use I/O device memory read/write API

Replace the raw I/O device memory read/write access with eal abstraction
for I/O device memory read/write access to fix portability issues across
different architectures.

CC: Helin Zhang <helin.zhang@intel.com>
CC: Jingjing Wu <jingjing.wu@intel.com>
Signed-off-by: Santosh Shukla <santosh.shukla@caviumnetworks.com>
Signed-off-by: Satha Rao <skoteshwar@caviumnetworks.com>
Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
7 years agonet/ixgbe: use I/O device memory read/write API
Santosh Shukla [Wed, 18 Jan 2017 01:21:37 +0000 (06:51 +0530)]
net/ixgbe: use I/O device memory read/write API

Replace the raw I/O device memory read/write access with eal
abstraction for I/O device memory read/write access to fix
portability issues across different architectures.

CC: Helin Zhang <helin.zhang@intel.com>
CC: Konstantin Ananyev <konstantin.ananyev@intel.com>
Signed-off-by: Santosh Shukla <santosh.shukla@caviumnetworks.com>
Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
7 years agonet/e1000: use I/O device memory read/write API
Santosh Shukla [Wed, 18 Jan 2017 01:21:32 +0000 (06:51 +0530)]
net/e1000: use I/O device memory read/write API

Replace the raw I/O device memory read/write access with eal
abstraction for I/O device memory read/write access to fix
portability issues across different architectures.

CC: Wenzhuo Lu <wenzhuo.lu@intel.com>
Signed-off-by: Santosh Shukla <santosh.shukla@caviumnetworks.com>
Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
7 years agoeal/arm64: change barrier definitions to macros
Jerin Jacob [Wed, 18 Jan 2017 01:21:27 +0000 (06:51 +0530)]
eal/arm64: change barrier definitions to macros

Change rte_*wb definitions to macros in order to
keep consistent with other barrier definitions in
the file.

Suggested-by: Jianbo Liu <jianbo.liu@linaro.org>
Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
7 years agoeal/arm64: override I/O device read/write access
Jerin Jacob [Wed, 18 Jan 2017 01:21:26 +0000 (06:51 +0530)]
eal/arm64: override I/O device read/write access

Override the generic I/O device memory read/write access and implement it
using armv8 instructions for arm64.

Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
7 years agoeal: let all architectures use generic I/O implementation
Jerin Jacob [Wed, 18 Jan 2017 01:21:25 +0000 (06:51 +0530)]
eal: let all architectures use generic I/O implementation

Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
7 years agoeal: add generic I/O device read/write implementation
Jerin Jacob [Wed, 18 Jan 2017 01:21:24 +0000 (06:51 +0530)]
eal: add generic I/O device read/write implementation

This patch implements the generic version of rte_read[b/w/l/q]_[relaxed]
and rte_write[b/w/l/q]_[relaxed] using rte_io_wmb() and rte_io_rmb()

Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
7 years agoeal: introduce I/O device memory read/write operations
Jerin Jacob [Wed, 18 Jan 2017 01:21:23 +0000 (06:51 +0530)]
eal: introduce I/O device memory read/write operations

This commit introduces 8-bit, 16-bit, 32bit, 64bit I/O device
memory read/write operations along with the relaxed versions.

The weakly-ordered machine like ARM needs additional I/O barrier for
device memory read/write access over PCI bus.
By introducing the eal abstraction for I/O device memory read/write access,
The drivers can access I/O device memory in architecture agnostic manner.

The relaxed version does not have additional I/O memory barrier, useful in
accessing the device registers of integrated controllers which
implicitly strongly ordered with respect to memory access.

Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
7 years agoeal/arm64: define I/O device memory barriers
Jerin Jacob [Wed, 18 Jan 2017 01:21:22 +0000 (06:51 +0530)]
eal/arm64: define I/O device memory barriers

CC: Jianbo Liu <jianbo.liu@linaro.org>
Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
7 years agoeal/arm64: define SMP barrier
Jerin Jacob [Wed, 18 Jan 2017 01:21:21 +0000 (06:51 +0530)]
eal/arm64: define SMP barrier

dmb instruction based barrier is used for smp version of memory barrier.

Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
7 years agoeal/arm64: fix memory barrier definition
Jerin Jacob [Wed, 18 Jan 2017 01:21:20 +0000 (06:51 +0530)]
eal/arm64: fix memory barrier definition

dsb instruction based barrier is used for non smp
version of memory barrier.

Fixes: d708f01b7102 ("eal/arm: add atomic operations for ARMv8")
Cc: stable@dpdk.org
Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
Acked-by: Jianbo Liu <jianbo.liu@linaro.org>
7 years agoeal/armv7: define I/O device memory barriers
Jerin Jacob [Wed, 18 Jan 2017 01:21:19 +0000 (06:51 +0530)]
eal/armv7: define I/O device memory barriers

The patch does not provide any functional change for ARMv7.
I/O barriers are mapped to existing smp barriers.

CC: Jan Viktorin <viktorin@rehivetech.com>
CC: Jianbo Liu <jianbo.liu@linaro.org>
Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
7 years agoeal/arm: separate SMP barrier definition for ARMv7 and ARMv8
Jerin Jacob [Wed, 18 Jan 2017 01:21:18 +0000 (06:51 +0530)]
eal/arm: separate SMP barrier definition for ARMv7 and ARMv8

Separate the smp barrier definition for arm and arm64 for fine
control on smp barrier definition for each architecture.

Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
7 years agoeal/ppc64: define I/O device memory barriers
Jerin Jacob [Wed, 18 Jan 2017 01:21:17 +0000 (06:51 +0530)]
eal/ppc64: define I/O device memory barriers

The patch does not provide any functional change for ppc_64.
I/O barriers are mapped to existing smp barriers.

CC: Chao Zhu <chaozhu@linux.vnet.ibm.com>
Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
7 years agoeal/tile: define I/O device memory barriers
Jerin Jacob [Wed, 18 Jan 2017 01:21:16 +0000 (06:51 +0530)]
eal/tile: define I/O device memory barriers

The patch does not provide any functional change for tile.
I/O barriers are mapped to existing smp barriers.

CC: Zhigang Lu <zlu@ezchip.com>
Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
7 years agoeal/x86: define I/O device memory barriers
Jerin Jacob [Wed, 18 Jan 2017 01:21:15 +0000 (06:51 +0530)]
eal/x86: define I/O device memory barriers

The patch does not provide any functional change for IA.
I/O barriers are mapped to existing smp barriers.

CC: Bruce Richardson <bruce.richardson@intel.com>
CC: Konstantin Ananyev <konstantin.ananyev@intel.com>
Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
7 years agoeal: introduce I/O device memory barriers
Jerin Jacob [Wed, 18 Jan 2017 01:21:14 +0000 (06:51 +0530)]
eal: introduce I/O device memory barriers

This commit introduce rte_io_mb(), rte_io_wmb() and rte_io_rmb(), in
order to enable memory barriers between I/O device and CPU.

Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
7 years agodevtools: relax tag checking in fixes
Thomas Monjalon [Tue, 17 Jan 2017 14:35:11 +0000 (15:35 +0100)]
devtools: relax tag checking in fixes

The tag "Cc: stable@dpdk.org" must be set when the commit must be
backported to a stable branch. The reminder is reworded.

It should be located just below the "Fixes:" tag (without blank line)
and followed by a blank line, separated from SoB and review tags below.
However, there is no strong need for checking blank lines.

Signed-off-by: Thomas Monjalon <thomas.monjalon@6wind.com>
Reviewed-by: Yuanhan Liu <yuanhan.liu@linux.intel.com>
7 years agodevtools: fix lookup commit fixing a fix of many commits
Thomas Monjalon [Tue, 17 Jan 2017 14:24:20 +0000 (15:24 +0100)]
devtools: fix lookup commit fixing a fix of many commits

There was a bug when looking at a commit fixing a commit which
itself was fixing many commits:

% devtools/git-log-fixes.sh 12ee45a36~..12ee45a36
devtools/git-log-fixes.sh: 96: local: 5499c1fc9baa: bad variable name

In this case, the list of commits was not quoted in variable assignment.

Signed-off-by: Thomas Monjalon <thomas.monjalon@6wind.com>
7 years agoconfig: enable nfp driver on Linux
Alejandro Lucero [Fri, 13 Jan 2017 11:50:02 +0000 (11:50 +0000)]
config: enable nfp driver on Linux

Because using a NFP PMD requires specific BSP installed, the PMD
support was not the default option before. This was just for making
people aware of such dependency, since there is no need for such a
BSP for just compiling DPDK with NFP PMD support.

Signed-off-by: Alejandro Lucero <alejandro.lucero@netronome.com>
7 years agonet/mlx5: support extended statistics
Shahaf Shuler [Tue, 17 Jan 2017 14:37:08 +0000 (16:37 +0200)]
net/mlx5: support extended statistics

Implement extended statistics callbacks.

Suggested-by: Hanoch Haim <hhaim@cisco.com>
Signed-off-by: Shahaf Shuler <shahafs@mellanox.com>
Signed-off-by: Elad Persiko <eladpe@mellanox.com>
Acked-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
7 years agodoc: update release notes for i40e base driver
Jingjing Wu [Tue, 17 Jan 2017 16:49:46 +0000 (00:49 +0800)]
doc: update release notes for i40e base driver

Signed-off-by: Jingjing Wu <jingjing.wu@intel.com>
7 years agonet/i40e: support Linux VF to configure IRQ link list
Chen Jing D(Mark) [Fri, 13 Jan 2017 03:13:21 +0000 (11:13 +0800)]
net/i40e: support Linux VF to configure IRQ link list

i40e PF host only support to work with DPDK VF driver, Linux
VF driver is not supported. This change will enhance in
configuring IRQ link list.

This Change will identify VF client by number of vector
requested. DPDK VF will ask only single one while Linux VF
will request at least 2. It will have different configuration
for different clients. DPDK VF will be configured to link all
queue together, while Linux VF will be configured per request.

Signed-off-by: Chen Jing D(Mark) <jing.d.chen@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
Acked-by: Vincent Jardin <vincent.jardin@6wind.com>
7 years agonet/i40e: parse more VF parameter and configure
Chen Jing D(Mark) [Fri, 13 Jan 2017 03:13:20 +0000 (11:13 +0800)]
net/i40e: parse more VF parameter and configure

When VF requested to configure TX queue, a few parameters are
missed to be configured in PF host. This change have more
fields parsed and configured for TX context.

Signed-off-by: Chen Jing D(Mark) <jing.d.chen@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
Acked-by: Vincent Jardin <vincent.jardin@6wind.com>
7 years agonet/i40e: return correct VSI id
Chen Jing D(Mark) [Fri, 13 Jan 2017 03:13:19 +0000 (11:13 +0800)]
net/i40e: return correct VSI id

PF host didn't return correct VSI id to VF.
This change fix it.

Signed-off-by: Chen Jing D(Mark) <jing.d.chen@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
Acked-by: Vincent Jardin <vincent.jardin@6wind.com>
7 years agonet/i40e: change version number to support Linux VF
Chen Jing D(Mark) [Fri, 13 Jan 2017 03:13:18 +0000 (11:13 +0800)]
net/i40e: change version number to support Linux VF

i40e PF host only support to work with DPDK VF driver, Linux
VF driver is not supported. This change will enhance in version
number returned.

Current version info returned won't be able to be recognized
by Linux VF driver, change to values that both DPDK VF and Linux
driver can recognize.

The expense is original DPDK host specific feature like
CFG_VLAN_PVID and CONFIG_VSI_QUEUES_EXT will not available.

DPDK VF also can't identify host driver by version number returned.
It always assume talking with Linux PF.

Signed-off-by: Chen Jing D(Mark) <jing.d.chen@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
Acked-by: Vincent Jardin <vincent.jardin@6wind.com>
7 years agodoc: update for VFD experimental API
Wenzhuo Lu [Tue, 17 Jan 2017 08:45:28 +0000 (16:45 +0800)]
doc: update for VFD experimental API

Update the doc and release note.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
Acked-by: Vincent Jardin <vincent.jardin@6wind.com>
7 years agonet/i40e: set/clear VF stats from PF
Qi Zhang [Tue, 17 Jan 2017 08:45:27 +0000 (16:45 +0800)]
net/i40e: set/clear VF stats from PF

This patch add support to get/clear VF statistics
from PF side.
Two APIs are added:
rte_pmd_i40e_get_vf_stats.
rte_pmd_i40e_reset_vf_stats.

Signed-off-by: Qi Zhang <qi.z.zhang@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
Acked-by: Vincent Jardin <vincent.jardin@6wind.com>
7 years agonet/i40e: enhance sanity check of MAC
Chen Jing D(Mark) [Tue, 17 Jan 2017 08:45:26 +0000 (16:45 +0800)]
net/i40e: enhance sanity check of MAC

When VF sends request to add a new MAC address, PF host
will check if it's a non-zero or unicast address, or it
will return with error. In fact, VF still can set multicast
address. This change remove to check if it's a unicast
address.

Signed-off-by: Chen Jing D(Mark) <jing.d.chen@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
Acked-by: Vincent Jardin <vincent.jardin@6wind.com>
7 years agoapp/testpmd: handle i40e in VF VLAN filter command
Bernard Iremonger [Tue, 17 Jan 2017 08:45:25 +0000 (16:45 +0800)]
app/testpmd: handle i40e in VF VLAN filter command

modify set_vf_rx_vlan function to handle the i40e PMD.

Signed-off-by: Bernard Iremonger <bernard.iremonger@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
Acked-by: Vincent Jardin <vincent.jardin@6wind.com>
7 years agoapp/testpmd: add command for VF VLAN tag on i40e
Bernard Iremonger [Tue, 17 Jan 2017 08:45:24 +0000 (16:45 +0800)]
app/testpmd: add command for VF VLAN tag on i40e

command is: set vf vlan tag port_id vf_id on|off

Signed-off-by: Bernard Iremonger <bernard.iremonger@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
Acked-by: Vincent Jardin <vincent.jardin@6wind.com>
7 years agoapp/testpmd: add command for VF broadcast mode on i40e
Bernard Iremonger [Tue, 17 Jan 2017 08:45:23 +0000 (16:45 +0800)]
app/testpmd: add command for VF broadcast mode on i40e

Add command to call rte_pmd_i40e_set_vf_broadcast.
Add set vf broadcast in testpmd_funcs.rst file.

Signed-off-by: Bernard Iremonger <bernard.iremonger@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
Acked-by: Vincent Jardin <vincent.jardin@6wind.com>
7 years agoapp/testpmd: use multicast promiscuous mode on i40e
Wenzhuo Lu [Tue, 17 Jan 2017 08:45:22 +0000 (16:45 +0800)]
app/testpmd: use multicast promiscuous mode on i40e

Add testpmd CLI to set VF multicast promiscuous mode on i40e.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
Acked-by: Vincent Jardin <vincent.jardin@6wind.com>
7 years agoapp/testpmd: use unicast promiscuous mode on i40e
Wenzhuo Lu [Tue, 17 Jan 2017 08:45:21 +0000 (16:45 +0800)]
app/testpmd: use unicast promiscuous mode on i40e

Add testpmd CLI to set VF unicast promiscuous mode on i40e.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
Acked-by: Vincent Jardin <vincent.jardin@6wind.com>
7 years agoapp/testpmd: use VFD APIs on i40e
Wenzhuo Lu [Tue, 17 Jan 2017 08:45:20 +0000 (16:45 +0800)]
app/testpmd: use VFD APIs on i40e

The new VF Daemon (VFD) APIs is implemented on i40e. Change
testpmd code to use them, including VF MAC anti-spoofing,
VF VLAN anti-spoofing, TX loopback, VF VLAN strip, VF VLAN
insert.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Signed-off-by: Chen Jing D(Mark) <jing.d.chen@intel.com>
Signed-off-by: Bernard Iremonger <bernard.iremonger@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
Acked-by: Vincent Jardin <vincent.jardin@6wind.com>
7 years agonet/i40e: set VF VLAN filter from PF
Bernard Iremonger [Tue, 17 Jan 2017 08:45:19 +0000 (16:45 +0800)]
net/i40e: set VF VLAN filter from PF

add rte_pmd_i40e_set_vf_vlan_filter API.
User can call the API on PF to enable/disable
a set of VF's VLAN filters.

Signed-off-by: Bernard Iremonger <bernard.iremonger@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
Acked-by: Vincent Jardin <vincent.jardin@6wind.com>
7 years agonet/i40e: set VF VLAN tag from PF
Bernard Iremonger [Tue, 17 Jan 2017 08:45:18 +0000 (16:45 +0800)]
net/i40e: set VF VLAN tag from PF

Add rte_pmd_i40e_set_vf_vlan_tag API.
User can call the API on PF to enable/disable a specific
VF's VLAN tag.

Signed-off-by: Bernard Iremonger <bernard.iremonger@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
Acked-by: Vincent Jardin <vincent.jardin@6wind.com>
7 years agonet/i40e: set VF broadcast mode from PF
Bernard Iremonger [Tue, 17 Jan 2017 08:45:17 +0000 (16:45 +0800)]
net/i40e: set VF broadcast mode from PF

Support enabling/disabling VF broadcast mode from PF.
User can call the API on PF to enable/disable a specific
VF's broadcast mode.

Signed-off-by: Bernard Iremonger <bernard.iremonger@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
Acked-by: Vincent Jardin <vincent.jardin@6wind.com>
7 years agonet/i40e: set VF VLAN insertion from PF
Bernard Iremonger [Tue, 17 Jan 2017 08:45:16 +0000 (16:45 +0800)]
net/i40e: set VF VLAN insertion from PF

Support inserting VF VLAN id from PF.
User can call the API on PF to insert a VLAN id to a
specific VF.

Signed-off-by: Bernard Iremonger <bernard.iremonger@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
Acked-by: Vincent Jardin <vincent.jardin@6wind.com>
7 years agonet/i40e: set VF VLAN strip from PF
Chen Jing D(Mark) [Tue, 17 Jan 2017 08:45:15 +0000 (16:45 +0800)]
net/i40e: set VF VLAN strip from PF

Add a function to configure vlan strip enable/disable for specific
SRIOV VF device.

Signed-off-by: Chen Jing D(Mark) <jing.d.chen@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
Acked-by: Vincent Jardin <vincent.jardin@6wind.com>
7 years agonet/i40e: fix VF MAC address assignment
Ferruh Yigit [Tue, 17 Jan 2017 08:45:14 +0000 (16:45 +0800)]
net/i40e: fix VF MAC address assignment

If PF sets vf->mac_addr, in VF initialization hw->mac.addr will be set
to that same value. It is possible to check if PF set a MAC address or
not through the hw->mac.addr variable.

hw->mac.addr set by i40e_vf_parse_hw_config(), call stack is:

In PF side
i40e_pf_host_process_cmd_get_vf_resources()
    eth_addr_copy(vf->mac_addr, vf_res->vsi_res[0].default_mac_address)

In VF sise
i40evf_init_vf()
    i40evf_get_vf_resources()
            i40e_vf_parse_hw_config()
                    memcpy(hw->mac.addr, vsi_res->default_mac_addr)

Updated code is after i40evf_get_vf_resources() and can benefit from
hw->mac.addr variable.

Fixes: 89e6b86384bb ("i40evf: rework MAC address validation")

Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
Acked-by: Vincent Jardin <vincent.jardin@6wind.com>
7 years agonet/i40e: set VF MAC from VF
Ferruh Yigit [Tue, 17 Jan 2017 08:45:13 +0000 (16:45 +0800)]
net/i40e: set VF MAC from VF

Support changing VF default MAC address.
This function is not supported if PF set the MAC
address for the PF.

Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
Acked-by: Vincent Jardin <vincent.jardin@6wind.com>
7 years agonet/i40e: set VF MAC from PF
Ferruh Yigit [Tue, 17 Jan 2017 08:45:12 +0000 (16:45 +0800)]
net/i40e: set VF MAC from PF

Support setting VF MAC address from PF.
User can call the API on PF to set a specific
VF's MAC address.

PF should set MAC address before VF initialized,
if PF sets the MAC address after VF initialized,
new MAC address won't be effective until VF
reinitialized.

This will remove all existing MAC filters.

Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
Acked-by: Vincent Jardin <vincent.jardin@6wind.com>
7 years agonet/i40e: fix VF reset flow
Qi Zhang [Tue, 17 Jan 2017 08:45:11 +0000 (16:45 +0800)]
net/i40e: fix VF reset flow

Add missing step during VF reset: PF should
set I40E_VFGEN_RSTAT to ACTIVE at end of the
VF reset operation or VF driver may not able
to detect that reset is already completed.
This patch also remove the unnecessary enum
for vfr state.

Fixes: 4861cde46116 ("i40e: new poll mode driver")

Signed-off-by: Qi Zhang <qi.z.zhang@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
Acked-by: Vincent Jardin <vincent.jardin@6wind.com>
7 years agonet/i40e: enable VF MTU change
Qi Zhang [Tue, 17 Jan 2017 08:45:10 +0000 (16:45 +0800)]
net/i40e: enable VF MTU change

This patch implement mtu_set ops for i40e VF.

Signed-off-by: Qi Zhang <qi.z.zhang@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
Acked-by: Vincent Jardin <vincent.jardin@6wind.com>
7 years agonet/i40e: set VF multicast promiscuous mode from PF
Wenzhuo Lu [Tue, 17 Jan 2017 08:45:09 +0000 (16:45 +0800)]
net/i40e: set VF multicast promiscuous mode from PF

Support enabling/disabling VF multicast promiscuous mode from
PF.
User can call the API on PF to enable/disable a specific
VF's multicast promiscuous mode.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
Acked-by: Vincent Jardin <vincent.jardin@6wind.com>
7 years agonet/i40e: set VF unicast promiscuous mode from PF
Wenzhuo Lu [Tue, 17 Jan 2017 08:45:08 +0000 (16:45 +0800)]
net/i40e: set VF unicast promiscuous mode from PF

Support enabling/disabling VF unicast promiscuous mode from
PF.
User can call the API on PF to enable/disable a specific
VF's unicast promiscuous mode.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
Acked-by: Vincent Jardin <vincent.jardin@6wind.com>
7 years agonet/i40e: set Tx loopback from PF
Wenzhuo Lu [Tue, 17 Jan 2017 08:45:07 +0000 (16:45 +0800)]
net/i40e: set Tx loopback from PF

Support enabling/disabling TX loopback from PF.
User can call the API on PF to enable/disable TX loopback
for all the PF and VFs.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
Acked-by: Vincent Jardin <vincent.jardin@6wind.com>
7 years agonet/i40e: set VF VLAN anti-spoofing from PF
Wenzhuo Lu [Tue, 17 Jan 2017 08:45:06 +0000 (16:45 +0800)]
net/i40e: set VF VLAN anti-spoofing from PF

Support enabling/disabling VF VLAN anti-spoofing from
PF.
User can call the API on PF to enable/disable a specific
VF's VLAN anti-spoofing.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
Acked-by: Vincent Jardin <vincent.jardin@6wind.com>
7 years agonet/i40e: set VF MAC anti-spoofing from PF
Wenzhuo Lu [Tue, 17 Jan 2017 08:45:05 +0000 (16:45 +0800)]
net/i40e: set VF MAC anti-spoofing from PF

Support enabling/disabling VF MAC anti-spoofing from
PF.
User can call the API on PF to enable/disable a specific
VF's MAC anti-spoofing.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
Acked-by: Vincent Jardin <vincent.jardin@6wind.com>
7 years agonet/i40e: add user callback for VF to PF message
Wenzhuo Lu [Tue, 17 Jan 2017 08:45:04 +0000 (16:45 +0800)]
net/i40e: add user callback for VF to PF message

The callback asks the user application if it is allowed to
perform the mailbox messages.

If the return value from user is RTE_PMD_I40E_MB_EVENT_PROCEED
then continue. If ACK or NACK, do nothing and send
not_supported to VF.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
Acked-by: Vincent Jardin <vincent.jardin@6wind.com>
7 years agonet/i40e: support link status notification
Wenzhuo Lu [Tue, 17 Jan 2017 08:45:03 +0000 (16:45 +0800)]
net/i40e: support link status notification

Add an API to expose the ability, that PF can notify VF
when link status changes, to APP.
So if PF APP doesn't want to enable interruption but check
link status by itself, PF APP can let VF know link status
changed.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
Acked-by: Vincent Jardin <vincent.jardin@6wind.com>
7 years agonet/mlx: fix IPv4 and IPv6 packet type
Matthieu Ternisien d'Ouville [Wed, 11 Jan 2017 16:44:33 +0000 (17:44 +0100)]
net/mlx: fix IPv4 and IPv6 packet type

Mellanox PMDs do not differentiate IP header with or without options, so
the advertised packet type for an IPv4 should not be RTE_PTYPE_L3_IPV4,
which explicitly means "does not contain any header option".

Change the driver to set
RTE_PTYPE(_INNER)_L3_IPV4_EXT_UNKNOWN or
RTE_PTYPE(_INNER)_L3_IPV6_EXT_UNKNOWN flags for all IPv4/IPv6 packets
received.

Fixes: 429df3803a16 ("mlx4: replace some offload flags with packet type")
Fixes: 67fa62bc672d ("mlx5: support checksum offload")

Signed-off-by: Samuel Gauthier <samuel.gauthier@6wind.com>
Signed-off-by: Matthieu Ternisien d'Ouville <matthieu.tdo@6wind.com>
Signed-off-by: Olivier Matz <olivier.matz@6wind.com>
Acked-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
7 years agonet/mlx: remove link update lock
Matthieu Ternisien d'Ouville [Wed, 11 Jan 2017 16:44:01 +0000 (17:44 +0100)]
net/mlx: remove link update lock

Retrieving link status information through the link update callback should
be quick and non-blocking.

Mellanox PMDs retrieve this information through ioctl() calls on the
related kernel netdevice. This appears to take a long time to
complete and may cause significant slowdowns in applications.

While these system calls cannot be accelerated, removing the lock on the
private structure allows applications to perform other control operations
from separate threads in the meantime. This function remains safe without
locking as it does not write the private structure, it is only used to
retrieve the name of the netdevice.

Signed-off-by: Matthieu Ternisien d'Ouville <matthieu.tdo@6wind.com>
Signed-off-by: Olivier Matz <olivier.matz@6wind.com>
Acked-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
7 years agonet/af_packet: support 802.1Q VLAN
Chas Williams [Thu, 5 Jan 2017 13:53:44 +0000 (08:53 -0500)]
net/af_packet: support 802.1Q VLAN

AF_PACKET has some flags to check on the receive side for 802.1Q
information.  If present, we copy into the mbuf.  For transmit, we
insert any 802.1Q information into the packet before copying to the ring.

Signed-off-by: Chas Williams <ciwillia@brocade.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
7 years agonet/af_packet: support promiscuous
Chas Williams [Thu, 5 Jan 2017 13:53:43 +0000 (08:53 -0500)]
net/af_packet: support promiscuous

Add promiscuous support to the AF_PACKET PMD.  The underlying Linux
device's IF_PROMISC flag is toggled to enable or disable.

Signed-off-by: Chas Williams <ciwillia@brocade.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
7 years agonet/af_packet: support MTU change
Chas Williams [Thu, 5 Jan 2017 13:53:42 +0000 (08:53 -0500)]
net/af_packet: support MTU change

The underlying Linux device's MTU is changed subject to the frame size
limitations during device creation.

Signed-off-by: Chas Williams <ciwillia@brocade.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
7 years agonet/af_packet: add interface name to internals
Chas Williams [Thu, 5 Jan 2017 13:53:41 +0000 (08:53 -0500)]
net/af_packet: add interface name to internals

This will be used by later changes to determine the underlying Linux
interface.

Signed-off-by: Chas Williams <ciwillia@brocade.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
7 years agonet/bnxt: make ethdev functions struct const
Ferruh Yigit [Thu, 12 Jan 2017 22:19:37 +0000 (22:19 +0000)]
net/bnxt: make ethdev functions struct const

Reported-by: Stephen Hemminger <stephen@networkplumber.org>
Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com>
7 years agonet/ena: make ethdev functions struct const
Ferruh Yigit [Thu, 12 Jan 2017 22:18:55 +0000 (22:18 +0000)]
net/ena: make ethdev functions struct const

Reported-by: Stephen Hemminger <stephen@networkplumber.org>
Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com>
7 years agonet/qede: fix function declaration
Emmanuel Roullit [Sun, 15 Jan 2017 19:51:24 +0000 (20:51 +0100)]
net/qede: fix function declaration

clang reports this error message:
error: this function declaration is not a prototype
[-Werror,-Wstrict-prototypes]

Fixes: 5cdd769a26ec ("qede: add L2 support")

Signed-off-by: Emmanuel Roullit <emmanuel.roullit@gmail.com>
Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>
7 years agonet/cxgbe: fix parenthesis on bitwise operation
Emmanuel Roullit [Sun, 15 Jan 2017 19:50:37 +0000 (20:50 +0100)]
net/cxgbe: fix parenthesis on bitwise operation

clang reports the following error:
error: logical not is only applied to the left hand side of this bitwise
operator. [-Werror,-Wlogical-not-parentheses]

Fixes: 92c8a63223e5 ("cxgbe: add device configuration and Rx support")

Signed-off-by: Emmanuel Roullit <emmanuel.roullit@gmail.com>
Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>
7 years agonet/ixgbe: flush all the filter list
Wei Zhao [Fri, 13 Jan 2017 08:13:12 +0000 (16:13 +0800)]
net/ixgbe: flush all the filter list

This patch adds a function to flush all the filter list
filter on a port.

Signed-off-by: Wei Zhao <wei.zhao1@intel.com>
Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Acked-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Wei Dai <wei.dai@intel.com>
7 years agonet/ixgbe: destroy consistent filter
Wei Zhao [Fri, 13 Jan 2017 08:13:11 +0000 (16:13 +0800)]
net/ixgbe: destroy consistent filter

This patch adds a function to destroy the flow filter.

Signed-off-by: Wei Zhao <wei.zhao1@intel.com>
Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Acked-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Wei Dai <wei.dai@intel.com>
7 years agonet/ixgbe: create consistent filter
Wei Zhao [Fri, 13 Jan 2017 08:13:10 +0000 (16:13 +0800)]
net/ixgbe: create consistent filter

This patch adds a function to create the flow directory filter.

Signed-off-by: Wei Zhao <wei.zhao1@intel.com>
Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Acked-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Wei Dai <wei.dai@intel.com>
7 years agonet/ixgbe: parse flow director filter
Wei Zhao [Fri, 13 Jan 2017 08:13:09 +0000 (16:13 +0800)]
net/ixgbe: parse flow director filter

check if the rule is a flow director rule, and get the flow director info.

Signed-off-by: Wei Zhao <wei.zhao1@intel.com>
Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Acked-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Wei Dai <wei.dai@intel.com>
7 years agonet/ixgbe: parse L2 tunnel filter
Wei Zhao [Fri, 13 Jan 2017 08:13:08 +0000 (16:13 +0800)]
net/ixgbe: parse L2 tunnel filter

check if the rule is a L2 tunnel rule, and get the L2 tunnel info.

Signed-off-by: Wei Zhao <wei.zhao1@intel.com>
Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Acked-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Wei Dai <wei.dai@intel.com>
7 years agonet/ixgbe: parse TCP SYN filter
Wei Zhao [Fri, 13 Jan 2017 08:13:07 +0000 (16:13 +0800)]
net/ixgbe: parse TCP SYN filter

check if the rule is a TCP SYN rule, and get the SYN info.

Signed-off-by: Wei Zhao <wei.zhao1@intel.com>
Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Acked-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Wei Dai <wei.dai@intel.com>
7 years agonet/ixgbe: parse ethertype filter
Wei Zhao [Fri, 13 Jan 2017 08:13:06 +0000 (16:13 +0800)]
net/ixgbe: parse ethertype filter

check if the rule is a ethertype rule, and get the ethertype info.

Signed-off-by: Wei Zhao <wei.zhao1@intel.com>
Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Acked-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Wei Dai <wei.dai@intel.com>
7 years agonet/ixgbe: parse n-tuple filter
Wei Zhao [Fri, 13 Jan 2017 08:13:05 +0000 (16:13 +0800)]
net/ixgbe: parse n-tuple filter

Add rule validate function and check if the rule is a n-tuple rule,
and get the n-tuple info.

Signed-off-by: Wei Zhao <wei.zhao1@intel.com>
Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Acked-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Wei Dai <wei.dai@intel.com>
7 years agonet/ixgbe: flush all the filters
Wei Zhao [Fri, 13 Jan 2017 08:13:04 +0000 (16:13 +0800)]
net/ixgbe: flush all the filters

Add support for flush all the filters in SW.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Signed-off-by: Wei Zhao <wei.zhao1@intel.com>
Acked-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Wei Dai <wei.dai@intel.com>
7 years agonet/ixgbe: store and restore L2 tunnel configuration
Wei Zhao [Fri, 13 Jan 2017 08:13:03 +0000 (16:13 +0800)]
net/ixgbe: store and restore L2 tunnel configuration

Add support for store and restore L2 tunnel filter in SW.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Signed-off-by: Wei Zhao <wei.zhao1@intel.com>
Acked-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Wei Dai <wei.dai@intel.com>
7 years agonet/ixgbe: restore L2 tunnel filter
Wei Zhao [Fri, 13 Jan 2017 08:13:02 +0000 (16:13 +0800)]
net/ixgbe: restore L2 tunnel filter

Add support for restoring L2 tunnel filter in SW.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Signed-off-by: Wei Zhao <wei.zhao1@intel.com>
Acked-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Wei Dai <wei.dai@intel.com>
7 years agonet/ixgbe: restore flow director filter
Wei Zhao [Fri, 13 Jan 2017 08:13:01 +0000 (16:13 +0800)]
net/ixgbe: restore flow director filter

Add support for storing flow director filter in SW.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Signed-off-by: Wei Zhao <wei.zhao1@intel.com>
Acked-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Wei Dai <wei.dai@intel.com>
7 years agonet/ixgbe: restore TCP SYN filter
Wei Zhao [Fri, 13 Jan 2017 08:13:00 +0000 (16:13 +0800)]
net/ixgbe: restore TCP SYN filter

Add support for restoring TCP SYN filter in SW.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Signed-off-by: Wei Zhao <wei.zhao1@intel.com>
Acked-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Wei Dai <wei.dai@intel.com>
7 years agonet/ixgbe: restore ether type filter
Wei Zhao [Fri, 13 Jan 2017 08:12:59 +0000 (16:12 +0800)]
net/ixgbe: restore ether type filter

Add support for restoring ether type filter in SW.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Signed-off-by: Wei Zhao <wei.zhao1@intel.com>
Acked-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Wei Dai <wei.dai@intel.com>
7 years agonet/ixgbe: restore n-tuple filter
Wei Zhao [Fri, 13 Jan 2017 08:12:58 +0000 (16:12 +0800)]
net/ixgbe: restore n-tuple filter

Add support for restoring n-tuple filter in SW.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Signed-off-by: Wei Zhao <wei.zhao1@intel.com>
Acked-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Wei Dai <wei.dai@intel.com>
7 years agonet/ixgbe: store L2 tunnel filter
Wei Zhao [Fri, 13 Jan 2017 08:12:57 +0000 (16:12 +0800)]
net/ixgbe: store L2 tunnel filter

Add support for storing L2 tunnel filter in SW.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Signed-off-by: Wei Zhao <wei.zhao1@intel.com>
Acked-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Wei Dai <wei.dai@intel.com>
7 years agonet/ixgbe: store flow director filter
Wei Zhao [Fri, 13 Jan 2017 08:12:56 +0000 (16:12 +0800)]
net/ixgbe: store flow director filter

Add support for storing flow director filter in SW.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Signed-off-by: Wei Zhao <wei.zhao1@intel.com>
Acked-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Wei Dai <wei.dai@intel.com>
7 years agonet/ixgbe: store TCP SYN filter
Wei Zhao [Fri, 13 Jan 2017 08:12:55 +0000 (16:12 +0800)]
net/ixgbe: store TCP SYN filter

Add support for storing TCP SYN filter in SW.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Signed-off-by: Wei Zhao <wei.zhao1@intel.com>
Acked-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Wei Dai <wei.dai@intel.com>
7 years agonet/nfp: fix VLAN offload flags check
Olivier Matz [Thu, 12 Jan 2017 13:04:56 +0000 (14:04 +0100)]
net/nfp: fix VLAN offload flags check

Fix typo when checking that no VLAN offload flags are passed at port
initialization.

By the way, also fix a typo in the log.

Fixes: d4a27a3b092a ("nfp: add basic features")

Signed-off-by: Olivier Matz <olivier.matz@6wind.com>
Acked-by: Alejandro Lucero <alejandro.lucero@netronome.com>
7 years agonet/ixgbe/base: update shared code version to 2017.01.05
Wei Dai [Thu, 12 Jan 2017 14:53:31 +0000 (22:53 +0800)]
net/ixgbe/base: update shared code version to 2017.01.05

Update version of shared code to 2017-01-05 in README.

Signed-off-by: Wei Dai <wei.dai@intel.com>
7 years agonet/ixgbe/base: add debug traces
Wei Dai [Thu, 12 Jan 2017 14:53:30 +0000 (22:53 +0800)]
net/ixgbe/base: add debug traces

Add some traces in the reset_hw logic and semaphore acquisition logic
to help debugging.

Signed-off-by: Wei Dai <wei.dai@intel.com>
7 years agonet/ixgbe/base: use clause 22 MDIO functions for Marvell PHYs
Wei Dai [Thu, 12 Jan 2017 14:53:29 +0000 (22:53 +0800)]
net/ixgbe/base: use clause 22 MDIO functions for Marvell PHYs

Set the MDIO (Management Data Input/Output Interface) read/write
function pointers for Marvell PHYs on some X550 platforms to use
the clause 22 functions. Marvell PHYs do not support clause 45.

Signed-off-by: Wei Dai <wei.dai@intel.com>
7 years agonet/ixgbe/base: support Marvell 1000BASE-T PHYs
Wei Dai [Thu, 12 Jan 2017 14:53:28 +0000 (22:53 +0800)]
net/ixgbe/base: support Marvell 1000BASE-T PHYs

Add initial support for Marvell 1000BASE-T PHYs on some X550 platforms.

Firmware owns the link config for Marvell PHYs on these platforms,
software should not touch it.

Also these platforms are not capable of speeds lower than 1Gb.

Signed-off-by: Wei Dai <wei.dai@intel.com>
7 years agonet/ixgbe/base: configure speeds for KR/KX backplane
Wei Dai [Thu, 12 Jan 2017 14:53:27 +0000 (22:53 +0800)]
net/ixgbe/base: configure speeds for KR/KX backplane

Ensure that the advertised link speeds are configured for KR/KX
backplane on some new platform.

Without this patch the link remains at 1G when resuming from low power
after being downshifted by LPLU (Low Power Link Up).

This patch ensures that the advertised speeds are not changed for
2.5G configurations.

Signed-off-by: Wei Dai <wei.dai@intel.com>
7 years agonet/ixgbe/base: remove a compiler warning
Wei Dai [Thu, 12 Jan 2017 14:53:26 +0000 (22:53 +0800)]
net/ixgbe/base: remove a compiler warning

Remove warning for "mac->led_link_act = i" where led_link_act is u8.

Signed-off-by: Wei Dai <wei.dai@intel.com>
7 years agonet/ixgbe/base: support XFI backplane for X550
Wei Dai [Thu, 12 Jan 2017 14:53:25 +0000 (22:53 +0800)]
net/ixgbe/base: support XFI backplane for X550

Add initial support for a XFI backplane interface on some new platforms.

The XFI backplane requires a custom tuned link. Hardware/Firmware owns
the link config for XF backplane and software must not interfere.

Signed-off-by: Wei Dai <wei.dai@intel.com>
7 years agonet/ixgbe: fix API parameter checking
Bernard Iremonger [Wed, 11 Jan 2017 17:24:59 +0000 (17:24 +0000)]
net/ixgbe: fix API parameter checking

Add checks to rte_pmd_ixgbe_* API's to ensure that the port
is an ixgbe port.

Fixes: 49e248223e9f ("net/ixgbe: add API for VF management")

Signed-off-by: Bernard Iremonger <bernard.iremonger@intel.com>
Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>
7 years agonet/enic: remove unnecessary function parameter attributes
John Daley [Wed, 11 Jan 2017 03:42:12 +0000 (19:42 -0800)]
net/enic: remove unnecessary function parameter attributes

Remove __rte_unused attributes in function declaration when
the parameters really are used.

Fixes: dfbd6a9cb504 ("net/enic: extend flow director support for 1300 series")

Signed-off-by: John Daley <johndale@cisco.com>
7 years agonet/enic: use new Rx checksum flags
John Daley [Wed, 11 Jan 2017 03:42:11 +0000 (19:42 -0800)]
net/enic: use new Rx checksum flags

Use the new L3 and L4 ..CKSUM_GOOD  and ..CKSUM_UNKNOWN flags to
distinguish good checksums from unknown ones.

Signed-off-by: John Daley <johndale@cisco.com>
7 years agonet/i40e: improve message grep-ability
Michał Mirosław [Wed, 11 Jan 2017 17:13:49 +0000 (18:13 +0100)]
net/i40e: improve message grep-ability

Join message lines for easier grepping.
PRIxXX are left glued to strings as they are in other parts of the file.

Signed-off-by: Michał Mirosław <michal.miroslaw@atendesoftware.pl>
Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>
7 years agonet/i40e: return errno when interrupt setup fails
Michał Mirosław [Tue, 13 Dec 2016 01:08:19 +0000 (02:08 +0100)]
net/i40e: return errno when interrupt setup fails

Signed-off-by: Michał Mirosław <michal.miroslaw@atendesoftware.pl>
Reviewed-by: Jingjing Wu <jingjing.wu@intel.com>
7 years agonet/enic: support TSO
John Daley [Mon, 9 Jan 2017 23:04:28 +0000 (15:04 -0800)]
net/enic: support TSO

The enic TSO implementation requires that the length of the Eth/IP/TCP
headers be passed to the NIC. Other than that, it's just a matter of
setting the mss and offload mode on a per packet basis.

In TSO mode, IP and TCP checksums are offloaded even if not requested
with mb->ol_flags.

Signed-off-by: John Daley <johndale@cisco.com>
7 years agonet/ixgbe: fix VMDq function name
Wenzhuo Lu [Tue, 10 Jan 2017 02:19:11 +0000 (10:19 +0800)]
net/ixgbe: fix VMDq function name

The function name ixgbe_vmdq_mode_check is not right.
This function checks if Virtualization Technology is
enabled. It's for both VMDq and IOV.
Others may be misled by the current name.

Fixes: fe3a45fd4104 ("ixgbe: add VMDq support")

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Acked-by: Bernard Iremonger <bernard.iremonger@intel.com>