Commit Graph

442 Commits

Author SHA1 Message Date
Adrien Mazarguil
2e22920b85 mlx5: support non-scattered Tx and Rx
RSS implementation with parent/child QPs comes from mlx4 and is temporary.

Signed-off-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
Signed-off-by: Nelio Laranjeiro <nelio.laranjeiro@6wind.com>
2015-10-30 22:21:07 +01:00
Adrien Mazarguil
771fa900b7 mlx5: introduce new driver for Mellanox ConnectX-4 adapters
In its current state, this driver implements the bare minimum to initialize
itself and Mellanox ConnectX-4 adapters without doing anything else
(no RX/TX for instance). It is disabled by default since it is based on the
mlx4 driver and also depends on libibverbs.

Signed-off-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
Signed-off-by: Nelio Laranjeiro <nelio.laranjeiro@6wind.com>
Signed-off-by: Or Ami <ora@mellanox.com>
2015-10-30 22:03:42 +01:00
John Daley
d739ba4c6a enic: improve Tx packet rate
For every packet sent, a completion was being requested and the
posted_index register on the nic was being updated. Instead, request a
completion and update the posted index once per burst after all
packets have been sent by the burst function.

Signed-off-by: John Daley <johndale@cisco.com>
Acked-by: Sujith Sankar <ssujith@cisco.com>
2015-10-30 18:34:37 +01:00
Bernard Iremonger
4009b369e7 xenvirt: free queues when closing
Signed-off-by: Bernard Iremonger <bernard.iremonger@intel.com>
Acked-by: Huawei Xie <huawei.xie@intel.com>
2015-10-30 17:57:04 +01:00
Bernard Iremonger
5ad78a66c1 xenvirt: support port hotplug
Signed-off-by: Bernard Iremonger <bernard.iremonger@intel.com>
Acked-by: Huawei Xie <huawei.xie@intel.com>
2015-10-30 17:52:50 +01:00
Zhe Tao
8e109464c0 i40e: allow vector Rx and Tx usage
To support FVL PMD can select which RX and TX function should be used
according to the queue config.

Signed-off-by: Zhe Tao <zhe.tao@intel.com>
Acked-by: Cunming Liang <cunming.liang@intel.com>
2015-10-30 17:00:37 +01:00
Zhe Tao
0e0da28cd8 i40e: add vector scatter Rx
To support the multiple segments in one packets when the received pkts exceed
 one buffer size.

Signed-off-by: Zhe Tao <zhe.tao@intel.com>
Acked-by: Cunming Liang <cunming.liang@intel.com>
2015-10-30 16:50:27 +01:00
Zhe Tao
b4669bb950 i40e: add vector Tx
The way to increase the performance of the vPMD TX is to use some fast mbuf
release method compares to the scalar TX.

Signed-off-by: Zhe Tao <zhe.tao@intel.com>
Acked-by: Cunming Liang <cunming.liang@intel.com>
2015-10-30 16:50:14 +01:00
Zhe Tao
9ed94e5bb0 i40e: add vector Rx
The vPMD RX function uses the multi-buffer and SSE instructions to
accelerate the RX speed, but now the pktype cannot be supported by the vPMD RX,
because it will decrease the performance heavily.

Signed-off-by: Zhe Tao <zhe.tao@intel.com>
Acked-by: Cunming Liang <cunming.liang@intel.com>
2015-10-30 16:49:30 +01:00
Zhe Tao
f53577f069 i40e: support flow control
Feature Add: Rx/Tx flow control support for the i40e

All the Rx/Tx LFC enable/disable operation is done by the F/W,
so PMD driver need to use the Set PHY Config AD command to trigger the PHY
to do the auto-negotiation, after the Tx/Rx pause ability is negotiated,
the F/W will help us to set the related LFC enable/disable registers.
PMD driver also need to configure the related registers to control
how often to send the pause frame and what the value in the pause frame.

Signed-off-by: Zhe Tao <zhe.tao@intel.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
2015-10-30 15:21:38 +01:00
Jingjing Wu
92e689cedb i40evf: fix write back with virtual channel 1.1
If DPDK is used on VF while the host is using Linux Kernel driver
as PF driver on FVL NIC, then VF Rx is reported only in batches of
4 packets. It is due to the kernel driver assumes VF driver is working
in interrupt mode, but DPDK VF is working in Polling mode.
This patch fixes this issue by using the V1.1 virtual channel with
Linux i40e PF driver.

Signed-off-by: Jingjing Wu <jingjing.wu@intel.com>
Acked-by: Cunming Liang <cunming.liang@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
2015-10-30 12:31:29 +01:00
Jingjing Wu
909119cd4d i40e: drop flow control frames from VF
This patch adds a workaround to drop flow control frames from being
transmitted from VSIs.
With this patch in place a malicious VF cannot send flow control or PFC
packets out on the wire.

Signed-off-by: Jingjing Wu <jingjing.wu@intel.com>
Acked-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
2015-10-30 12:22:49 +01:00
Michael Qiu
6bbf8c8f4d fm10k: support Boulder Rapid device
Boulder Rapid is Intel new NIC within fm10k family.
This patch make DPDK driver support this new NIC.

Signed-off-by: Michael Qiu <michael.qiu@intel.com>
Acked-by: Jing Chen <jing.d.chen@intel.com>
Acked-by: Shaopeng He <shaopeng.he@intel.com>
2015-10-29 23:47:44 +01:00
Wang Xiao W
d9623c4fa0 fm10k: enable TSO support
This patch enables fm10k TSO feature for both non-tunneling packet
and tunneling packet.

Signed-off-by: Wang Xiao W <xiao.w.wang@intel.com>
Acked-by: Michael Qiu <michael.qiu@intel.com>
2015-10-29 23:47:44 +01:00
Yong Liu
921a72008f e1000: add Rx interrupt handler
When datapath rxq interrupt is enabled, enable related device rxq.
Remove the interrupt handler after device stopped.
e1000 only support one type of interrupt cause, so remove lsc interrupt
handler if rxq enabled.

Signed-off-by: Marvin Liu <yong.liu@intel.com>
Acked-by: Cunming Liang <cunming.liang@intel.com>
2015-10-29 19:08:38 +01:00
Yong Liu
dcfd32cfa2 e1000: support Rx interrupt setup
Enable rx interrupt support on e1000 physical and emulated device.
Implement rxq interrupt related functions in eth_dev_ops structure.

Signed-off-by: Marvin Liu <yong.liu@intel.com>
Acked-by: Cunming Liang <cunming.liang@intel.com>
2015-10-29 19:08:25 +01:00
Yong Liu
72d9269cd8 e1000: separate link and Rx interrupt disabling
Separate lsc and rxq interrupt for they have different interrupt handlers.

Signed-off-by: Marvin Liu <yong.liu@intel.com>
Acked-by: Cunming Liang <cunming.liang@intel.com>
2015-10-29 18:57:12 +01:00
Yong Liu
667b9313f9 e1000: restrict link interrupt setup scope
Only mask lsc interrupt bit when setup device interrupt.

Signed-off-by: Marvin Liu <yong.liu@intel.com>
Acked-by: Cunming Liang <cunming.liang@intel.com>
2015-10-29 18:55:07 +01:00
Wenzhuo Lu
82fb702077 ixgbe: support new flow director modes for X550
Implement the new CLIs for fdir mac vlan and tunnel modes, including
flow_director_filter and flow_director_mask. Set the mask of fdir.
Add, delete or update the entities of filter.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Acked-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
2015-10-29 00:06:01 +01:00
Harry van Haaren
f38770578f igb: fix build without ieee1588 enabled
This patch marks rxq with RTE_SET_USED in
rx_desc_hlen_type_rss_to_pkt_flags(), when
ieee1588 is disabled. Previously a compilation
error occurred on unused-parameter.

Fixes: 1ce6591e23 ("igb: fix ieee1588 frame identification in i210")

Signed-off-by: Harry van Haaren <harry.van.haaren@intel.com>
Acked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
2015-10-28 18:30:05 +01:00
Wenzhuo Lu
35ffb4ff14 ixgbevf: support RSS reta/hash query and update
This patch implements the VF RSS reta/hash query and update function
on 10G NICs. But the update function is only provided for x550. Because
the other NICs don't have the separate registers for VF, we don't want
to let a VF NIC change the shared RSS reta/hash registers. It may cause
PF and other VF NICs' behavior change without being noticed.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Acked-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
2015-10-28 18:30:05 +01:00
Wenzhuo Lu
f4d1598ee1 ixgbevf: support RSS config on x550
On x550, there're separate registers provided for VF RSS while on the other
10G NICs, for example, 82599, VF and PF share the same registers.
This patch lets x550 use the VF specific registers when doing RSS configuration
on VF. The behavior of other 10G NICs doesn't change.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Acked-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
2015-10-28 18:30:05 +01:00
Wenzhuo Lu
4bee94a6c2 ixgbe: support 512 RSS entries on x550
Comparing with the older NICs, x550's RSS redirection table is enlarged to 512
entries. As the original code is for the NICs which have a 128 entries RSS table,
it means only part of the RSS table is set on x550. So, RSS cannot work as
expected on x550, it doesn't redirect the packets evenly.
This patch configs the entries beyond 128 on x550 to let RSS work well, and also
update the query and update functions to support 512 entries.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Acked-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
2015-10-28 18:30:00 +01:00
Wenzhuo Lu
988f1d00a6 ixgbe: drop flow control frames from VF
This patch will drop flow control frames from being transmitted
from VSIs.
With this patch in place a malicious VF cannot send flow control
or PFC packets out on the wire.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Acked-by: Helin Zhang <helin.zhang@intel.com>
2015-10-28 17:41:27 +01:00
Zoltan Kiss
3cbf01c0c0 ixgbe: prefetch cacheline after pointer becomes valid
At the original point the rx_pkts[pos( + n)] pointers are not initialized,
so the code is prefetching random data.

Signed-off-by: Zoltan Kiss <zoltan.kiss@linaro.org>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
2015-10-28 17:19:25 +01:00
Remy Horton
6fc6a0915d ixgbe: fix access to last byte of EEPROM
Incorrect operator in ixgbe_get_eeprom & ixgbe_set_eeprom prevents
last byte of EEPROM being read/written, and hence cannot be dumped
or updated in entirity using these functions.

Fixes: 0198848a47 ("ixgbe: add access to specific device info")

Signed-off-by: Remy Horton <remy.horton@intel.com>
Acked-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
2015-10-28 17:14:41 +01:00
Harry van Haaren
e81a315e5d ixgbe: add MAC short packet discard count to Rx errors
This patch adds the mspdc (MAC Short Packet Discard Count)
to the total rx errors, as discussed on the dev@dpdk mailing
list: http://comments.gmane.org/gmane.comp.networking.dpdk.devel/23717

Suggested-by: Igor Ryzhov <iryzhov@arccn.ru>
Signed-off-by: Harry van Haaren <harry.van.haaren@intel.com>
Acked-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
2015-10-28 15:50:04 +01:00
Harry van Haaren
dc58e8c568 ixgbe: remove jabber count from Rx errors
Remove receive jabber count (rjc) from ierrors count as the
register overlaps with the CRC error register, previously
causing some packets to be counted twice.

Signed-off-by: Harry van Haaren <harry.van.haaren@intel.com>
Acked-by: Maryam Tahhan <maryam.tahhan@intel.com>
Acked-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
2015-10-28 15:49:56 +01:00
Harry van Haaren
75e7eb4a01 ixgbe: fix statistics for 82598/82599 differences
Ixgbe based 82598 and 82599 have different priority receive link-on
register addresses. This is solved in base/ by providing in the
PXONRXC and PXONXCNT as separate macros. This patch ensures the
correct address is read, avoiding reading garbage values.

Also PXON2OFFCNT doesn't exist in 82598, so it is not read for
that MAC.

This issue has existed since the drivers were imported into DPDK,
but was not easily discoverable as xstats were not available.
Tested using testpmd> show port xstats all

Fixes: af75078fec ("first public release")

Signed-off-by: Harry van Haaren <harry.van.haaren@intel.com>
Acked-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
2015-10-28 15:02:01 +01:00
Wenzhuo Lu
77770b3401 ixgbevf: fix TSO support
When setting TSO on VF ixgbe NICs, for example, 82599, x550, the
prompt that TSO is not supported will be printed. But TSO is
supported by VF ixgbe NICs.
We should add TSO to the capability flag, so, we will not see the
wrong prompt.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
2015-10-28 14:41:12 +01:00
Harry van Haaren
00b7ca600c ixgbevf: fix statistic wraparound
Fix a misinterpretation of VF stats in ixgbe

Signed-off-by: Harry van Haaren <harry.van.haaren@intel.com>
Acked-by: Roger Melton <rmelton@cisco.com>
2015-10-28 14:41:11 +01:00
Harry van Haaren
795618c0aa igbvf: fix statistic wraparound
Fix a misinterpreatation of VF statistic macro in e1000/igb.

Signed-off-by: Harry van Haaren <harry.van.haaren@intel.com>
Acked-by: Roger Melton <rmelton@cisco.com>
2015-10-28 14:41:11 +01:00
Pablo de Lara
1ce6591e23 igb: fix ieee1588 frame identification in i210
Fixed issue where the flag PKT_RX_IEEE1588_PTP was not being set
in Intel I210 NIC, as EtherType in RX descriptor is in bits 8:10 of
Packet Type and not in the default bits 0:2.

Fixes known issue "IEEE1588 support possibly not working
with an Intel Ethernet Controller I210 NIC"

Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Acked-by: John McNamara <john.mcnamara@intel.com>
Acked-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
2015-10-28 14:41:11 +01:00
Wang Xiao W
4c8db5f09a igb: enable TSO support
This patch enables igb TSO feature, the feature works on both PF and VF.
The TCP segmentation offload needs to write the offload related information
into the advanced context descriptors, which is similar to checksum offload.

Signed-off-by: Wang Xiao W <xiao.w.wang@intel.com>
Acked-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
2015-10-27 19:28:06 +01:00
Harry van Haaren
67b38d93c9 e1000: fix total byte statistics
This patch fixes a bug in reading the 64 bit register reading
which was causing the total octets counters to show zero.
Now the code reads both the lower and higher 32 bits.
Tested in testpmd, byte values are correct.

Fixes: 805803445a ("e1000: support EM devices (also known as e1000/e1000e)")

Signed-off-by: Harry van Haaren <harry.van.haaren@intel.com>
Acked-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
2015-10-27 18:39:44 +01:00
Wenzhuo Lu
d5f46be3d5 e1000/base: minor changes
Some minor code change. No functionality impact.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
2015-10-27 16:20:37 +01:00
Wenzhuo Lu
b496406489 e1000/base: allow both ULP and EEE in Sx state
This patch implements a modified flow that allows both ULP and EEE
in Sx (Sticky mode).

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
2015-10-27 16:20:37 +01:00
Wenzhuo Lu
ed8ebafe98 e1000/base: synchronize PHY interface on non-ME systems
On power up, the MAC - PHY interface needs to be set to PCIe, even if
cable is disconnected.  In ME systems, the ME handles this on exit from
Sx(Sticky mode) state. In non-ME, the driver handles it. Added a check
for non-ME system to the driver code that handles that.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
2015-10-27 16:20:37 +01:00
Wenzhuo Lu
6e0ca097b5 e1000/base: increase timeout of reset check
Previously, in check_reset_block RSPCIPHY was polled for 100 ms before determining
that the ME veto is set. This needed to be increased to 300 ms.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
2015-10-27 16:12:57 +01:00
Wenzhuo Lu
53c2e4a19e e1000/base: initialize 88E1543 PHY
The initialization process for 88E1543 PHY.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
2015-10-27 16:12:57 +01:00
Wenzhuo Lu
c35be7b211 e1000/base: disable IPv6 extension header parsing
All 1G Server products need to have IPv6 extension headers turned off.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
2015-10-27 16:12:57 +01:00
Wenzhuo Lu
4bff263d54 e1000/base: prevent ULP flow if cable connected
Enabling ulp on link down when cable is connect caused an infinite
loop of linkup/down indications in the NDIS driver.
After discussed, correct flow is to enable ULP only when cable is
disconnected.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
2015-10-27 16:12:57 +01:00
Wenzhuo Lu
24a9b538ad e1000/base: add flags to set EEE advertisement modes
Requires driver changes!

Change e1000_set_eee_i350 and e1000_set_eee_i354 to have flags allowing
changes in the advertised EEE speeds.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
2015-10-27 16:12:57 +01:00
Wenzhuo Lu
849651f863 e1000/base: support inverted format ETrackId
There are some images which contain ETrackID in inverted format. This patch
allows reading this format.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
2015-10-27 16:12:57 +01:00
Wenzhuo Lu
5b6439cf03 e1000/base: support different EEARBC for i210
EEARBC has changed on i210. It means EEARBC has a different address on
i210 than on other NICs. So, add a new entity named EEARBC_I210 to the
register list and make sure the right one is being used on i210.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
2015-10-27 16:12:57 +01:00
Wenzhuo Lu
75a7f9cfdd e1000/base: add bit to disable packetbuffer read
Added bit FEXTNVM7[18], that controls disabling MAC packet buffer read.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
2015-10-27 16:12:57 +01:00
Wenzhuo Lu
9fa668f29b e1000/base: add defaults for i210 Rx/Tx PBSIZE
These are the defaults for the packet buffer size registers that need to
be explicitly set back if someone changes them and comes back to a normal
driver.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
2015-10-27 16:12:57 +01:00
Wenzhuo Lu
6f934fa24d e1000/base: fix K1 configuration
This patch is for the following updates to the K1 configurations:
Tx idle period for entering K1 should be 128 ns.
Minimum Tx idle period in K1 should be 256 ns.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
2015-10-27 16:12:56 +01:00
Wenzhuo Lu
923efe61c3 e1000/base: fix link detect flow
In case that auto-negotiate is not enabled, call
e1000_setup_copper_link_generic instead of e1000_phy_setup_autoneg.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
2015-10-27 16:12:56 +01:00
Wenzhuo Lu
975ba6912f e1000/base: fix link check for i354 88E1112 PHY
e1000_check_for_link_media_swap() is supposed to check PHY page 0 for
copper and PHY page 1 for "other" (fiber) link. We switched back from
page 1 to page 0 too soon, before e1000_check_for_link_82575() is
executed and we were never finding link on fiber (other).

Note: The precedence of link type is controlled by the PHY settings.

If the link is copper, as the M88E1112 page address is set to 1, it should be
set back to 0 before checking this link.

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
2015-10-27 16:12:56 +01:00