This patch introduces RTE_CRYPTODEV_FF_MBUF_SCATTER_GATHER feature flag
informing that selected crypto device supports segmented mbufs natively
and doesn't need to be coalesced before crypto operation.
While using segmented buffers in crypto devices may have unpredictable
results, for PMDs which doesn't support it natively, additional check is
made for debug compilation.
Signed-off-by: Tomasz Kulasek <tomaszx.kulasek@intel.com>
Acked-by: Declan Doherty <declan.doherty@intel.com>
EVP_CIPHER_CTX_set_padding() function always returns 1, so the check is
unneeded.
Fixes: d61f70b4c9 ("crypto/libcrypto: add driver for OpenSSL library")
Signed-off-by: Piotr Azarewicz <piotrx.t.azarewicz@intel.com>
Tested-by: Zhaoyan Chen <zhaoyan.chen@intel.com>
Acked-by: Declan Doherty <declan.doherty@intel.com>
This patch sets iv size in qat PMD to 12 bytes to be
conformant with nist SP800-38D.
Fixes: 26c2e4ad5a ("cryptodev: add capabilities discovery")
Signed-off-by: Arek Kusztal <arkadiuszx.kusztal@intel.com>
Acked-by: Fiona Trahe <fiona.trahe@intel.com>
This patch sets iv size in aesni gcm PMD to 12 bytes to be
conformant with nist SP800-38D.
Fixes: eec136f3c5 ("aesni_gcm: add driver for AES-GCM crypto operations")
Signed-off-by: Arek Kusztal <arkadiuszx.kusztal@intel.com>
Acked-by: Piotr Azarewicz <piotrx.t.azarewicz@intel.com>
This commit fixes pre-counter block (J0) padding by clearing
four most significant bytes before setting initial counter value.
Fixes: b2bb359747 ("crypto/aesni_gcm: move pre-counter block to driver")
Signed-off-by: Arek Kusztal <arkadiuszx.kusztal@intel.com>
Acked-by: Piotr Azarewicz <piotrx.t.azarewicz@intel.com>
Release v0.44 of Intel(R) Multi-Buffer Crypto for IPsec library adds
support for AVX512 instructions. This patch enables the new AVX512
accelerated functions from the aesni_mb_pmd crypto poll mode driver.
This patch set requires that the aesni_mb_pmd is linked against the
version 0.44 or greater of the Multi-Buffer Crypto for IPsec library.
Signed-off-by: Declan Doherty <declan.doherty@intel.com>
Acked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Update driver to use new AESNI Multibuffer IPSec library single
operation functionality (cipher only and authentication only).
This patch also adds tests for this new feature.
Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Acked-by: Declan Doherty <declan.doherty@intel.com>
When using sessionless crypto operations, crypto session
is obtained from a pool of sessions, when processing the
operation. Once the operation is processed, the session
is put back in the pool, but for the AESNI MB PMD, this
session was not being saved in the operation and therefore,
it did not return to the session pool.
Fixes: 924e84f873 ("aesni_mb: add driver for multi buffer based crypto")
Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Acked-by: Declan Doherty <declan.doherty@intel.com>
Extra bytes are being written at end of data while process standard
openssl cipher encryption. This behaviour is unexpected.
This patch disable the padding feature in openssl library, which is
causing the problem.
Fixes: d61f70b4c9 ("crypto/libcrypto: add driver for OpenSSL library")
Signed-off-by: Piotr Azarewicz <piotrx.t.azarewicz@intel.com>
Acked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
In out-of-place operation, data is DMAed from source mbuf
to destination mbuf. To avoid header data in dest mbuf being
overwritten, the minimal data-set should be DMAed.
Fixes: 39e0bee48e ("crypto/qat: rework request builder for performance")
Signed-off-by: Fiona Trahe <fiona.trahe@intel.com>
Acked-by: John Griffin <john.griffin@intel.com>
The cryptodev API had specified that if the digest address field was
left empty on an authentication operation, then the PMD would assume
the digest was appended to the source or destination data.
This case was not handled at all by most PMDs and incorrectly handled
by the QAT PMD.
As no bugs were raised, it is assumed to be not needed, so this patch
removes it, rather than add handling for the case on all PMDs.
The digest can still be appended to the data, but its
address must now be provided in the op.
Signed-off-by: Fiona Trahe <fiona.trahe@intel.com>
Acked-by: John Griffin <john.griffin@intel.com>
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 Griffin <john.griffin@intel.com>
CC: Fiona Trahe <fiona.trahe@intel.com>
CC: Deepak Kumar Jain <deepak.k.jain@intel.com>
Signed-off-by: Santosh Shukla <santosh.shukla@caviumnetworks.com>
Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
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: Yong Wang <yongwang@vmware.com>
Signed-off-by: Santosh Shukla <santosh.shukla@caviumnetworks.com>
Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
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.
Signed-off-by: Santosh Shukla <santosh.shukla@caviumnetworks.com>
Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
Acked-by: Yuanhan Liu <yuanhan.liu@linux.intel.com>
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.
Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
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.
Suggested-by: Jan Medala <jan@semihalf.com>
Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
Acked-by: Jan Medala <jan@semihalf.com>
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>
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: Stephen Hurd <stephen.hurd@broadcom.com>
CC: Ajit Khaparde <ajit.khaparde@broadcom.com>
Signed-off-by: Santosh Shukla <santosh.shukla@caviumnetworks.com>
Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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: 89e6b86384 ("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>
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>
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>
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: 4861cde461 ("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>
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>
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>
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>
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>
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>
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>
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>
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: 429df3803a ("mlx4: replace some offload flags with packet type")
Fixes: 67fa62bc67 ("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>
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>
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>
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>
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>
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>
clang reports this error message:
error: this function declaration is not a prototype
[-Werror,-Wstrict-prototypes]
Fixes: 5cdd769a26 ("qede: add L2 support")
Signed-off-by: Emmanuel Roullit <emmanuel.roullit@gmail.com>
Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>
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: 92c8a63223 ("cxgbe: add device configuration and Rx support")
Signed-off-by: Emmanuel Roullit <emmanuel.roullit@gmail.com>
Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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: d4a27a3b09 ("nfp: add basic features")
Signed-off-by: Olivier Matz <olivier.matz@6wind.com>
Acked-by: Alejandro Lucero <alejandro.lucero@netronome.com>
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>
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>
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>
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>
Add checks to rte_pmd_ixgbe_* API's to ensure that the port
is an ixgbe port.
Fixes: 49e248223e ("net/ixgbe: add API for VF management")
Signed-off-by: Bernard Iremonger <bernard.iremonger@intel.com>
Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>
Remove __rte_unused attributes in function declaration when
the parameters really are used.
Fixes: dfbd6a9cb5 ("net/enic: extend flow director support for 1300 series")
Signed-off-by: John Daley <johndale@cisco.com>
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>
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>
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>
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: fe3a45fd41 ("ixgbe: add VMDq support")
Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Acked-by: Bernard Iremonger <bernard.iremonger@intel.com>
In function "reassemble_packets()", the statement "end = secondlast;"
is redundant since there is another assignment "start = end = NULL;"
3 lines below. BTW, I removed the redundant braces in the conditional
statement "if (end->data_len > rxq->crc_len)".
Signed-off-by: Yong Wang <wang.yong19@zte.com.cn>
Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>
When freeing up last mbuf, start->nb_segs should be decremented
by one. See also ixgbe process.
Fixes: 0e0da28cd8 ("i40e: add vector scatter Rx")
Signed-off-by: Chenghu Yao <yao.chenghu@zte.com.cn>
Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>
When using the same file descriptor for both rx and tx, the
eth_dev_stop function would close the same fd twice. This
change prevents that from happening.
Fixes: 364e08f2bb ("af_packet: add PMD for AF_PACKET-based virtual devices")
Signed-off-by: Timmons C. Player <timmons.player@spirent.com>
Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>
Add support for PCI IDs which was removed as a part of
commit 0e7bd0b2d6 ("net/bnxt: remove support for few devices")
Signed-off-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
The only reason why bulk alloc disabled for the rings with
more than (IXGBE_MAX_RING_DESC - RTE_PMD_IXGBE_RX_MAX_BURST)
descriptors is the possible out-of-bound access to the dma
memory. But it's the artificial limit and can be easily
avoided by allocating of RTE_PMD_IXGBE_RX_MAX_BURST more
descriptors in memory. This will not interfere the HW and,
as soon as all rings' memory zeroized, Rx functions will
work correctly.
This change allows to use vectorized Rx functions with
4096 descriptors in Rx ring which is important to achieve
zero packet drop rate in high-load installations.
Signed-off-by: Ilya Maximets <i.maximets@samsung.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
The only reason why bulk alloc disabled for the rings with
more than (I40E_MAX_RING_DESC - RTE_PMD_I40E_RX_MAX_BURST)
descriptors is the possible out-of-bound access to the dma
memory. But it's the artificial limit and can be easily
avoided by allocating of RTE_PMD_I40E_RX_MAX_BURST more
descriptors in memory. This will not interfere the HW and,
as soon as all rings' memory zeroized, Rx functions will
work correctly.
This change allows to use vectorized Rx functions with
4096 descriptors in Rx ring which is important to achieve
zero packet drop rate in high-load installations.
Signed-off-by: Ilya Maximets <i.maximets@samsung.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
Add PCI device ID for ConnectX-5 and enable multi-packet send for PF and VF
along with changing documentation and release note.
Signed-off-by: Yongseok Koh <yskoh@mellanox.com>
Acked-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
If value of number of rxq/txq is different than
RTE_ETHDEV_QUEUE_STAT_CNTRS, limit per queue
stats/xstats to minimum of the two.
Fixes: 7634c5f915 ("net/qede: add queue statistics")
Signed-off-by: Rasesh Mody <rasesh.mody@cavium.com>
Allocate double the number of fastpath status block index
since the PF RX/TX queues are not sharing the status block.
This is an interim solution till other parts of the code
is modified to handle the same.
Fixes: f1e4b6c0ac ("net/qede: fix status block index for VF queues")
Signed-off-by: Harish Patil <harish.patil@qlogic.com>
- Fix minimum RX buffer size to 1024B
- Force enable scatter/gather mode if given RX buf size is lesser than MTU
- Adjust RX buffer size to cache-line size with overhead included
Fixes: bec0228816 ("net/qede: support scatter gather")
Fixes: 2ea6f76aff ("qede: add core driver")
Signed-off-by: Harish Patil <harish.patil@qlogic.com>
This patch adds i40e_flow_flush_tunnel_filter
function to flush all tunnel filters, including
filters in SW and HW.
Signed-off-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
This patch adds i40e_flow_flush_ethertype_filter
function to flush all ethertype filters, including
filters in SW and HW.
Signed-off-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
This patch adds i40e_flow_flush function to flush all
filters for users. And flow director flush function
is involved first.
Signed-off-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
This patch adds i40e_flow_destroy_tunnel_filter
function to destroy a tunnel filter for users.
Signed-off-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
This patch adds i40e_flow_destroy_ethertype_filter
function to destroy a ethertype filter for users.
Signed-off-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
This patch adds i40e_flow_destroy function to destroy
a flow for users.
Signed-off-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
This patch adds i40e_flow_create function to create a
rule. It will check if a flow matches ethertype filter
or flow director filter or tunnel filter, if the flow
matches some kind of filter, then set the filter to HW.
Signed-off-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
This patch adds i40e_flow_parse_tunnel_filter to check
if a rule is a tunnel rule according to items of the
flow pattern, and the function also gets the tunnel info.
Signed-off-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
This patch adds i40e_flow_parse_fdir_filter to check
if a rule is a flow director rule according to the
flow pattern, and the function also gets the flow
director info.
Signed-off-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
This patch adds i40e_flow_validation function to check if
a flow is valid according to the flow pattern.
i40e_flow_parse_ethertype_filter is added first, it also
gets the ethertype info.
i40e_flow.c is added to handle all generic filter events.
Signed-off-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
Add support of restoring ethertype filter in case filter
dropped accidentally, as all filters need to be added and
removed by user obviously for generic filter API.
Signed-off-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
Currently there's no flow director filter stored in SW. This
patch stores flow director filters in SW with cuckoo hash,
also adds protection if a flow director filter has been added.
Signed-off-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
Currently there's no tunnel filter stored in SW.
This patch stores tunnel filter in SW with cuckoo
hash, also adds protection if a tunnel filter has
been added.
Signed-off-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
Currently there's no ethertype filter stored in SW.
This patch stores ethertype filter with cuckoo hash
in SW, also adds protection if an ethertype filter
has been added.
Signed-off-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Jingjing Wu <jingjing.wu@intel.com>
Dseg pointer is not initialized when the first segment is inlined
causing a segmentation fault in such situation.
Fixes: 2a66cf3789 ("net/mlx5: support inline send")
Signed-off-by: Shahaf Shuler <shahafs@mellanox.com>
Acked-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
Too much data is uselessly written to the Tx doorbell, which since v16.11
may also cause Tx queues to behave erratically and crash applications.
This regression was seen on VF devices when the BlueFlame buffer size is
zero (txq->bf_buf_size) due to the following change:
- txq->bf_offset ^= txq->bf_buf_size;
+ txq->bf_offset ^= (1 << txq->bf_buf_size);
Fixes: 1d88ba1719 ("net/mlx5: refactor Tx data path")
Fixes: d5793daefe ("net/mlx5: reduce memory overhead for BF handling")
Signed-off-by: Nelio Laranjeiro <nelio.laranjeiro@6wind.com>
Acked-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
Prefetching completion queue entries is inefficient because too few CPU
cycles are spent before their use, which results into cache misses anyway.
Signed-off-by: Nelio Laranjeiro <nelio.laranjeiro@6wind.com>
Acked-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
Use fewer instructions to copy the first two bytes of Ethernet headers to
work queue elements.
Signed-off-by: Nelio Laranjeiro <nelio.laranjeiro@6wind.com>
Acked-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
Gather function prototypes at the beginning of the file.
Signed-off-by: Nelio Laranjeiro <nelio.laranjeiro@6wind.com>
Acked-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
Let compiler automatically use the vector capabilities of the target
machine to optimize instructions.
Signed-off-by: Nelio Laranjeiro <nelio.laranjeiro@6wind.com>
Acked-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
Define a single work queue element type that encompasses them all. It
includes control, Ethernet segment and raw data all grouped in a single
place.
Signed-off-by: Nelio Laranjeiro <nelio.laranjeiro@6wind.com>
Acked-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
Prepare the code to write the Work Queue Element with vectorized
instructions.
Signed-off-by: Nelio Laranjeiro <nelio.laranjeiro@6wind.com>
Signed-off-by: Elad Persiko <eladpe@mellanox.com>
Acked-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
This patch includes changes for DCBX like:
- Return empty parameters for oper-params query when negotiation is not
complete
- Use the ieee specific mask value for reading the ethtype value in the
ieee dcbx mode
- Endian-ness conversion is not needed for priority<->TC field, as the
data is already being read/written by ecore in the bigendian way
- While writing the ets config, base driver incorrectly merges the input
values with the operational values. The values should be either set
or unset
- CEE selection field must be set regardless CEE/IEEE mode
- Fail the dcbx query for VF interfaces
- Semantic changes
Signed-off-by: Rasesh Mody <rasesh.mody@cavium.com>
Add support for 8.14.x.x firmware.
The new firmware adds support for external PHY BCM8485x; configures
fixed link speed with transceiver/cable not supporting negotiation;
supports engine swap; supports overriding PCIe preset equalization
value; checks pause too long for ports and reads die temperature
every second for shutdown threshold.
It includes change in FLR flow when there is a SW initiated FLR.
Signed-off-by: Rasesh Mody <rasesh.mody@cavium.com>
Add PCI IDs for new asic type (defined as CHIP_NUM_AH_xxx).
It supports 50G, 40G, 25G and 10G speeds.
Signed-off-by: Rasesh Mody <rasesh.mody@cavium.com>
As part of device probe, check if management FW crash dump logs are
available. If available, then log an warning message and update the
epoch value too. A new struct ecore_mdump_info is added to populate
dump info including the new "reason" field by reading shared memory
region.
Signed-off-by: Rasesh Mody <rasesh.mody@cavium.com>
Add new option called external PBL (page base list) to ecore_chain_alloc
for future use. Mark chain as external if external PBL is provided.
Signed-off-by: Rasesh Mody <rasesh.mody@cavium.com>
Add macros PTR_LO and PTR_HI (for converting pointer to HI and LOW bits for
passing to FW hsi handles).
Signed-off-by: Rasesh Mody <rasesh.mody@cavium.com>
In order to improve Tx switching performance an additional HSI parameter
called same-as-last-id is introduced. This resource allows FW caching the
txqs packet properties. Driver needs to set same-as-last-id to be equal to
the qzone.
Signed-off-by: Rasesh Mody <rasesh.mody@cavium.com>
Receive indication that VFs are malicious and pass it to the
caller/clients and stop serving those VF's additional resource requests.
Signed-off-by: Rasesh Mody <rasesh.mody@cavium.com>
Add a request for PF Function Level Reset (FLR) before a load request
Fix the location of the PF FLR initiation to be after ecore_get_hw_info()
(which invokes ecore_hw_info_port_num())
Signed-off-by: Rasesh Mody <rasesh.mody@cavium.com>
This commits adds:
- Type of service
- Next protocol ID
Signed-off-by: Nelio Laranjeiro <nelio.laranjeiro@6wind.com>
Acked-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
Introduce initial software for rte_flow rules.
VLAN, VXLAN are still not supported.
Signed-off-by: Nelio Laranjeiro <nelio.laranjeiro@6wind.com>
Acked-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
Previously the capability bitmap for Rx offloads was mistakenly taken
from Tx capability bitmap field. This patch fixes the problem.
Signed-off-by: Jakub Palider <jpa@semihalf.com>
This patch implements NFP PMD support for TSO but it also requires
a firmware advertising the capability.
Signed-off-by: Alejandro Lucero <alejandro.lucero@netronome.com>
When VF receives a message from PF, it should check the return
value. But in i40evf_execute_vf_cmd the value is ignored and not
returned to the caller.
Fixes: 95cd21f45d ("i40evf: allocate virtchnl commands buffer per VF")
Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Flows redirected to a specific queue do not have a valid RSS hash result
and the related mbuf flag must not be set.
Fixes: ecf60761fc ("net/mlx5: return RSS hash result in mbuf")
Signed-off-by: Nelio Laranjeiro <nelio.laranjeiro@6wind.com>
Acked-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
Removed unused "reg_info" global variable from ixgbe driver.
cat build/app/testpmd.map | grep "Allocating common symbols" -A 15
Allocating common symbols
Common symbol size file
reg_info 0x18 build/lib/librte_pmd_ixgbe.a(ixgbe_ethdev.o)
Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>
Having those modulo operations implies costly instructions execution,
what can be avoided with conditionals and unlikely clauses.
This change makes the software ring read and write indexes to be now
always within the ring size which has to be handled properly. The main
problem is when write pointer wraps and being less than the read pointer.
This happened before, but just with indexes type size (uint32_t) wrapping,
and in that case the processor does the right thing no requiring special
handling by software.
This work has also led to discovering redundant pointers in the driver,
which have been removed.
Signed-off-by: Alejandro Lucero <alejandro.lucero@netronome.com>
Apparently VF over Legacy PF doesn't work, as VF would fail after
getting the initial rejection message [instead of sending an additional
one where it asks for a FW override and see if it works].
Fixes: 22d07d939c ("net/qede/base: update")
Signed-off-by: Rasesh Mody <rasesh.mody@cavium.com>
Add a check and fail the VF's probe request if VF is already in
VF_ACQUIRED state.
Fixes: 22d07d939c ("net/qede/base: update")
Signed-off-by: Rasesh Mody <rasesh.mody@cavium.com>
Rx queue access is still done prior to the index being validated by PF.
Hence move Rx queue and status block validation check before accessing
Rx queue to prevent malicious VFs from using out-of-bound queue indices.
Fixes: 98bc693e19 ("net/qede/base: change queue start")
Signed-off-by: Rasesh Mody <rasesh.mody@cavium.com>
Fix to return error code ECORE_INVAL instead of 0 when EQ elements
is too large as done elsewhere in this function.
Fixes: 22d07d939c ("net/qede/base: update")
Signed-off-by: Rasesh Mody <rasesh.mody@cavium.com>
There are certain conditions under which VF would infinitely send
ACQUIRE messages, as it will fail to understand that PF has rejected
the ACQUIRE request. Fix to reject multiple acquisition requests by VF.
Fixes: 22d07d939c ("net/qede/base: update")
Signed-off-by: Rasesh Mody <rasesh.mody@cavium.com>
Remove unmeaningful function ID value in print.
Don't print the number of Multicast filters as part of Acquire response,
as this is an obsolete field which isn't enforced by PF.
Fixes: 86a2265e59 ("qede: add SRIOV support")
Signed-off-by: Rasesh Mody <rasesh.mody@cavium.com>
The vendor_id and device_id are used to determine device type. If you
don't have them, then check for determining device type fails and is
always set to default device type.
Fixes: ec94dbc573 ("qede: add base driver")
Signed-off-by: Rasesh Mody <rasesh.mody@cavium.com>
HW can support up to 128 queues based on the NIC config/personality.
But most of the testing is done with 32 queues for PF and 16 for VF
device across different qede devices, so change here is to advertise
only those many instead of returning max queues supported by HW.
Fixes: 2ea6f76aff ("qede: add core driver")
Signed-off-by: Harish Patil <harish.patil@qlogic.com>
qede PMD does not support SR-IOV PF driver functionality, so
max_vfs is set to 0 to imply the same.
Fixes: 2ea6f76aff ("qede: add core driver")
Signed-off-by: Harish Patil <harish.patil@qlogic.com>
This patch includes the following:
- Fix missing hash_key_size advertisement
- Fix RSS hash query function
- Update RSS offload flag
- Accept user provided RSS configuration params via rx_adv_conf
in dev_configure()
- Decouple RSS configuration from common qed_update_vport() and
instead make use of existing RSS APIs for default RSS configuration
Fixes: 6d9e26c42c ("net/qede: get RSS hash configuration")
Fixes: 9c5d0a669f ("net/qede: fix RSS")
Signed-off-by: Harish Patil <harish.patil@qlogic.com>
In qede_mac_addr_add() a check is added to differentiate between
unicast/multicast mac to prevent a multicast mac from being wrongly added
to unicast filter table. Secondly, two separate lists will be used to keep
track of unicast/multicast mac filters to prevent duplicate filter
programming. The other change is to remove filter_config from struct
qed_eth_ops_pass and invoke the base APIs directly. This avoids the need
to have multiple structs and function calls.
Fixes: 2ea6f76aff ("qede: add core driver")
Signed-off-by: Harish Patil <harish.patil@qlogic.com>
Update the version of shared codes to cid-ixgbe.2016.11.21.tar.gz,
All files in net/ixgbe/base are developed by another team and
DPDK PMD uses them accordingly.
Signed-off-by: Wei Dai <wei.dai@intel.com>
This patch updates the configuration of PHY from Inphi (www.inphi.com)
to flush the register write with a reg read.
The Inphi PHY is configured in ixgbe_setup_mac_link_sfp_x550a.
The Inphi PHY setup flow has been updated to read configuration reg,
write only linear/non-linear, and then read (write flush).
Signed-off-by: Wei Dai <wei.dai@intel.com>
This register was incorrect when compared to the data sheet.
Even though the driver doesn't currently use this register,
it is better to fix it upstream.
Fixes: af75078fec ("first public release")
Signed-off-by: Wei Dai <wei.dai@intel.com>
This patch adds Energy Efficient Ethernet (EEE) support for
some Marvell PHYs on some future platforms.
Because EEE capability or status was not indicated previously,
this patch simply assumes that it is supported.
As soon as there is a PHY that does not support EEE, there will
be defects in this area because the driver will not report the
EEE status correctly.
This also deletes some now-unused definitions from an earlier
Marvell PHY implementation and combines a device ID check into a
switch statement.
Signed-off-by: Wei Dai <wei.dai@intel.com>
This patch removes the flow control conversion from Rx and Tx to pause
and asymmetric pause, as that is handled by the ixgbe_negotiate_fc().
Performing the conversion prior to ixgbe_negotiate_fc() results in
an incorrect fc mode if Rx only pause is selected when the link partner
is advertising Tx.
Signed-off-by: Wei Dai <wei.dai@intel.com>
ixgbe_read_i2c_combined_generic_int() is only used by devices >= X550.
Set the initial value accordingly and remove the MAC type check.
Signed-off-by: Wei Dai <wei.dai@intel.com>
The "FW" PHY type now supports speeds 10M, 100M, and 1G.
Previously, only the 1G speed was reported for this PHY type.
Add reporting 10M and 100M speed options.
Signed-off-by: Wei Dai <wei.dai@intel.com>
This patch moves some of the extended speeds that come with X552
(5G, 2.5G, 10M) into the link check functions.
It also now returns speed_unknown for speeds that are not known
how to interpret.
Signed-off-by: Wei Dai <wei.dai@intel.com>
Read and store NW_MNG_IF_SEL register because register fields are
used to determine SGMII link for busy SGMII register reads.
Signed-off-by: Wei Dai <wei.dai@intel.com>
Update ixgbe_setup_phy_link_generic that set/unset auto-negotiation.
Ensure that unsupported auto-negotiation speeds are unset.
This is necessary since the PHY NVM may advertise unsupported speeds.
Fixes: af75078fec ("first public release")
Signed-off-by: Wei Dai <wei.dai@intel.com>
Fix ixgbe_setup_sgmii_m88 to set lane speed to autoneg instead of 1G
to prevent problems with link between PHYs
Fixes: d4b4c68454 ("net/ixgbe/base: add X550em_a FW ALEF support")
Signed-off-by: Wei Dai <wei.dai@intel.com>
Return correct physical layer for some x550 devices.
Fixes: 76d5b807ff ("ixgbe/base: new X557 phy")
Fixes: d2e72774e5 ("ixgbe/base: support X550")
Signed-off-by: Wei Dai <wei.dai@intel.com>
The MAC register NW_MNG_IF_SEL fields have been redefined for X553.
These changes impact the iXFI driver code flow. Since iXFI is only
supported in X552, this patch adds X552 MAC check for iXFI flows.
Signed-off-by: Wei Dai <wei.dai@intel.com>
Enable the Link Alarm Status Interrupt (LASI) only for X552 devices
to receive notifications of the link configurations of the external
PHY and correspondingly support the configuration of the internal
iXFI link, since iXFI does not support auto-negotiation.
This is not required for X553 devices having KR support, which
performs auto-negotiations and which is used as the internal
link to the external PHY.
Signed-off-by: Wei Dai <wei.dai@intel.com>
The variable checksum_last_word is used only for bounds check.
So remove this variable and use IXGBE_EEPROM_CHECKSUM directly.
Signed-off-by: Wei Dai <wei.dai@intel.com>
Add support to get the link active LED index via the LEDCTL register.
If the LEDCTL register does not have link active LED set then
use MAC default LED index.
Link active LED is used for adapter identify/blink support.
Signed-off-by: Wei Dai <wei.dai@intel.com>
This patch cleans up the code and clarifies the comment around
the X557 PHY link status check in ixgbe_check_link_t_x550em().
Signed-off-by: Wei Dai <wei.dai@intel.com>
Method to identify the CS4223/CS4227 is incorrect and unreliable.
Provide a new register to differentiate between these PHY SKUs.
Fixes: fc0559bdb5 ("net/ixgbe/base: add link MAC setup for X550a SFP+")
Signed-off-by: Wei Dai <wei.dai@intel.com>
Devices that cannot go 10G speeds can safely select a faster
Management Data Input/Output (MDIO) speed.
Select fast MDIO clock speed for for those devices.
Signed-off-by: Wei Dai <wei.dai@intel.com>
Receive Address Register (RAR) entries, including SAN MAC address,
are cleared when VMDq pool bits are cleared.
Prevent SAN MAC address to be cleared.
Fixes: af75078fec ("first public release")
Signed-off-by: Wei Dai <wei.dai@intel.com>
PHY type ixgbe_phy_x550em_ext_t requires different check
to verify reset status.
Fixes: af75078fec ("first public release")
Signed-off-by: Wei Dai <wei.dai@intel.com>
NFP supports more speeds than just 40 and 100GB, which were
what was advertised before.
Signed-off-by: Alejandro Lucero <alejandro.lucero@netronome.com>
Previous reported speed was hardcoded because there was not firmware
support for getting this information. This change needs also to support
old firmware versions, but instead of the previous hardcoded report, no
speed is reported to the user avoiding to give the wrong speed when link
is not configured to 40G.
Signed-off-by: Alejandro Lucero <alejandro.lucero@netronome.com>
Because macros for TCP and UDP related to offload cksums have
same values, this was not a main problem. But better to use the
right ones.
Fixes: d4a27a3b09 ("nfp: add basic features")
Signed-off-by: Alejandro Lucero <alejandro.lucero@netronome.com>
Our use case is that we have an app that needs to keep mbufs around
for a while. We've seen cases when calling vmxnet3_post_rx_bufs() from
vmxet3_recv_pkts(), it might not succeed to add any mbufs to any RX
descriptors (where it returns -err). Since there are no mbufs that the
virtual hardware can use, no packets will be received after this; the
driver won't refill the mbuf after this so it gets stuck in this
state. I call this a deadlock for lack of a better term - the virtual
HW waits for free mbufs, while the app waits for the hardware to
notify it for data (by flipping the generation bit on the used Rx
descriptors). Note that after this, the app can't recover.
This fix is a rework of this patch by Marco Lee:
http://dpdk.org/dev/patchwork/patch/6575/. I had to forward port
it, address review comments and also reverted the allocation
failure handling to the first version of the patch
(http://dpdk.org/ml/archives/dev/2015-July/022079.html), since
that's the only approach that seems to work, and seems to be what
other drivers are doing (I checked ixgbe and em). Reusing the mbuf
that's getting passed to the application doesn't seem to make
sense, and it was causing weird issues in our app. Also, reusing
rxm without checking if it's NULL could cause the code to crash.
Fixes: 14680e3747 ("vmxnet3: improve Rx performance")
Signed-off-by: Stefan Puiu <stefan.puiu@gmail.com>
Acked-by: Yong Wang <yongwang@vmware.com>
Signed-off-by: Ivan Malov <ivan.malov@oktetlabs.ru>
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
Reviewed-by: Andrew Lee <alee@solarflare.com>
Reviewed-by: Mark Spender <mspender@solarflare.com>
Reviewed-by: Robert Stonehouse <rstonehouse@solarflare.com>
Signed-off-by: Ivan Malov <ivan.malov@oktetlabs.ru>
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
Reviewed-by: Andrew Lee <alee@solarflare.com>
Reviewed-by: Robert Stonehouse <rstonehouse@solarflare.com>
Signed-off-by: Ivan Malov <ivan.malov@oktetlabs.ru>
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
Reviewed-by: Andrew Lee <alee@solarflare.com>
Reviewed-by: Robert Stonehouse <rstonehouse@solarflare.com>
Signed-off-by: Ivan Malov <ivan.malov@oktetlabs.ru>
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
Reviewed-by: Andrew Lee <alee@solarflare.com>
Reviewed-by: Robert Stonehouse <rstonehouse@solarflare.com>
Signed-off-by: Ivan Malov <ivan.malov@oktetlabs.ru>
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
Reviewed-by: Andrew Lee <alee@solarflare.com>
Reviewed-by: Robert Stonehouse <rstonehouse@solarflare.com>
Extract RSS hash provided by the HW in the prefix and put it to mbuf.
Signed-off-by: Ivan Malov <ivan.malov@oktetlabs.ru>
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
Reviewed-by: Andrew Lee <alee@solarflare.com>
Reviewed-by: Robert Stonehouse <rstonehouse@solarflare.com>
Signed-off-by: Ivan Malov <ivan.malov@oktetlabs.ru>
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
Reviewed-by: Andrew Lee <alee@solarflare.com>
Reviewed-by: Robert Stonehouse <rstonehouse@solarflare.com>
ICC complains that enumerated type mixed with another type.
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
Reviewed-by: Andrew Lee <alee@solarflare.com>
Reviewed-by: Robert Stonehouse <rstonehouse@solarflare.com>
Signed-off-by: Ivan Malov <ivan.malov@oktetlabs.ru>
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
Reviewed-by: Andrew Lee <alee@solarflare.com>
Reviewed-by: Robert Stonehouse <rstonehouse@solarflare.com>
Signed-off-by: Ivan Malov <ivan.malov@oktetlabs.ru>
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
Reviewed-by: Andrew Lee <alee@solarflare.com>
Reviewed-by: Robert Stonehouse <rstonehouse@solarflare.com>
Signed-off-by: Ivan Malov <ivan.malov@oktetlabs.ru>
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
Reviewed-by: Andrew Lee <alee@solarflare.com>
Reviewed-by: Robert Stonehouse <rstonehouse@solarflare.com>
Signed-off-by: Ivan Malov <ivan.malov@oktetlabs.ru>
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
Reviewed-by: Andrew Lee <alee@solarflare.com>
Reviewed-by: Robert Stonehouse <rstonehouse@solarflare.com>
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
Reviewed-by: Andrew Lee <alee@solarflare.com>
Reviewed-by: Robert Stonehouse <rstonehouse@solarflare.com>
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
Reviewed-by: Andrew Lee <alee@solarflare.com>
Reviewed-by: Robert Stonehouse <rstonehouse@solarflare.com>
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
Reviewed-by: Andrew Lee <alee@solarflare.com>
Reviewed-by: Robert Stonehouse <rstonehouse@solarflare.com>
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
Reviewed-by: Andrew Lee <alee@solarflare.com>
Reviewed-by: Robert Stonehouse <rstonehouse@solarflare.com>
Rx free threshold defines minimum number of free Rx descriptors
when Rx ring refill should be done.
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
Reviewed-by: Andrew Lee <alee@solarflare.com>
Reviewed-by: Robert Stonehouse <rstonehouse@solarflare.com>
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
Reviewed-by: Andrew Lee <alee@solarflare.com>
Reviewed-by: Robert Stonehouse <rstonehouse@solarflare.com>
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
Reviewed-by: Andrew Lee <alee@solarflare.com>
Reviewed-by: Robert Stonehouse <rstonehouse@solarflare.com>
IPv4 header and TCP/UDP checksums for both IPv4 and IPv6 are supported.
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
Reviewed-by: Andrew Lee <alee@solarflare.com>
Reviewed-by: Robert Stonehouse <rstonehouse@solarflare.com>
Signed-off-by: Ivan Malov <ivan.malov@oktetlabs.ru>
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
Reviewed-by: Andrew Lee <alee@solarflare.com>
Reviewed-by: Robert Stonehouse <rstonehouse@solarflare.com>
Signed-off-by: Ivan Malov <ivan.malov@oktetlabs.ru>
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
Reviewed-by: Andrew Lee <alee@solarflare.com>
Reviewed-by: Robert Stonehouse <rstonehouse@solarflare.com>
Signed-off-by: Ivan Malov <ivan.malov@oktetlabs.ru>
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
Reviewed-by: Andrew Lee <alee@solarflare.com>
Reviewed-by: Robert Stonehouse <rstonehouse@solarflare.com>
Signed-off-by: Artem Andreev <artem.andreev@oktetlabs.ru>
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
Reviewed-by: Andrew Lee <alee@solarflare.com>
Reviewed-by: Robert Stonehouse <rstonehouse@solarflare.com>