Kalesh AP [Tue, 28 Jan 2020 07:29:20 +0000 (12:59 +0530)]
net/bnxt: remove unnecessary structure variable
This change could help in reducing the size of bnxt PMD private
data structure by converting a uint8_t variable to use bit map flag.
Fixes:
5cd0e2889c43 ("net/bnxt: support NIC Partitioning")
Cc: stable@dpdk.org
Reviewed-by: Santoshkumar Karanappa Rastapur <santosh.rastapur@broadcom.com>
Reviewed-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
Signed-off-by: Somnath Kotur <somnath.kotur@broadcom.com>
Signed-off-by: Kalesh AP <kalesh-anakkur.purayil@broadcom.com>
Kalesh AP [Tue, 28 Jan 2020 07:29:19 +0000 (12:59 +0530)]
net/bnxt: remove redundant macro
Use "dev->data->dev_started" state, instead of local BNXT_FLAG_INIT_DONE
to check whether device has been initialised or not.
Fixes:
ed2ced6fe927 ("net/bnxt: check initialization before accessing stats")
Cc: stable@dpdk.org
Reviewed-by: Santoshkumar Karanappa Rastapur <santosh.rastapur@broadcom.com>
Reviewed-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
Signed-off-by: Somnath Kotur <somnath.kotur@broadcom.com>
Signed-off-by: Kalesh AP <kalesh-anakkur.purayil@broadcom.com>
Kalesh AP [Tue, 28 Jan 2020 07:29:18 +0000 (12:59 +0530)]
net/bnxt: remove redundant if statement
Since "eth_dev->data->dev_started" has been assigned to 0 at the
beginning of bnxt_dev_stop_op() routine, the code inside the if()
condition is redundant. Remove it.
Anyways "eth_dev->data->dev_link.link_status" will be set to 0 in
bnxt_dev_set_link_down_op() later in the routine.
Fixes:
316e412299fd ("net/bnxt: fix crash when closing")
Cc: stable@dpdk.org
Signed-off-by: Kalesh AP <kalesh-anakkur.purayil@broadcom.com>
Signed-off-by: Somnath Kotur <somnath.kotur@broadcom.com>
Reviewed-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
Somnath Kotur [Tue, 28 Jan 2020 07:29:17 +0000 (12:59 +0530)]
net/bnxt: allow group ID 0 for RSS action
Allow RSS action with group ID 0. The RSS match check will ensure if
requested RSS action configuration parameters should be allowed as per
the VNIC's RSS configuration or not and if it does match as it is
by design in OVS-DPDK use case, the default vnic can be used to create
the filter. As part of this ensure that rx_queue_cnt for the default
vnic is setup during init as this field was being set only for non-zero
vnics while handling RSS action for flow create.
Check for out of bounds error while accessing the vnic array.
Fixes:
adc0f81c6552 ("net/bnxt: support RSS action")
Cc: stable@dpdk.org
Reviewed-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
Signed-off-by: Somnath Kotur <somnath.kotur@broadcom.com>
Somnath Kotur [Tue, 28 Jan 2020 07:29:16 +0000 (12:59 +0530)]
net/bnxt: fix bumping of L2 filter reference count
Now that the L2 filter reference count is bumped up in all cases
including bnxt_alloc_filter() which is issued in init, just move this
ref count bump inside the routine issuing the HWRM cmd so that it is
bumped up only if the cmd is successful.
Fixes:
5c1171c97216 ("net/bnxt: refactor filter/flow")
Cc: stable@dpdk.org
Reviewed-by: Kalesh AP <kalesh-anakkur.purayil@broadcom.com>
Signed-off-by: Somnath Kotur <somnath.kotur@broadcom.com>
Signed-off-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
Somnath Kotur [Tue, 28 Jan 2020 07:29:15 +0000 (12:59 +0530)]
net/bnxt: fix alloc filter to use a common routine
Invoke bnxt_get_unused_filter() inside bnxt_alloc_filter() so that
all filters are allocated from one common routine.
Fixes:
f92735db1e4c ("net/bnxt: add L2 filter alloc/init/free")
Cc: stable@dpdk.org
Reviewed-by: Kalesh AP <kalesh-anakkur.purayil@broadcom.com>
Signed-off-by: Somnath Kotur <somnath.kotur@broadcom.com>
Signed-off-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
Kiran Kumar K [Fri, 24 Jan 2020 13:54:26 +0000 (19:24 +0530)]
net/octeontx2: disable HIGIG on port stop
If HIGIG mode is enabled on configure, This needs to be disabled
on port stop. Adding support to send mbox message on port stop
to configure the port to default.
Signed-off-by: Kiran Kumar K <kirankumark@marvell.com>
Acked-by: Jerin Jacob <jerinj@marvell.com>
Kiran Kumar K [Fri, 24 Jan 2020 03:46:02 +0000 (09:16 +0530)]
net/octeontx2: extend RSS supported offload types
Extend RSS offload types for octeontx2. Add support to select
L3 SRC, L3 DST, L4 SRC and L4 DST for RSS calculation.
Add support to select L3 SRC or DST only, L4 SRC or DST only for RSS
calculation.
With this requirement there will be following combinations,
IPV[4,6]_SRC_ONLY, IPV[4,6]_DST_ONLY, [TCP,UDP,SCTP]_SRC_ONLY,
[TCP,UDP,SCTP]_DST_ONLY. So, instead of creating a bit for each
combination, we are using upper 4 bits (31:28) in the flow_key_cfg
to represent the SRC, DST selection. 31 => L3_SRC, 30 => L3_DST,
29 => L4_SRC, 28 => L4_DST. These won't be part of flow_cfg, so that
we don't need to change the existing ABI.
Signed-off-by: Kiran Kumar K <kirankumark@marvell.com>
Acked-by: Jerin Jacob <jerinj@marvell.com>
Rasesh Mody [Sun, 26 Jan 2020 22:54:19 +0000 (14:54 -0800)]
net/bnx2x: fix to sync fastpath Rx queue access
PMD handles fast path completions in the Rx handler and control path
completions in the interrupt handler. They both are processing
completions from the same fastpath completion queue. There is a
potential for race condition when these two paths are processing
the completions from the same queue and trying to updating Rx Producer.
Add a fastpath Rx lock between these two paths to close this race.
Fixes:
540a211084a7 ("bnx2x: driver core")
Cc: stable@dpdk.org
Signed-off-by: Rasesh Mody <rmody@marvell.com>
Rasesh Mody [Sun, 26 Jan 2020 22:54:18 +0000 (14:54 -0800)]
net/bnx2x: fix reset of scan FP flag
The fastpath task queue handler resets the fastpath scan flag
unconditionally, this patch changes that to reset the flag
only if it was set.
Fixes:
08a6e472c3d7 ("net/bnx2x: fix packet drop")
Cc: stable@dpdk.org
Signed-off-by: Rasesh Mody <rmody@marvell.com>
Stephen Hemminger [Mon, 27 Jan 2020 03:34:58 +0000 (19:34 -0800)]
app/testpmd: fix RFC addresses for Tx only
The previous patch to change default IP addresses for tx only
mode got the wrong values (typo).
Fixes:
bf5b2126bf44 ("app/testpmd: add ability to set Tx IP and UDP parameters")
Cc: stable@dpdk.org
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
Suanming Mou [Thu, 23 Jan 2020 06:01:02 +0000 (08:01 +0200)]
net/mlx5: fix register usage in meter
Flow with meter will split to three subflows, the prefix subflow with
meter action do the color, the meter subflow filter the packets, the
suffix subflow do all the left actions for packets pass the filter.
Both the color and the subflow match between prefix and suffix use the
register to store the tag.
For some of the NICs with meter color register share capability, it
only uses 8 LSB of the register for color, the left 24 MSB can be used
for flow id match between meter prefix subflow and suffix subflow.
Currently, one entire register is allocated for flow matching which
causes the NICs with limited registers don't have enough register for
other matching.
Add the meter color share capability checking to fix lacking of
registers issue.
Fixes:
9ea9b049a960 ("net/mlx5: split meter flow")
Cc: stable@dpdk.org
Signed-off-by: Suanming Mou <suanmingm@mellanox.com>
Acked-by: Viacheslav Ovsiienko <viacheslavo@mellanox.com>
Suanming Mou [Thu, 23 Jan 2020 06:01:01 +0000 (08:01 +0200)]
net/mlx5: support maximum flow id allocation
The id allocated is for the register unique id match. Some registers may
not use the full 32 bits. Add the maximum id to avoid allocate id over
the register restriction.
Signed-off-by: Suanming Mou <suanmingm@mellanox.com>
Acked-by: Viacheslav Ovsiienko <viacheslavo@mellanox.com>
Shiri Kuzin [Wed, 22 Jan 2020 14:37:54 +0000 (14:37 +0000)]
net/mlx5: fix ICMPv6 header rewrite actions
The ConnectX-5 HW cannot calculate the checksum for ICMPv6,
therefore flows with pattern 'ipv6 proto is 58' with actions that change
the header should be rejected. the actions that change the header
in this type of flow are 'set_ipv6_src' and 'set_ipv6_dst'.
Fixes:
4bb14c83df95 ("net/mlx5: support modify header using Direct Verbs")
Cc: stable@dpdk.org
Signed-off-by: Shiri Kuzin <shirik@mellanox.com>
Acked-by: Viacheslav Ovsiienko <viacheslavo@mellanox.com>
Dekel Peled [Wed, 22 Jan 2020 12:33:06 +0000 (14:33 +0200)]
net/mlx5: fix setting of port ID for egress rules
Previous patch fixed the setting of port-id for eswitch rules, which
are ingress only.
This patch expands the fix, to support NIC rules as well, which can
be ingress or egress.
Fixes:
ce777b147bf8 ("net/mlx5: fix E-Switch flow without port item")
Cc: stable@dpdk.org
Signed-off-by: Dekel Peled <dekelp@mellanox.com>
Acked-by: Ori Kam <orika@mellanox.com>
Eli Britstein [Wed, 22 Jan 2020 15:03:58 +0000 (15:03 +0000)]
net/mlx5: fix zero out UDP checksum in encap data
The cited commit zeroed the UDP checksum for raw-encap case.
Add the same handling for vxlan-encap case.
Fixes:
bf1d7d9a033a ("net/mlx5: zero out UDP checksum in encapsulation")
Cc: stable@dpdk.org
Signed-off-by: Eli Britstein <elibr@mellanox.com>
Acked-by: Matan Azrad <matan@mellanox.com>
Matan Azrad [Wed, 22 Jan 2020 14:36:10 +0000 (14:36 +0000)]
net/mlx5: fix build with clang 3.4.2
Compilation massage example:
"dpdk/drivers/net/mlx5/mlx5_flow_dv.c:1087:10: error: comparison of
unsigned enum expression < 0 is always false
[-Werror,-Wtautological-compare]
if (reg < 0)
~~~ ^ ~
"
enum modify_reg holds only non-negative integers and in some places in
the code it was used to be compared with negative value, hence
compilation was failed.
Change all thus places to use integer instead of enum modify_reg.
Fixes:
3e8edd0ef848 ("net/mlx5: update metadata register ID query")
Fixes:
55deee1715f0 ("net/mlx5: extend flow mark support")
Cc: stable@dpdk.org
Signed-off-by: Matan Azrad <matan@mellanox.com>
Dekel Peled [Wed, 22 Jan 2020 14:27:23 +0000 (16:27 +0200)]
doc: update supported hardware offloads in mlx5 guide
Function of_set_vlan_vid is wrongly listed twice in table
"Supported hardware offloads".
This patch removes the listing of of_set_vlan_vid under
"Header rewrite", and leaves the listing of of_set_vlan_vid
under "VLAN".
Signed-off-by: Dekel Peled <dekelp@mellanox.com>
Acked-by: Ori Kam <orika@mellanox.com>
Acked-by: Viacheslav Ovsiienko <viacheslavo@mellanox.com>
Dekel Peled [Wed, 22 Jan 2020 14:27:22 +0000 (16:27 +0200)]
net/mlx5: update description of validation functions
Description of several functions is not accurate.
This patch updates the description, parameter names etc.
Signed-off-by: Dekel Peled <dekelp@mellanox.com>
Acked-by: Ori Kam <orika@mellanox.com>
Acked-by: Viacheslav Ovsiienko <viacheslavo@mellanox.com>
Dekel Peled [Wed, 22 Jan 2020 14:27:21 +0000 (16:27 +0200)]
net/mlx5: fix VLAN VID action validation
Validation function of 'set VLAN VID' action checks twice for existing
same action in flow rule.
This patch updates the validation function logic, to check the same
restrictions more efficiently.
Fixes:
5f163d520cff ("net/mlx5: support modify VLAN ID on existing VLAN header")
Fixes:
b8c0372bc5ac ("net/mlx5: fix set VLAN ID/PCP in new header")
Cc: stable@dpdk.org
Signed-off-by: Dekel Peled <dekelp@mellanox.com>
Acked-by: Ori Kam <orika@mellanox.com>
Acked-by: Viacheslav Ovsiienko <viacheslavo@mellanox.com>
Dekel Peled [Wed, 22 Jan 2020 14:27:20 +0000 (16:27 +0200)]
net/mlx5: fix pop VLAN action validation
Validation function of 'POP VLAN' action includes check for other
'POP VLAN' actions present in flow.
It doesn't check for 'PUSH VLAN' actions present in flow.
This patch adds check for 'PUSH VLAN' actions present in flow.
Fixes:
b41e47da2592 ("net/mlx5: support pop flow action on VLAN header")
Cc: stable@dpdk.org
Signed-off-by: Dekel Peled <dekelp@mellanox.com>
Acked-by: Ori Kam <orika@mellanox.com>
Acked-by: Viacheslav Ovsiienko <viacheslavo@mellanox.com>
Dekel Peled [Wed, 22 Jan 2020 14:27:19 +0000 (16:27 +0200)]
net/mlx5: block pop VLAN action on Tx
Add missing check in validation function of 'pop VLAN' action.
Action is not allowed for egress flow rules.
Fixes:
b41e47da2592 ("net/mlx5: support pop flow action on VLAN header")
Cc: stable@dpdk.org
Signed-off-by: Dekel Peled <dekelp@mellanox.com>
Acked-by: Ori Kam <orika@mellanox.com>
Acked-by: Viacheslav Ovsiienko <viacheslavo@mellanox.com>
Dekel Peled [Wed, 22 Jan 2020 14:27:18 +0000 (16:27 +0200)]
net/mlx5: block push VLAN action on Rx
Add missing check in validation function of 'push VLAN' action.
Action is not allowed for ingress flow rules.
Fixes:
9aee7a8418d4 ("net/mlx5: support push flow action on VLAN header")
Cc: stable@dpdk.org
Signed-off-by: Dekel Peled <dekelp@mellanox.com>
Acked-by: Ori Kam <orika@mellanox.com>
Acked-by: Viacheslav Ovsiienko <viacheslavo@mellanox.com>
Dekel Peled [Wed, 22 Jan 2020 14:27:17 +0000 (16:27 +0200)]
net/mlx5: unify validation of drop action
According to PRM: "Drop action is mutually-exclusive with any other
action, except for Count action".
In current code this limitation is checked separately in validation
function of each action.
This patch removes the discrete checks, and adds a single check common
for all actions.
Signed-off-by: Dekel Peled <dekelp@mellanox.com>
Acked-by: Ori Kam <orika@mellanox.com>
Acked-by: Viacheslav Ovsiienko <viacheslavo@mellanox.com>
Dekel Peled [Wed, 22 Jan 2020 14:27:16 +0000 (16:27 +0200)]
net/mlx5: allow push VLAN without VID
Currently the push VLAN action requires a VID value, either from
existing VLAN item, or from following 'set VLAN vid' action.
This patch removes this limitation, allowing a push VLAN action with
vid value 0.
Fixes:
b8c0372bc5ac ("net/mlx5: fix set VLAN ID/PCP in new header")
Cc: stable@dpdk.org
Signed-off-by: Dekel Peled <dekelp@mellanox.com>
Acked-by: Ori Kam <orika@mellanox.com>
Acked-by: Viacheslav Ovsiienko <viacheslavo@mellanox.com>
Dekel Peled [Wed, 22 Jan 2020 14:27:15 +0000 (16:27 +0200)]
net/mlx5: fix bit mask to validate push VLAN
Validation function of 'push VLAN' action uses (POP_VLAN or PUSH_VLAN)
actions flags, instead of using a mask of both flags.
This patch replaces it to use existing VLAN_ACTIONS mask.
Fixes:
9aee7a8418d4 ("net/mlx5: support push flow action on VLAN header")
Cc: stable@dpdk.org
Signed-off-by: Dekel Peled <dekelp@mellanox.com>
Acked-by: Ori Kam <orika@mellanox.com>
Acked-by: Viacheslav Ovsiienko <viacheslavo@mellanox.com>
Dekel Peled [Wed, 22 Jan 2020 14:27:14 +0000 (16:27 +0200)]
net/mlx5: fix check for VLAN actions
Flow validation function includes, after all items and actions are
validated discretely, a check for VLAN and VXLAN actions.
This check is incorrect and redundant.
This patch removes the invalid check from validation function.
Check is incorrect, action_flags bit map is checked against
items mask MLX5_FLOW_LAYER_TUNNEL.
Check is also redundant, because VLAN push/pop actions can be used
together with packet reformat actions.
Fixes:
b41e47da2592 ("net/mlx5: support pop flow action on VLAN header")
Cc: stable@dpdk.org
Signed-off-by: Dekel Peled <dekelp@mellanox.com>
Acked-by: Ori Kam <orika@mellanox.com>
Acked-by: Viacheslav Ovsiienko <viacheslavo@mellanox.com>
Dekel Peled [Wed, 22 Jan 2020 14:27:13 +0000 (16:27 +0200)]
net/mlx5: fix masks of encap and decap actions
PUSH_VLAN and POP_VLAN actions flags were added to ENCAP_ACTIONS
and DECAP_ACTIONS bit masks, respectively.
This is incorrect, because VLAN actions are considered as 'modify
header' actions, not as 'packet reformat' actions.
This patch removes the PUSH_VLAN and POP_VLAN actions flags from
ENCAP_ACTIONS and DECAP_ACTIONS bit masks.
Fixes:
9aee7a8418d4 ("net/mlx5: support push flow action on VLAN header")
Fixes:
b41e47da2592 ("net/mlx5: support pop flow action on VLAN header")
Cc: stable@dpdk.org
Signed-off-by: Dekel Peled <dekelp@mellanox.com>
Acked-by: Ori Kam <orika@mellanox.com>
Acked-by: Viacheslav Ovsiienko <viacheslavo@mellanox.com>
Chenmin Sun [Tue, 21 Jan 2020 11:56:53 +0000 (19:56 +0800)]
net/ice: add outer IPv4 matching for GTP-U flow
This patch adds the capability of matching the outer IPv4
headers for GTPU flows.
Fixes:
efc16c621415 ("net/ice: support flow director GTPU tunnel")
Cc: stable@dpdk.org
Signed-off-by: Chenmin Sun <chenmin.sun@intel.com>
Acked-by: Qi Zhang <qi.z.zhang@intel.com>
Acked-by: Xiaolong Ye <xiaolong.ye@intel.com>
Qi Zhang [Tue, 21 Jan 2020 01:30:48 +0000 (09:30 +0800)]
net/ice: fix flow director GTP-U pattern
Based on current FDIR implementation for GTP-U, inner specification is
not supported, issue a rule for eth/ipv4/gtpu/ipv4 will also match
eth/ipv4/gtpu/ipv6, the patch adds new pattern list to align with
existed implementation.
Fixes:
efc16c621415 ("net/ice: support flow director GTPU tunnel")
Cc: stable@dpdk.org
Signed-off-by: Qi Zhang <qi.z.zhang@intel.com>
Acked-by: Xiaolong Ye <xiaolong.ye@intel.com>
Yunjian Wang [Tue, 21 Jan 2020 02:12:43 +0000 (10:12 +0800)]
net/tap: fix memory leak when unregister intr handler
The return check of function tap_lsc_intr_handle_set() is wrong, it should
be 0 or a positive number if success. So the intr_handle->intr_vec was not
been freed when tap_lsc_intr_handle_set() returned a positive number.
Fixes:
4870a8cdd968 ("net/tap: support Rx interrupt")
Cc: stable@dpdk.org
Signed-off-by: Yunjian Wang <wangyunjian@huawei.com>
Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>
John Daley [Tue, 21 Jan 2020 20:35:07 +0000 (12:35 -0800)]
net/enic: use common min and max macros
Use the RTE_MIN and RTE_MAX macros instead of private macros.
Fixes:
aae7dd40cda4 ("net/enic: move min/max macros")
Signed-off-by: John Daley <johndale@cisco.com>
Reviewed-by: Hyong Youb Kim <hyonkim@cisco.com>
Stephen Hemminger [Wed, 22 Jan 2020 17:55:14 +0000 (09:55 -0800)]
net/bnxt: remove unnecessary memset
The rte_ethdev layer already zeros statistics before calling
the device.
Fixes:
57d5e5bc86e4 ("net/bnxt: add statistics")
Cc: stable@dpdk.org
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Reviewed-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
Stephen Hemminger [Wed, 22 Jan 2020 17:55:13 +0000 (09:55 -0800)]
net/bnxt: do not log error if stats queried before start
When using pktgen lots of unnecessary errors are printed
because pktgen queries statistics before device is started.
Fixes:
3e92fd4e4ec0 ("net/bnxt: use dynamic log type")
Cc: stable@dpdk.org
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Reviewed-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
Stephen Hemminger [Wed, 22 Jan 2020 00:47:33 +0000 (16:47 -0800)]
net/bnxt: fix VLAN strip flags in SSE Rx
When the VLAN is stripped from the packet on receive the
driver must set the PKT_RX_VLAN_STRIPPED flag in the mbuf.
This is done correctly for normal receive in the bnxt driver
but was not being handled correctly in the new SSE code.
Fixes:
bc4a000f2f53 ("net/bnxt: implement SSE vector mode")
Cc: stable@dpdk.org
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Reviewed-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
Tao Zhu [Thu, 16 Jan 2020 16:38:36 +0000 (16:38 +0000)]
net/ice: fix flow FDIR/switch memory leak
1. Fix ice FDIR and hash flow memory leak.
2. Fix the ice definition of LIST_FOR_EACH_ENTRY_SAFE not
save tmp which cause list deletion incompletely.
Fixes:
5f0978e96220 ("net/ice/base: add OS specific implementation")
Fixes:
f5cafa961fae ("net/ice: add flow director create and destroy")
Fixes:
5ad3db8d4bdd ("net/ice: enable advanced RSS")
Cc: stable@dpdk.org
Signed-off-by: Tao Zhu <taox.zhu@intel.com>
Reviewed-by: Simei Su <simei.su@intel.com>
Reviewed-by: Yahui Cao <yahui.cao@intel.com>
Acked-by: Xiaolong Ye <xiaolong.ye@intel.com>
Xiaolong Ye [Wed, 22 Jan 2020 03:58:10 +0000 (11:58 +0800)]
net/i40e/base: skip further adminq init for VF
Since VF has no need of firmware, we can skip further adminq init which
involves firmware operation, this patch fixes the testpmd segfault issue
when starting with i40e VF.
Fixes:
d5e1a149362e ("net/i40e/base: check MAC type")
Signed-off-by: Xiaolong Ye <xiaolong.ye@intel.com>
Acked-by: Beilei Xing <beilei.xing@intel.com>
Beilei Xing [Tue, 21 Jan 2020 11:42:11 +0000 (19:42 +0800)]
net/ice: fix flow director flag
If there's no mark action when creating a FDIR rule,
there shouldn't be FDIR flags in mbuf.
Fixes:
f5cafa961fae ("net/ice: add flow director create and destroy")
Fixes:
bd984f155f49 ("net/ice/base: support FDIR")
Cc: stable@dpdk.org
Signed-off-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Qi Zhang <qi.z.zhang@intel.com>
Somnath Kotur [Thu, 16 Jan 2020 13:04:55 +0000 (18:34 +0530)]
net/bnxt: fix max rings calculation
Max Tx rings count could be lesser than max Rx rings in some
cases, so take this into account as well.
Account for stat contexts available(one for each ring) along with
no: of completion rings(one for each ring) to cap the max no: of
Tx /Rx rings that can be possibly created.
Fixes:
f03e66cb64ce ("net/bnxt: limit queue count for NS3/Stingray devices")
Cc: stable@dpdk.org
Signed-off-by: Somnath Kotur <somnath.kotur@broadcom.com>
Reviewed-by: Kalesh AP <kalesh-anakkur.purayil@broadcom.com>
Reviewed-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
Somnath Kotur [Thu, 16 Jan 2020 13:04:54 +0000 (18:34 +0530)]
net/bnxt: release port upon close
Set RTE_ETH_DEV_CLOSE_REMOVE upon probe so all the private resources
for the port can be freed by rte_eth_dev_close().
Signed-off-by: Somnath Kotur <somnath.kotur@broadcom.com>
Reviewed-by: Kalesh AP <kalesh-anakkur.purayil@broadcom.com>
Reviewed-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
Kalesh AP [Thu, 16 Jan 2020 13:04:53 +0000 (18:34 +0530)]
net/bnxt: use macro for PCI log format
Fixes:
19e6af01bb36 ("net/bnxt: support get/set EEPROM")
Cc: stable@dpdk.org
Signed-off-by: Kalesh AP <kalesh-anakkur.purayil@broadcom.com>
Reviewed-by: Somnath Kotur <somnath.kotur@broadcom.com>
Kalesh AP [Thu, 16 Jan 2020 13:04:52 +0000 (18:34 +0530)]
net/bnxt: fix a memory leak in port stop
The memory for mark table is allocated during port start.
But the allocated memory is freed only during port close
or driver unload which in turn causes a memory leakage
on each port start/stop.
Fixed it by moving the memory free to port stop.
Fixes:
94eb699bc82e ("net/bnxt: support flow mark action")
Signed-off-by: Kalesh AP <kalesh-anakkur.purayil@broadcom.com>
Reviewed-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
Kalesh AP [Thu, 16 Jan 2020 13:04:51 +0000 (18:34 +0530)]
net/bnxt: handle HW filter setting when port is stopped
Driver destroy the VNIC when the port is brought down.
Port HW filter setting such as promiscuos, allmulti and
VLAN filtering will be applied when port is started.
Fixed to return success silently for these callbacks
when port is stopped. Also fixed to clear "bp->dev_stopped"
before invoking bnxt_vlan_offload_set_op() in bnxt_dev_start_op().
Signed-off-by: Kalesh AP <kalesh-anakkur.purayil@broadcom.com>
Reviewed-by: Venkat Duvvuru <venkatkumar.duvvuru@broadcom.com>
Kalesh AP [Thu, 16 Jan 2020 13:04:50 +0000 (18:34 +0530)]
net/bnxt: fix VLAN strip
HWRM_VNIC_CFG command to configure VNIC dynamically with
traffic running is not working. Driver has to free and
recreate the VNIC and then reconfigure the VNIC filters.
Fixes:
7fe5668d2ea3 ("net/bnxt: support VLAN filter and strip")
Cc: stable@dpdk.org
Signed-off-by: Kalesh AP <kalesh-anakkur.purayil@broadcom.com>
Reviewed-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
Reviewed-by: Somnath Kotur <somnath.kotur@broadcom.com>
Kalesh AP [Thu, 16 Jan 2020 13:04:49 +0000 (18:34 +0530)]
net/bnxt: fix enable/disable VLAN filtering
There is no condition check for the user requested operation
for VLAN filtering. As a result, VLAN filtering is getting disabled
when the user enables/disables VLAN stripping on same port.
The function bnxt_hwrm_clear_l2_filter() didn't actually free
L2 filter in HW if the reference count of filter is zero.
Fixed it by incrementing the reference count of filter in
bnxt_alloc_filter() routine.
Because of the recent changes in bnxt_hwrm_clear_l2_filter(),
change was needed in the routine bnxt_set_default_mac_addr_op()
to destroy and re-create the default filter when the user
changes the default MAC of the port.
Fixes:
5c1171c97216 ("net/bnxt: refactor filter/flow")
Fixes:
6118503d8071 ("net/bnxt: fix VLAN filtering")
Cc: stable@dpdk.org
Signed-off-by: Kalesh AP <kalesh-anakkur.purayil@broadcom.com>
Reviewed-by: Somnath Kotur <somnath.kotur@broadcom.com>
Reviewed-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
Kalesh AP [Thu, 16 Jan 2020 13:04:48 +0000 (18:34 +0530)]
net/bnxt: fix IOVA mapping
Use rte_malloc_virt2iova() to obtain the IO address of a
virtual address obtained through rte_malloc().
Fixed to use the iova address returned by rte_memzone_reserve_aligned()
as the call always returns with populating "mz->iova" with
rte_malloc_virt2iova(mz->addr).
Removed redundant rte_mem_lock_page() call to lock the pages.
Fixes:
f55e12f33416 ("net/bnxt: support extended port counters")
Cc: stable@dpdk.org
Signed-off-by: Kalesh AP <kalesh-anakkur.purayil@broadcom.com>
Reviewed-by: Somnath Kotur <somnath.kotur@broadcom.com>
Reviewed-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
Kalesh AP [Thu, 16 Jan 2020 13:04:47 +0000 (18:34 +0530)]
net/bnxt: fix probe in FreeBSD
In FreeBSD environment, nic_uio driver does not support interrupts
and rte_intr_callback_register() will fail to register interrupts
which in turn causes bnxt driver probe failure.
Fixed driver to ignore interrupt callback failures in FreeBSD.
Also fixed to not use a dedicated completion ring for async events
from FW and process these events on RXQ0 in FreeBSD.
Fixes:
6de4c538b393 ("net/bnxt: fix error handling in port start")
Fixes:
43f78b380f89 ("net/bnxt: retry IRQ callback deregistration")
Cc: stable@dpdk.org
Signed-off-by: Kalesh AP <kalesh-anakkur.purayil@broadcom.com>
Reviewed-by: Somnath Kotur <somnath.kotur@broadcom.com>
Reviewed-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
Reviewed-by: Santoshkumar Karanappa Rastapur <santosh.rastapur@broadcom.com>
Kalesh AP [Thu, 16 Jan 2020 13:04:46 +0000 (18:34 +0530)]
net/bnxt: fix flow creation
If flow create fails due to not enough filter resources,
driver does not populate the rte_flow_error using
rte_flow_error_set().
Since "rte_errno" could have garbage value and is not reliable,
it could cause a segfault in the stack in port_flow_complain().
Fix it to set rte_flow_error using rte_flow_error_set()
when flow create fails due to not enough filter resources.
Fixes:
5c1171c97216 ("net/bnxt: refactor filter/flow")
Cc: stable@dpdk.org
Signed-off-by: Kalesh AP <kalesh-anakkur.purayil@broadcom.com>
Reviewed-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
Takeshi Yoshimura [Fri, 17 Jan 2020 04:25:55 +0000 (13:25 +0900)]
vfio: fix mapping failures in ppc64le
ppc64le failed when using large physical memory. I found problems in my two
commits in the past.
In commit
e072d16f8920 ("vfio: fix expanding DMA area in ppc64le"), I added
a sanity check using a mapped address to resolve an issue around expanding
IOMMU window, but this was not enough, since memory allocation can return
memory anywhere dependent on memory fragmentation. DPDK may still skip DMA
mapping and attempts to unmap non-mapped DMA during expanding IOMMU window.
As a result, SPDK apps using large physical memory frequently failed to
proceed the communication with NVMe and/or went into an infinite loop.
The root cause of the bug was in a gap between memory segments managed by
DPDK and firmware-level DMA mapping. DPDK's memory segments don't contain
the state of DMA mapping, and so, the memesg_walk cannot determine if an
iterated memory segment is mapped or not. This resulted in incorrect DMA
maps and unmaps.
At this time, I added the code to avoid iterating non-mapped memory
segments during DMA mapping. The memseg_walk iterates over memory segments
marked as "used", and so, the code sets memory segments that will be
mapped or unmapped as "free" transiently.
The commit
db90b4969e2e ("vfio: retry creating sPAPR DMA window") allows
retring different page levels and sizes to create DMA window. However, this
allows page sizes different from hugepage sizes. This inconsistency caused
failures at the time of DMA mapping after the window creation. This patch
fixes to retry only different page levels.
Fixes:
e072d16f8920 ("vfio: fix expanding DMA area in ppc64le")
Fixes:
db90b4969e2e ("vfio: retry creating sPAPR DMA window")
Cc: stable@dpdk.org
Signed-off-by: Takeshi Yoshimura <tyos@jp.ibm.com>
Reviewed-by: David Christensen <drc@linux.vnet.ibm.com>
Andrzej Ostruszka [Thu, 30 Jan 2020 09:25:30 +0000 (10:25 +0100)]
build: remove unneeded function versioning
Timer, LPM and Distributor libraries no longer use function versioning
and therefore do not need separate build for static and shared version
of libraries.
This patch removes use_function_versioning from their meson build files
and corresponding include from the sources.
Fixes:
f2fb215843a9 ("timer: remove deprecated code")
Fixes:
6e5b51676176 ("distributor: remove deprecated code")
Fixes:
c381a8d554b7 ("lpm: remove deprecated code")
Cc: stable@dpdk.org
Signed-off-by: Andrzej Ostruszka <aostruszka@marvell.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: David Marchand <david.marchand@redhat.com>
Stephen Hemminger [Fri, 8 Nov 2019 16:47:17 +0000 (08:47 -0800)]
pdump: use dynamic log type
The logtype USER1 should not be overloaded for library function.
Instead use a dynamic log type.
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Reshma Pattan <reshma.pattan@intel.com>
Stephen Hemminger [Fri, 8 Nov 2019 16:47:16 +0000 (08:47 -0800)]
pdump: use mbuf copy function
The rte_pktmbuf_copy handles varying size mbuf pools correctly.
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Reshma Pattan <reshma.pattan@intel.com>
Honnappa Nagarahalli [Mon, 3 Feb 2020 19:49:12 +0000 (13:49 -0600)]
hash: fix lock-free flag doxygen
Lock-free extendable table is supported. Correct the comments.
Fixes:
f401363d984a ("hash: support lock-free extendable bucket")
Cc: stable@dpdk.org
Signed-off-by: Honnappa Nagarahalli <honnappa.nagarahalli@arm.com>
Honnappa Nagarahalli [Mon, 3 Feb 2020 19:49:11 +0000 (13:49 -0600)]
test/hash: move lock-free tests to perf tests
Move reader writer lock free tests to performance tests.
Signed-off-by: Honnappa Nagarahalli <honnappa.nagarahalli@arm.com>
Honnappa Nagarahalli [Mon, 3 Feb 2020 19:49:10 +0000 (13:49 -0600)]
test/hash: add lock-free functional tests
Add lock-free reader writer concurrency functional tests.
These tests will provide the same coverage that non lock-free
APIs have.
Signed-off-by: Honnappa Nagarahalli <honnappa.nagarahalli@arm.com>
Amit Gupta [Mon, 3 Feb 2020 19:49:08 +0000 (13:49 -0600)]
test/hash: split into shorter subtests
hash_readwrite test was taking too much time to complete in Travis.
Test is split into functional and perf test.
perf test is being moved under perf testsuites in meson.
Signed-off-by: Amit Gupta <agupta3@marvell.com>
Acked-by: Yipeng Wang <yipeng1.wang@intel.com>
Signed-off-by: Honnappa Nagarahalli <honnappa.nagarahalli@arm.com>
Thomas Monjalon [Wed, 5 Feb 2020 15:39:23 +0000 (16:39 +0100)]
buildtools: allow pedantic empty pmdinfo
If a driver has no info generated by pmdinfogen,
and if this driver is compiled as pedantic,
then an failure would occur:
drivers/rte_common_mlx5.pmd.c:1: error:
ISO C forbids an empty translation unit [-Werror=pedantic]
Such error is triggered with the new mlx5 common directory.
In order to allow an "empty driver info" compiled in pedantic mode,
the script generating .pmd.c file is modified to add a static string
unconditionnaly.
The minimal generated code is:
static __attribute__((unused)) const char *generator =
"/path/to/dpdk/buildtools/gen-pmdinfo-cfile.sh";
Signed-off-by: Thomas Monjalon <thomas@monjalon.net>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Thomas Monjalon [Wed, 5 Feb 2020 11:04:32 +0000 (12:04 +0100)]
cryptodev: revert Chacha20-Poly1305 AEAD algorithm
API makes think that rte_cryptodev_info_get() cannot return
a value >= 3 (RTE_CRYPTO_AEAD_LIST_END in 19.11).
20.02-rc1 was returning 3 (RTE_CRYPTO_AEAD_CHACHA20_POLY1305).
So the ABI compatibility contract was broken.
It could be solved with some function versioning,
but because a lack of time, the feature is reverted for now.
This reverts following commits:
-
6c9f3b347e21 ("cryptodev: add Chacha20-Poly1305 AEAD algorithm")
-
2c512e64d600 ("crypto/qat: support Chacha Poly")
-
d55e01f579e1 ("test/crypto: add Chacha Poly cases")
Signed-off-by: Thomas Monjalon <thomas@monjalon.net>
David Marchand [Sun, 2 Feb 2020 21:08:34 +0000 (22:08 +0100)]
devtools: add ABI checks
For normal developers, those checks are disabled.
Enabling them requires a configuration that will trigger the ABI dumps
generation as part of the existing devtools/test-build.sh and
devtools/test-meson-builds.sh scripts.
Those checks are enabled in the CI for the default meson options on x86
and aarch64 so that proposed patches are validated via our CI robot.
A cache of the ABI is stored in travis jobs to avoid rebuilding too
often.
Checks can be informational only, by setting ABI_CHECKS_WARN_ONLY when
breaking the ABI in a future release.
Explicit suppression rules have been added on internal structures
exposed to crypto drivers as the current ABI policy does not apply to
them.
This could be improved in the future by carefully splitting the headers
content with application and driver "users" in mind.
We currently have issues reported for librte_crypto recent changes for
which suppression rules have been added too.
Mellanox glue libraries are explicitly skipped as they are not part of
the application ABI.
Signed-off-by: David Marchand <david.marchand@redhat.com>
Acked-by: Luca Boccassi <bluca@debian.org>
David Marchand [Sun, 2 Feb 2020 21:08:33 +0000 (22:08 +0100)]
devtools: split meson build helper
No functional change intended, prepare for reusing this code.
The config and compilation parts are separated in helpers.
Unsetting CC is moved to the caller of the helper.
Signed-off-by: David Marchand <david.marchand@redhat.com>
Acked-by: Luca Boccassi <bluca@debian.org>
David Marchand [Sun, 2 Feb 2020 21:08:32 +0000 (22:08 +0100)]
hash: fix meson headers packaging
Those headers are internal and should not be distributed.
Fixes:
5b9656b157d3 ("lib: build with meson")
Cc: stable@dpdk.org
Signed-off-by: David Marchand <david.marchand@redhat.com>
Acked-by: Luca Boccassi <bluca@debian.org>
Pavan Nikhilesh [Fri, 24 Jan 2020 04:55:44 +0000 (10:25 +0530)]
lib: use common macro RTE_DIM
Use RTE_DIM to calculate array size.
Suggested-by: David Marchand <david.marchand@redhat.com>
Signed-off-by: Pavan Nikhilesh <pbhagavatula@marvell.com>
Acked-by: Cristian Dumitrescu <cristian.dumitrescu@intel.com>
Acked-by: Kevin Laatz <kevin.laatz@intel.com>
Acked-by: David Marchand <david.marchand@redhat.com>
Pavan Nikhilesh [Fri, 24 Jan 2020 04:55:43 +0000 (10:25 +0530)]
examples: use common macro RTE_DIM
Use RTE_DIM macro to calculate array size.
Suggested-by: David Marchand <david.marchand@redhat.com>
Signed-off-by: Pavan Nikhilesh <pbhagavatula@marvell.com>
Acked-by: David Marchand <david.marchand@redhat.com>
Pavan Nikhilesh [Fri, 24 Jan 2020 04:55:42 +0000 (10:25 +0530)]
app: use common macro RTE_DIM
Use RTE_DIM macro to calculate array size.
Suggested-by: David Marchand <david.marchand@redhat.com>
Signed-off-by: Pavan Nikhilesh <pbhagavatula@marvell.com>
Acked-by: David Marchand <david.marchand@redhat.com>
Pavan Nikhilesh [Tue, 28 Jan 2020 05:35:05 +0000 (11:05 +0530)]
doc: add event mode to l3fwd guide
Update l3fwd user guide to include event device related information.
Update release notes.
Signed-off-by: Pavan Nikhilesh <pbhagavatula@marvell.com>
Acked-by: Jerin Jacob <jerinj@marvell.com>
Pavan Nikhilesh [Tue, 28 Jan 2020 05:35:04 +0000 (11:05 +0530)]
examples/l3fwd: add graceful teardown for eventdev
Add graceful teardown that addresses both event mode and poll mode.
Signed-off-by: Pavan Nikhilesh <pbhagavatula@marvell.com>
Acked-by: Jerin Jacob <jerinj@marvell.com>
Pavan Nikhilesh [Tue, 28 Jan 2020 05:35:03 +0000 (11:05 +0530)]
examples/l3fwd: add event em main loop
Add em main loop for handling events based on capabilities of the
event device.
Signed-off-by: Pavan Nikhilesh <pbhagavatula@marvell.com>
Acked-by: Jerin Jacob <jerinj@marvell.com>
Pavan Nikhilesh [Tue, 28 Jan 2020 05:35:02 +0000 (11:05 +0530)]
examples/l3fwd: add event lpm main loop
Add lpm main loop for handling events based on capabilities of the
event device.
Signed-off-by: Pavan Nikhilesh <pbhagavatula@marvell.com>
Acked-by: Jerin Jacob <jerinj@marvell.com>
Pavan Nikhilesh [Tue, 28 Jan 2020 05:35:01 +0000 (11:05 +0530)]
examples/l3fwd: add service core setup based on caps
Add service core setup when eventdev and Rx/Tx adapter don't have
internal port capability.
Signed-off-by: Pavan Nikhilesh <pbhagavatula@marvell.com>
Acked-by: Jerin Jacob <jerinj@marvell.com>
Pavan Nikhilesh [Tue, 28 Jan 2020 05:35:00 +0000 (11:05 +0530)]
examples/l3fwd: add event eth Rx/Tx adapter setup
Add event eth Rx/Tx adapter setup for both generic and internal port
event device pipelines.
Signed-off-by: Sunil Kumar Kori <skori@marvell.com>
Signed-off-by: Pavan Nikhilesh <pbhagavatula@marvell.com>
Acked-by: Jerin Jacob <jerinj@marvell.com>
Sunil Kumar Kori [Tue, 28 Jan 2020 05:34:59 +0000 (11:04 +0530)]
examples/l3fwd: add event port and queue setup
Add event device queue and port setup based on event eth Tx adapter
capabilities.
Signed-off-by: Sunil Kumar Kori <skori@marvell.com>
Acked-by: Jerin Jacob <jerinj@marvell.com>
Sunil Kumar Kori [Tue, 28 Jan 2020 05:34:58 +0000 (11:04 +0530)]
examples/l3fwd: add ethdev setup based on eventdev
Add ethernet port Rx/Tx queue setup for event device which are later
used for setting up event eth Rx/Tx adapters.
Signed-off-by: Sunil Kumar Kori <skori@marvell.com>
Signed-off-by: Nipun Gupta <nipun.gupta@nxp.com>
Acked-by: Jerin Jacob <jerinj@marvell.com>
Pavan Nikhilesh [Tue, 28 Jan 2020 05:34:57 +0000 (11:04 +0530)]
examples/l3fwd: add event device configuration
Add event device configuration based on the capabilities of the
probed event device.
Signed-off-by: Pavan Nikhilesh <pbhagavatula@marvell.com>
Acked-by: Jerin Jacob <jerinj@marvell.com>
Sunil Kumar Kori [Tue, 28 Jan 2020 05:34:56 +0000 (11:04 +0530)]
examples/l3fwd: split pipelines based on capability
Add infra to split eventdev framework based on event Tx adapter
capability.
If event Tx adapter has internal port capability then we use
`rte_event_eth_tx_adapter_enqueue` to transmitting packets else
we use a SINGLE_LINK event queue to enqueue packets to a service
core which is responsible for transmitting packets.
Signed-off-by: Sunil Kumar Kori <skori@marvell.com>
Acked-by: Jerin Jacob <jerinj@marvell.com>
Sunil Kumar Kori [Tue, 28 Jan 2020 05:34:55 +0000 (11:04 +0530)]
examples/l3fwd: add framework for event device
Add framework to enable event device as a producer of packets.
To switch between event mode and poll mode the following options
have been added:
`--mode="eventdev"` or `--mode="poll"`
Allow the user to select the schedule type to be either
RTE_SCHED_TYPE_ORDERED, RTE_SCHED_TYPE_ATOMIC or RTE_SCHED_TYPE_PARALLEL
through:
`--eventq-sched="ordered"` or `--eventq-sched="atomic"` or
`--eventq-sched="parallel"`
Allow the user to specify the number of Rx queues to be connected to
event queue using:
`--event-eth-rxqs`
Poll mode is still the default operation mode.
Signed-off-by: Sunil Kumar Kori <skori@marvell.com>
Signed-off-by: Nipun Gupta <nipun.gupta@nxp.com>
Acked-by: Jerin Jacob <jerinj@marvell.com>
Mattias Rönnblom [Mon, 20 Jan 2020 15:03:00 +0000 (16:03 +0100)]
event/dsw: use custom element size ring for control
Replace DSW's use of regular DPDK rings (and code for
packing/unpacking control messages into void pointers) with custom
size rings.
In addition to cleaner code, this change allows DSW to support up to
the eventdev API's maximum of 255 ports by tweaking DSW_MAX_PORTS.
Signed-off-by: Mattias Rönnblom <mattias.ronnblom@ericsson.com>
Reviewed-by: Honnappa Nagarahalli <honnappa.nagarahalli@arm.com>
David Marchand [Mon, 20 Jan 2020 20:35:13 +0000 (21:35 +0100)]
maintainers: set git tree for EAL and core libraries
Without a git tree, the "guess" script from dpdk-ci will ignore all files
that are referenced in those sections and let a patchset land in any
subtree.
Changes in the EAL, mbuf, mempool... go through the main repository.
Signed-off-by: David Marchand <david.marchand@redhat.com>
Acked-by: Thomas Monjalon <thomas@monjalon.net>
David Marchand [Tue, 14 Jan 2020 13:09:02 +0000 (14:09 +0100)]
maintainers: set git tree for packet framework and QoS
Mark librte_meter and librte_sched as being handled in the dpdk-next-qos
subtree.
The packet framework bits go through dpdk-next-pipeline.
Signed-off-by: David Marchand <david.marchand@redhat.com>
David Marchand [Tue, 14 Jan 2020 09:18:15 +0000 (10:18 +0100)]
maintainers: set git tree for test applications
Changes on the main test applications should be considered against
subtrees where most of the API changes and development happen:
- testpmd goes through dpdk-next-net as it is mainly about ethdev,
- dpdk-test-compress-perf goes through dpdk-next-crypto since the
compress API goes through this tree,
- dpdk-test-crypto-perf through dpdk-next-crypto,
- dpdk-test-eventdev through dpdk-next-eventdev,
Signed-off-by: David Marchand <david.marchand@redhat.com>
Acked-by: Jerin Jacob <jerinj@marvell.com>
Acked-by: Thomas Monjalon <thomas@monjalon.net>
Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>
Acked-by: Andrew Rybchenko <arybchenko@solarflare.com>
Acked-by: Akhil Goyal <akhil.goyal@nxp.com>
Ranjit Menon [Mon, 13 Jan 2020 19:35:34 +0000 (11:35 -0800)]
maintainers: update for Windows
Since Anand is no longer with Intel, Pallavi will replace him
as maintainer.
Signed-off-by: Ranjit Menon <ranjit.menon@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Adrien Mazarguil [Wed, 8 Jan 2020 10:10:00 +0000 (11:10 +0100)]
maintainers: resign from flow API maintenance
Unfortunately due to lack of time, I've been unable to even participate to
flow API discussions for several months. Better make it official since this
is not going to improve anytime soon.
This doesn't mean I won't contribute to rte_flow in the future!
Cc: stable@dpdk.org
Signed-off-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
Acked-by: Ori Kam <orika@mellanox.com>
Gaetan Rivet [Wed, 8 Jan 2020 14:13:32 +0000 (15:13 +0100)]
maintainers: update for failsafe and PCI library
My email address has changed, gaetan.rivet@6wind.com is no longer valid.
Cc: stable@dpdk.org
Signed-off-by: Gaetan Rivet <grive@u256.net>
Ferruh Yigit [Tue, 21 Jan 2020 09:58:01 +0000 (09:58 +0000)]
net/ionic: ignore missing field initializers warning
The compiler warning is:
from .../drivers/net/ionic/ionic_dev.c:7:
.../drivers/net/ionic/ionic_if.h:202:5: note: ‘rsvd’ declared here
u8 rsvd[62];
^
This has been observed with gcc 4.8.5, newer 9+ compiler are not giving
this warning.
Warning is a reminder to the user that there are some fields in the
struct not initialized with the default value.
But the C standard clarifies that in that case the field value will be
zero and code is aware of this behavior, so no initializing to a default
value is intentional and it is safe to ignore this compiler warning.
Adding '-Wno-missing-field-initializers' compiler flag to disable the
warning.
Reported-by: Anoob Joseph <anoobj@marvell.com>
Reported-by: Raslan Darawsheh <rasland@mellanox.com>
Reported-by: Xueming Zhang <xuemingx.zhang@intel.com>
Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com>
Thomas Monjalon [Tue, 21 Jan 2020 00:26:11 +0000 (01:26 +0100)]
version: 20.02-rc1
Signed-off-by: Thomas Monjalon <thomas@monjalon.net>
David Marchand [Mon, 2 Dec 2019 15:42:20 +0000 (16:42 +0100)]
eal: remove limitation on cpuset with --lcores
Contrary to the -c/-l options, where a logical core runs on the same
physical core in a 1:1 fashion (example: lcore 0 runs on core 0, lcore
16 runs on core 16), the --lcores option makes it possible to select the
physical cores on which runs a logical core.
However the current parsing code still limits the cpuset to the
[0, RTE_MAX_LCORE] range.
Example, before the patch, on a 24 cores system with RTE_MAX_LCORE == 16:
$ ./master/app/testpmd --no-huge --no-pci -m 512 --log-level *:debug \
--lcores 0@16,1@17 -- -i --total-num-mbufs 2048
EAL: Detected lcore 0 as core 0 on socket 0
EAL: Detected lcore 1 as core 1 on socket 0
EAL: Detected lcore 2 as core 2 on socket 0
EAL: Detected lcore 3 as core 3 on socket 0
EAL: Detected lcore 4 as core 4 on socket 0
EAL: Detected lcore 5 as core 5 on socket 0
EAL: Detected lcore 6 as core 6 on socket 0
EAL: Detected lcore 7 as core 8 on socket 0
EAL: Detected lcore 8 as core 9 on socket 0
EAL: Detected lcore 9 as core 10 on socket 0
EAL: Detected lcore 10 as core 11 on socket 0
EAL: Detected lcore 11 as core 12 on socket 0
EAL: Detected lcore 12 as core 13 on socket 0
EAL: Detected lcore 13 as core 14 on socket 0
EAL: Detected lcore 14 as core 0 on socket 0
EAL: Detected lcore 15 as core 1 on socket 0
EAL: Skipped lcore 16 as core 2 on socket 0
EAL: Skipped lcore 17 as core 3 on socket 0
EAL: Skipped lcore 18 as core 4 on socket 0
EAL: Skipped lcore 19 as core 5 on socket 0
EAL: Skipped lcore 20 as core 6 on socket 0
EAL: Skipped lcore 21 as core 8 on socket 0
EAL: Skipped lcore 22 as core 9 on socket 0
EAL: Skipped lcore 23 as core 10 on socket 0
EAL: Skipped lcore 24 as core 11 on socket 0
EAL: Skipped lcore 25 as core 12 on socket 0
EAL: Skipped lcore 26 as core 13 on socket 0
EAL: Skipped lcore 27 as core 14 on socket 0
EAL: Support maximum 16 logical core(s) by configuration.
EAL: Detected 16 lcore(s)
EAL: Detected 1 NUMA nodes
EAL: invalid parameter for --lcores
We can remove this limitation by using a cpuset_t (which is a more
natural type since this is what gets passed to pthread_setaffinity*
in the end).
After the patch:
$ ./master/app/testpmd --no-huge --no-pci -m 512 --log-level *:debug \
--lcores 0@16,1@17 -- -i --total-num-mbufs 2048
[...]
EAL: Master lcore 0 is ready (tid=
7f94217bbc00;cpuset=[16])
EAL: lcore 1 is ready (tid=
7f941f491700;cpuset=[17])
Signed-off-by: David Marchand <david.marchand@redhat.com>
David Marchand [Mon, 2 Dec 2019 15:42:10 +0000 (16:42 +0100)]
eal: log all detected cores on startup
Add debug logs to have a trace of unused cores for -c/-l options on
systems with more cores than RTE_MAX_LCORE.
Signed-off-by: David Marchand <david.marchand@redhat.com>
David Marchand [Mon, 2 Dec 2019 15:42:01 +0000 (16:42 +0100)]
eal: do not cache lcore detection state
We use this state in control path only for services cores and -c/-l
options.
The value is not updated when using --lcores.
Use the internal helper where needed.
Signed-off-by: David Marchand <david.marchand@redhat.com>
David Marchand [Mon, 2 Dec 2019 15:41:46 +0000 (16:41 +0100)]
eal/windows: fix cpuset macro name
Fix the name of CPU_SETSIZE in hope we can reuse it in other parts of
the dpdk manipulating some rte_cpuset_t.
Fixes:
4dc2b4d2a4cd ("eal/windows: add headers for compatibility")
Cc: stable@dpdk.org
Signed-off-by: David Marchand <david.marchand@redhat.com>
Xiaoyu Min [Mon, 20 Jan 2020 04:01:45 +0000 (06:01 +0200)]
doc: add flow dump command in testpmd guide
Explanation of flow dump command is added into testpmd functions.
Fixes:
1e8a4e97b057 ("app/testpmd: add flow dump command")
Signed-off-by: Xiaoyu Min <jackmin@mellanox.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
Bing Zhao [Mon, 20 Jan 2020 09:43:07 +0000 (11:43 +0200)]
net/mlx5: fix modify actions support limitation
In the root table, there is some limitation of total number of header
modify actions, 16 or 8 for each. But in other tables, there is no
such strict limitation. In an IPv6 case, the IP fields modifying
will occupy more actions than that in IPv4, so the total support
number should be increased in order to support as many actions as
possible for an IPv6 + TCP packet.
And in the meanwhile, the memory consumption should also be taken
into consideration because sometimes only several actions are needed.
The root table checking could also be done in low layer driver and
the error code will be returned if the actions number is over the
maximal supported value.
Fixes:
0e9d00027686 ("net/mlx5: check maximum modify actions number")
Cc: stable@dpdk.org
Signed-off-by: Bing Zhao <bingz@mellanox.com>
Acked-by: Ori Kam <orika@mellanox.com>
Acked-by: Viacheslav Ovsiienko <viacheslavo@mellanox.com>
Suanming Mou [Wed, 8 Jan 2020 10:41:09 +0000 (12:41 +0200)]
net/mlx5: fix meter suffix flow
The meter suffix flow item pointer restore is not correct to decrease
a fixed value. The incorrect operation will cause incorrect match to
the meter suffix flow, the flow create will fail once the magic number
in the wrong offset memory start with RTE_FLOW_ITEM_TYPE_END.
The pointer should decrease the real offset it increases.
Set the decrease value to the real offset the pointer increases to fix
the issue.
Fixes:
9ea9b049a960 ("net/mlx5: split meter flow")
Cc: stable@dpdk.org
Reported-by: Tonghao Zhang <xiangxia.m.yue@gmail.com>
Signed-off-by: Suanming Mou <suanmingm@mellanox.com>
Acked-by: Viacheslav Ovsiienko <viacheslavo@mellanox.com>
Dekel Peled [Thu, 16 Jan 2020 18:36:23 +0000 (20:36 +0200)]
net/mlx5: support GTP
This patch adds to MLX5 PMD support of matching on GTP item,
fields msg_type and teid, according to RFC [1].
GTP item validation and translation functions are added and called.
GTP tunnel type is added to supported tunnels.
[1] http://mails.dpdk.org/archives/dev/2019-December/152799.html
Signed-off-by: Dekel Peled <dekelp@mellanox.com>
Acked-by: Ori Kam <orika@mellanox.com>
Dekel Peled [Wed, 15 Jan 2020 21:19:39 +0000 (23:19 +0200)]
net/mlx5: optimize Rx hash fields conversion
Previous fix added translation of Rx hash fields to PRM format.
This patch optimizes the fix, to perform value translation only
if value is not zero.
In case value is zero, there is no need to translate it.
Fixes:
c3e33304a7f6 ("net/mlx5: fix setting of Rx hash fields")
Cc: stable@dpdk.org
Signed-off-by: Dekel Peled <dekelp@mellanox.com>
Acked-by: Viacheslav Ovsiienko <viacheslavo@mellanox.com>
Viacheslav Ovsiienko [Thu, 9 Jan 2020 17:16:07 +0000 (17:16 +0000)]
net/mlx5: engage free on completion queue
The free on completion queue keeps the indices of elts array,
all mbuf stored below this index should be freed on arrival
of normal send completion. In debug version it also contains
an index of completed transmitting descriptor (WQE) to check
queues synchronization.
Signed-off-by: Viacheslav Ovsiienko <viacheslavo@mellanox.com>
Acked-by: Matan Azrad <matan@mellanox.com>
Viacheslav Ovsiienko [Thu, 9 Jan 2020 17:16:06 +0000 (17:16 +0000)]
net/mlx5: add free on completion queue
The new software manged entity is introduced in Tx datapath
- free on completion queue. This queue keeps the information
how many buffers stored in elts array must freed on send
completion. Each element of the queue contains transmitting
descriptor index to be in synch with completion entries (in
debug build only) and the index in elts array to free buffers.
Signed-off-by: Viacheslav Ovsiienko <viacheslavo@mellanox.com>
Acked-by: Matan Azrad <matan@mellanox.com>
Viacheslav Ovsiienko [Thu, 9 Jan 2020 17:16:05 +0000 (17:16 +0000)]
net/mlx5: update Tx error handling routine
This is preparation step, we are going to store the index
of elts to free on completion in the dedicated free on
completion queue, this patch updates the elts freeing routine
and updates Tx error handling routine to be synced with
coming new queue.
Signed-off-by: Viacheslav Ovsiienko <viacheslavo@mellanox.com>
Acked-by: Matan Azrad <matan@mellanox.com>
Viacheslav Ovsiienko [Thu, 9 Jan 2020 17:16:04 +0000 (17:16 +0000)]
net/mlx5: move Tx complete request routine
The complete request flag is set once per Tx burst call,
the code of appropriate routine moved to the end of sending
loop. This is preparation step to remove WQE reserved field
usage to store index of elts to free.
Signed-off-by: Viacheslav Ovsiienko <viacheslavo@mellanox.com>
Acked-by: Matan Azrad <matan@mellanox.com>
Alfredo Cardigliano [Sun, 19 Jan 2020 15:53:55 +0000 (16:53 +0100)]
net/ionic: support FW version
Add support for reading the firmware version.
Signed-off-by: Alfredo Cardigliano <cardigliano@ntop.org>
Reviewed-by: Shannon Nelson <snelson@pensando.io>
Alfredo Cardigliano [Sun, 19 Jan 2020 15:53:54 +0000 (16:53 +0100)]
net/ionic: support Tx checksum
Add support for Tx checksumming.
Signed-off-by: Alfredo Cardigliano <cardigliano@ntop.org>
Reviewed-by: Shannon Nelson <snelson@pensando.io>
Alfredo Cardigliano [Sun, 19 Jan 2020 15:53:53 +0000 (16:53 +0100)]
net/ionic: add stats
Add basic, per queue and extended statistics for
RX and TX, both from the adapter and the driver.
Signed-off-by: Alfredo Cardigliano <cardigliano@ntop.org>
Reviewed-by: Shannon Nelson <snelson@pensando.io>