[PATCH] net/mlx5: fix the workspace double free in Windows

2023-10-26 Thread Bing Zhao
resources management in Windows will remain the same with some stub function when needed. Fixes: dc7c5e0aa905 ("net/mlx5: fix flow workspace destruction") Cc: getel...@nvidia.com Cc: d...@stable.org Signed-off-by: Bing Zhao Acked-by: Matan Azrad --- drivers/net/mlx5/linux/m

[PATCH] net/mlx5: fix the workspace double free in Windows

2023-10-26 Thread Bing Zhao
resources management in Windows will remain the same with some stub function when needed. Fixes: dc7c5e0aa905 ("net/mlx5: fix flow workspace destruction") Cc: getel...@nvidia.com Cc: sta...@dpdk.org Signed-off-by: Bing Zhao Acked-by: Matan Azrad --- drivers/net/mlx5/linux/m

[PATCH] net/mlx5: fix the building with flexible array

2022-10-31 Thread Bing Zhao
will help to get rid of this complain. Fixes: e848218741ea ("net/mlx5: check delay drop settings in kernel driver") Cc: sta...@dpdk.org Signed-off-by: Bing Zhao --- drivers/net/mlx5/linux/mlx5_ethdev_os.c | 22 +- 1 file changed, 13 insertions(+), 9 deletions(-)

[dpdk-dev] [PATCH v3 0/1] Change shared action API to action handle API

2021-04-15 Thread Bing Zhao
The patch set includes: 1. API changes 2. testpmd adaption and guide update 3. driver update (only net/mlx5 is impacted) 4. rte_flow documentation update --- v2: add adaptions of testpmd and driver part v3: squash all patches into one and update rte_flow doc --- Bing Zhao (1

[dpdk-dev] [PATCH v3 1/1] ethdev: introduce indirect action APIs

2021-04-15 Thread Bing Zhao
d_action*" to the new "rte_flow_action_handle*" and the "update" interface's 3rd input parameter is changed to generic pointer, the mlx5 PMD that uses these APIs needs to do the adaption to the new APIs as well. Signed-off-by: Bing Zhao Acked-by: Andrey Vesnovaty

[dpdk-dev] [PATCH v2 0/2] ethdev: introduce conntrack flow action and item

2021-04-15 Thread Bing Zhao
Depends-on: series-16419 ("Change shared action API to action handle API") This patch set includes the conntrack action and item definitions as well as the testpmd CLI proposal. --- v2: add testpmd CLI proposal --- Bing Zhao (2): ethdev: introduce conntrack flow action and item a

[dpdk-dev] [PATCH v2 1/2] ethdev: introduce conntrack flow action and item

2021-04-15 Thread Bing Zhao
ot pass. Naming and definition: https://elixir.bootlin.com/linux/latest/source/include/uapi/linux/netfilter/nf_conntrack_tcp.h https://elixir.bootlin.com/linux/latest/source/net/netfilter/nf_conntrack_proto_tcp.c Other reference: https://www.usenix.org/legacy/events/sec01/invitedtalks/rooij.pdf Sign

[dpdk-dev] [PATCH v2 2/2] app/testpmd: add CLI for conntrack

2021-04-15 Thread Bing Zhao
packet should jump to the next flow for the result checking with conntrack item. The state is defined with bits and a valid combination could be supported. Signed-off-by: Bing Zhao --- app/test-pmd/cmdline.c | 354 app/test-pmd/cmdline_flow.c | 92 +

Re: [dpdk-dev] [PATCH] ethdev: introduce conntrack flow action and item

2021-04-15 Thread Bing Zhao
Hi Ori, > -Original Message- > From: Ori Kam > Sent: Friday, April 16, 2021 12:25 AM > To: Bing Zhao ; NBU-Contact-Thomas Monjalon > ; ferruh.yi...@intel.com; > andrew.rybche...@oktetlabs.ru > Cc: dev@dpdk.org; ajit.khapa...@broadcom.com > Subject: RE: [PATCH] eth

Re: [dpdk-dev] [PATCH v3 1/1] ethdev: introduce indirect action APIs

2021-04-15 Thread Bing Zhao
Hi Ajit, > -Original Message- > From: Ajit Khaparde > Sent: Friday, April 16, 2021 2:00 AM > To: Bing Zhao > Cc: Ori Kam ; NBU-Contact-Thomas Monjalon > ; Ferruh Yigit ; Andrew > Rybchenko ; Matan Azrad > ; Slava Ovsiienko ; dpdk- > dev ; Gregory Etelson ; An

[dpdk-dev] [PATCH v4 0/1] Change shared action API to action handle API

2021-04-16 Thread Bing Zhao
error --- Bing Zhao (1): ethdev: introduce indirect action APIs app/test-pmd/cmdline.c | 24 +- app/test-pmd/cmdline_flow.c | 252 ++-- app/test-pmd/config.c | 160 ++--- app/test-pmd/testpmd.h

[dpdk-dev] [PATCH v4 1/1] ethdev: introduce indirect action APIs

2021-04-16 Thread Bing Zhao
d_action*" to the new "rte_flow_action_handle*" and the "update" interface's 3rd input parameter is changed to generic pointer, the mlx5 PMD that uses these APIs needs to do the adaption to the new APIs as well. Signed-off-by: Bing Zhao Acked-by: Andrey Vesnovaty Acked

[dpdk-dev] [PATCH v3 0/3] ethdev: introduce conntrack flow action and item

2021-04-16 Thread Bing Zhao
Depends-on: series-16451 ("Change shared action API to action handle API") This patch set includes the conntrack action and item definitions as well as the testpmd CLI proposal. Documents of release notes and guides are also updated. --- v2: add testpmd CLI proposal v3: add doc update

[dpdk-dev] [PATCH v3 1/3] ethdev: introduce conntrack flow action and item

2021-04-16 Thread Bing Zhao
x/netfilter/nf_conntrack_tcp.h https://elixir.bootlin.com/linux/latest/source/net/netfilter/nf_conntrack_proto_tcp.c Other reference: https://www.usenix.org/legacy/events/sec01/invitedtalks/rooij.pdf Signed-off-by: Bing Zhao --- lib/librte_ethdev/rte_flow.c | 2 + lib/

[dpdk-dev] [PATCH v3 2/3] app/testpmd: add CLI for conntrack

2021-04-16 Thread Bing Zhao
packet should jump to the next flow for the result checking with conntrack item. The state is defined with bits and a valid combination could be supported. Signed-off-by: Bing Zhao --- app/test-pmd/cmdline.c | 354 app/test-pmd/cmdline_flow.c | 92 +

[dpdk-dev] [PATCH v3 3/3] doc: update for conntrack

2021-04-16 Thread Bing Zhao
The updated documentations include: 1. Release notes 2. rte_flow.rst 3. testpmd user guide Signed-off-by: Bing Zhao --- doc/guides/prog_guide/rte_flow.rst | 113 doc/guides/rel_notes/release_21_05.rst | 4 + doc/guides/testpmd_app_ug/testpmd_funcs.rst

Re: [dpdk-dev] [PATCH v2 1/2] ethdev: introduce conntrack flow action and item

2021-04-16 Thread Bing Zhao
Hi Ori, My comments are inline, PSB. > -Original Message- > From: Ori Kam > Sent: Friday, April 16, 2021 8:42 PM > To: Bing Zhao ; NBU-Contact-Thomas Monjalon > ; ferruh.yi...@intel.com; > andrew.rybche...@oktetlabs.ru > Cc: dev@dpdk.org; ajit.khapa...@broadcom.com

Re: [dpdk-dev] [PATCH v2 1/2] ethdev: introduce conntrack flow action and item

2021-04-16 Thread Bing Zhao
Hi Thomas, Thanks for your comments. Almost all the comments are addressed. PSB. > -Original Message- > From: Thomas Monjalon > Sent: Friday, April 16, 2021 6:50 PM > To: Bing Zhao > Cc: Ori Kam ; ferruh.yi...@intel.com; > andrew.rybche...@oktetlabs.ru; dev@dpdk

Re: [dpdk-dev] [PATCH v2 2/2] app/testpmd: add CLI for conntrack

2021-04-16 Thread Bing Zhao
Hi Ori, > -Original Message- > From: Ori Kam > Sent: Friday, April 16, 2021 4:47 PM > To: Bing Zhao ; NBU-Contact-Thomas Monjalon > ; ferruh.yi...@intel.com; > andrew.rybche...@oktetlabs.ru > Cc: dev@dpdk.org; ajit.khapa...@broadcom.com > Subject: RE: [PATCH v2 2

Re: [dpdk-dev] [PATCH v2 1/2] ethdev: introduce conntrack flow action and item

2021-04-16 Thread Bing Zhao
Hi Ajit, > -Original Message- > From: Ajit Khaparde > Sent: Saturday, April 17, 2021 5:47 AM > To: Bing Zhao > Cc: Ori Kam ; NBU-Contact-Thomas Monjalon > ; ferruh.yi...@intel.com; > andrew.rybche...@oktetlabs.ru; dev@dpdk.org > Subject: Re: [PATCH v2 1/2] eth

[dpdk-dev] [PATCH v5] Change shared action API to action handle API

2021-04-19 Thread Bing Zhao
error v5: deprecate "RTE_FLOW_ACTION_TYPE_SHARED" and update description --- Bing Zhao (1): ethdev: introduce indirect action APIs app/test-pmd/cmdline.c | 24 +-- app/test-pmd/cmdline_flow.c | 252 ++-- app/test-pm

[dpdk-dev] [PATCH v5] ethdev: introduce indirect action APIs

2021-04-19 Thread Bing Zhao
d_action*" to the new "rte_flow_action_handle*" and the "update" interface's 3rd input parameter is changed to generic pointer, the mlx5 PMD that uses these APIs needs to do the adaption to the new APIs as well. Signed-off-by: Bing Zhao Acked-by: Andrey Vesnovaty Acked-

[dpdk-dev] [PATCH v5 1/1] ethdev: introduce indirect action APIs

2021-04-19 Thread Bing Zhao
d_action*" to the new "rte_flow_action_handle*" and the "update" interface's 3rd input parameter is changed to generic pointer, the mlx5 PMD that uses these APIs needs to do the adaption to the new APIs as well. Signed-off-by: Bing Zhao Acked-by: Andrey Vesnovaty Acked

[dpdk-dev] [PATCH v5 0/1] Change shared action API to action handle API

2021-04-19 Thread Bing Zhao
error v5: deprecate "RTE_FLOW_ACTION_TYPE_SHARED" and update description --- Bing Zhao (1): ethdev: introduce indirect action APIs app/test-pmd/cmdline.c | 24 +- app/test-pmd/cmdline_flow.c | 252 ++-- app/test-pm

Re: [dpdk-dev] [PATCH v4 1/1] ethdev: introduce indirect action APIs

2021-04-19 Thread Bing Zhao
Hi Thomas, All the comments were addressed in the v5. Many thanks. > -Original Message- > From: Thomas Monjalon > Sent: Monday, April 19, 2021 8:26 PM > To: Ori Kam ; Bing Zhao > Cc: ferruh.yi...@intel.com; andrew.rybche...@oktetlabs.ru; Matan > Azrad ; Slava Ovsiienk

Re: [dpdk-dev] [PATCH v3 1/3] ethdev: introduce conntrack flow action and item

2021-04-19 Thread Bing Zhao
Hi Thomas, > -Original Message- > From: Thomas Monjalon > Sent: Monday, April 19, 2021 10:06 PM > To: Bing Zhao > Cc: Ori Kam ; ferruh.yi...@intel.com; > andrew.rybche...@oktetlabs.ru; dev@dpdk.org; > ajit.khapa...@broadcom.com; xiaoyun...@intel.com > Subject: Re

Re: [dpdk-dev] [PATCH v3 1/3] ethdev: introduce conntrack flow action and item

2021-04-19 Thread Bing Zhao
Hi, > -Original Message- > From: Thomas Monjalon > Sent: Monday, April 19, 2021 10:08 PM > To: Bing Zhao ; Ajit Khaparde > > Cc: dev@dpdk.org; Ori Kam ; Ferruh Yigit > ; Andrew Rybchenko > ; dpdk-dev ; Xiaoyun Li > > Subject: Re: [dpdk-dev] [PATCH v3 1/

[dpdk-dev] [PATCH v4 0/3] ethdev: introduce conntrack flow action and item

2021-04-19 Thread Bing Zhao
This patch set includes the conntrack action and item definitions as well as the testpmd CLI proposal. Documents of release notes and guides are also updated. --- v2: add testpmd CLI proposal v3: add doc update v4: fix building and address comments for doc and header file --- Bing Zhao (3

[dpdk-dev] [PATCH v4 1/3] ethdev: introduce conntrack flow action and item

2021-04-19 Thread Bing Zhao
netfilter/nf_conntrack_tcp.h https://elixir.bootlin.com/linux/latest/source/net/netfilter/ nf_conntrack_proto_tcp.c Other reference: https://www.usenix.org/legacy/events/sec01/invitedtalks/rooij.pdf Signed-off-by: Bing Zhao --- lib/librte_ethdev/rte_flow.c | 2 + lib/

[dpdk-dev] [PATCH v4 3/3] doc: update for conntrack

2021-04-19 Thread Bing Zhao
The updated documentations include: 1. Release notes 2. rte_flow.rst 3. testpmd user guide Signed-off-by: Bing Zhao --- doc/guides/prog_guide/rte_flow.rst | 118 doc/guides/rel_notes/release_21_05.rst | 4 + doc/guides/testpmd_app_ug/testpmd_funcs.rst

[dpdk-dev] [PATCH v4 2/3] app/testpmd: add CLI for conntrack

2021-04-19 Thread Bing Zhao
packet should jump to the next flow for the result checking with conntrack item. The state is defined with bits and a valid combination could be supported. Signed-off-by: Bing Zhao --- app/test-pmd/cmdline.c | 355 app/test-pmd/cmdline_flow.c | 92 +

Re: [dpdk-dev] [PATCH v3 3/3] doc: update for conntrack

2021-04-19 Thread Bing Zhao
Hi Ajit, > -Original Message- > From: Ajit Khaparde > Sent: Saturday, April 17, 2021 2:30 AM > To: Bing Zhao > Cc: Ori Kam ; NBU-Contact-Thomas Monjalon > ; Ferruh Yigit ; Andrew > Rybchenko ; dpdk-dev ; > Xiaoyun Li > Subject: Re: [PATCH v3 3/3] doc: updat

[dpdk-dev] [PATCH v5 1/2] ethdev: introduce conntrack flow action and item

2021-04-19 Thread Bing Zhao
netfilter/nf_conntrack_tcp.h https://elixir.bootlin.com/linux/latest/source/net/netfilter/ nf_conntrack_proto_tcp.c Other reference: https://www.usenix.org/legacy/events/sec01/invitedtalks/rooij.pdf Signed-off-by: Bing Zhao Acked-by: Ori Kam --- doc/guides/prog_guide/rte_flow.rst

[dpdk-dev] [PATCH v5 2/2] app/testpmd: add CLI for conntrack

2021-04-19 Thread Bing Zhao
packet should jump to the next flow for the result checking with conntrack item. The state is defined with bits and a valid combination could be supported. Signed-off-by: Bing Zhao Acked-by: Ori Kam --- app/test-pmd/cmdline.c | 355 app/test-pmd/cmdline

[dpdk-dev] [PATCH v5 0/2] ethdev: introduce conntrack flow action and item

2021-04-19 Thread Bing Zhao
into ethdev and testpmd separately --- Bing Zhao (2): ethdev: introduce conntrack flow action and item app/testpmd: add CLI for conntrack app/test-pmd/cmdline.c | 355 app/test-pmd/cmdline_flow.c | 92 + app/test-pmd/config.c

Re: [dpdk-dev] [PATCH v2] mbuf: support eCPRI hardware packet type

2021-04-20 Thread Bing Zhao
Hi Lingyu, > -Original Message- > From: dev On Behalf Of Liu, Lingyu > Sent: Tuesday, April 20, 2021 10:17 AM > To: Olivier Matz > Cc: dev@dpdk.org; Zhang, Qi Z ; NBU-Contact- > Thomas Monjalon ; david.march...@redhat.com; > Hemant Agrawal > Subject: Re: [dpdk-dev] [PATCH v2] mbuf: supp

Re: [dpdk-dev] [PATCH v2] doc: fix formatting in testpmd user guide

2021-04-24 Thread Bing Zhao
Hi, > -Original Message- > From: Ferruh Yigit > Sent: Saturday, April 24, 2021 12:30 AM > To: Xiaoyun Li ; Ori Kam ; > Bing Zhao > Cc: Ferruh Yigit ; dev@dpdk.org; Ajit > Khaparde > Subject: [PATCH v2] doc: fix formatting in testpmd user guide > > Exter

[dpdk-dev] [PATCH 00/17] conntrack support in mlx5 PMD

2021-04-27 Thread Bing Zhao
This patch set adds the connection tracking offload support in the mlx5 driver. Bing Zhao (17): common/mlx5: add connection tracking object definition common/mlx5: add CT offload capability checking net/mlx5: use meter color reg for CT net/mlx5: initialization of CT management common

[dpdk-dev] [PATCH 01/17] common/mlx5: add connection tracking object definition

2021-04-27 Thread Bing Zhao
and update, as well as the query. The capabilities 2 (HCA_CAP_2) layout is also added. The connection tracking related capabilities could be queried via the HCA_CAP_2. Signed-off-by: Bing Zhao --- drivers/common/mlx5/mlx5_prm.h | 85 ++ 1 file changed, 85

[dpdk-dev] [PATCH 02/17] common/mlx5: add CT offload capability checking

2021-04-27 Thread Bing Zhao
The following CT creation should also check this capability. With the old driver, the pre-processing macro should be used in order to make the compiling pass. Signed-off-by: Bing Zhao --- drivers/common/mlx5/linux/meson.build | 2 ++ drivers/common/mlx5/mlx5_devx_cmds.c | 3 +++ drivers/common

[dpdk-dev] [PATCH 03/17] net/mlx5: use meter color reg for CT

2021-04-27 Thread Bing Zhao
Based on the capacity, 3 registers could be used. Due to the register allocation, only the one REG_C_3 for meter color could be reused right now. Then in the same flow, no more than one ASO action can be supported. Signed-off-by: Bing Zhao --- drivers/net/mlx5/mlx5_flow.c | 4 +++- drivers/net

[dpdk-dev] [PATCH 04/17] net/mlx5: initialization of CT management

2021-04-27 Thread Bing Zhao
each bulk for a better management purpose. The ASO QP for CT is initialized, the SQ will be used for both modify and query command. Signed-off-by: Bing Zhao --- drivers/net/mlx5/linux/mlx5_os.c | 13 +++ drivers/net/mlx5/mlx5.c | 36 + drivers/net/mlx5

[dpdk-dev] [PATCH 05/17] common/mlx5: add Dexv CT objects creation

2021-04-27 Thread Bing Zhao
Adding support for connection tracking ASO creation via Devx command. Right now only bulk creation is supported. By default, the objects with zero contents will be created. Before using a single object, the modification via posting a WQE to the ASO CT SQ is needed. Signed-off-by: Bing Zhao

[dpdk-dev] [PATCH 06/17] net/mlx5: add modify support for CT

2021-04-27 Thread Bing Zhao
e CQE to be generated. Signed-off-by: Bing Zhao --- drivers/net/mlx5/mlx5.h | 6 + drivers/net/mlx5/mlx5_flow.h | 3 + drivers/net/mlx5/mlx5_flow_aso.c | 288 +++ 3 files changed, 297 insertions(+) diff --git a/drivers/net/mlx5/mlx5.h b/driver

[dpdk-dev] [PATCH 07/17] net/mlx5: add actions creating for CT

2021-04-27 Thread Bing Zhao
connection tracking context associated with these actions need to be updated via WQE before using for steering. Signed-off-by: Bing Zhao --- drivers/net/mlx5/mlx5.h | 4 + drivers/net/mlx5/mlx5_flow.h| 27 - drivers/net/mlx5/mlx5_flow_dv.c | 261

[dpdk-dev] [PATCH 08/17] net/mlx5: close CT management structure

2021-04-27 Thread Bing Zhao
memory region for query should also be deregistered and then freed. Signed-off-by: Bing Zhao --- drivers/net/mlx5/mlx5.c | 56 drivers/net/mlx5/mlx5_flow_aso.c | 4 +++ 2 files changed, 60 insertions(+) diff --git a/drivers/net/mlx5/mlx5.c b

[dpdk-dev] [PATCH 09/17] net/mlx5: add ASO CT query implementation

2021-04-27 Thread Bing Zhao
-off-by: Bing Zhao --- drivers/net/mlx5/mlx5.h | 9 +- drivers/net/mlx5/mlx5_flow_aso.c | 205 +++ drivers/net/mlx5/mlx5_flow_dv.c | 10 ++ 3 files changed, 223 insertions(+), 1 deletion(-) diff --git a/drivers/net/mlx5/mlx5.h b/drivers/net/mlx5

[dpdk-dev] [PATCH 10/17] net/mlx5: add ASO CT destroy handling

2021-04-27 Thread Bing Zhao
system and will be reused directly from the free list. Signed-off-by: Bing Zhao --- drivers/net/mlx5/mlx5_flow_dv.c | 9 + 1 file changed, 9 insertions(+) diff --git a/drivers/net/mlx5/mlx5_flow_dv.c b/drivers/net/mlx5/mlx5_flow_dv.c index 9093142..f4fa3a0 100644 --- a/drivers/net/mlx5

[dpdk-dev] [PATCH 11/17] net/mlx5: add translation for CT action

2021-04-27 Thread Bing Zhao
use in the hardware. Signed-off-by: Bing Zhao --- drivers/net/mlx5/mlx5.h | 3 ++- drivers/net/mlx5/mlx5_flow.c | 9 + drivers/net/mlx5/mlx5_flow.h | 1 + drivers/net/mlx5/mlx5_flow_aso.c | 40 drivers/net/mlx5/mlx5_flow_dv.c

[dpdk-dev] [PATCH 13/17] net/mlx5: add CT context update

2021-04-27 Thread Bing Zhao
until the hardware status is updated and ready for the next flow creation. Signed-off-by: Bing Zhao --- drivers/net/mlx5/mlx5_flow_dv.c | 47 + 1 file changed, 47 insertions(+) diff --git a/drivers/net/mlx5/mlx5_flow_dv.c b/drivers/net/mlx5/mlx5_flow_dv.c

[dpdk-dev] [PATCH 12/17] net/mlx5: add translation of CT item

2021-04-27 Thread Bing Zhao
. Signed-off-by: Bing Zhao --- drivers/net/mlx5/mlx5_flow.h| 7 + drivers/net/mlx5/mlx5_flow_dv.c | 62 + 2 files changed, 69 insertions(+) diff --git a/drivers/net/mlx5/mlx5_flow.h b/drivers/net/mlx5/mlx5_flow.h index ddfc517..c52468c 100644 --- a

[dpdk-dev] [PATCH 14/17] net/mlx5: validation of CT action

2021-04-27 Thread Bing Zhao
. Currently, only the TCP protocol support connection tracking. Signed-off-by: Bing Zhao --- drivers/net/mlx5/mlx5.h | 4 +++ drivers/net/mlx5/mlx5_flow.c| 31 +++ drivers/net/mlx5/mlx5_flow_dv.c | 68 + 3 files changed, 103 insertions

[dpdk-dev] [PATCH 15/17] net/mlx5: validation of CT item

2021-04-27 Thread Bing Zhao
the state bits conflict should be checked. It is assumed that the flow with CT item will always work on the TCP traffic. Signed-off-by: Bing Zhao --- drivers/net/mlx5/mlx5_flow.h| 3 +++ drivers/net/mlx5/mlx5_flow_dv.c | 52 + 2 files changed, 55

[dpdk-dev] [PATCH 16/17] net/mlx5: reduce the reference count of CT

2021-04-27 Thread Bing Zhao
, if the context type is CT and the index valid. The release process should be handled. By default, the handling will fall back to release the age. Signed-off-by: Bing Zhao --- drivers/net/mlx5/mlx5_flow.h| 6 +- drivers/net/mlx5/mlx5_flow_dv.c | 7 ++- 2 files changed, 11 insertions

[dpdk-dev] [PATCH 17/17] net/mlx5: add support of CT between two ports

2021-04-27 Thread Bing Zhao
or query it right now. Signed-off-by: Bing Zhao --- drivers/net/mlx5/mlx5_flow.h| 57 -- drivers/net/mlx5/mlx5_flow_dv.c | 69 +++-- 2 files changed, 108 insertions(+), 18 deletions(-) diff --git a/drivers/net/mlx5

[dpdk-dev] [PATCH v2 00/17] conntrack support in mlx5 PMD

2021-05-04 Thread Bing Zhao
This patch set adds the connection tracking offload support in the mlx5 driver, as well as the documents update. --- v2: code bug fixes, commits clean up and doc update. --- Bing Zhao (17): common/mlx5: add connection tracking object definition common/mlx5: add CT offload capability checking

[dpdk-dev] [PATCH v2 02/17] common/mlx5: add CT offload capability checking

2021-05-04 Thread Bing Zhao
The following CT creation should also check this capability. With the old driver, the pre-processing macro should be used in order to make the compiling pass. Signed-off-by: Bing Zhao --- drivers/common/mlx5/linux/meson.build | 2 ++ drivers/common/mlx5/mlx5_devx_cmds.c | 3 +++ drivers/common

[dpdk-dev] [PATCH v2 01/17] common/mlx5: add connection tracking object definition

2021-05-04 Thread Bing Zhao
and update, as well as for the query. The capabilities 2 (HCA_CAP_2) layout is also added. The connection tracking related capabilities could be queried via the HCA_CAP_2. Signed-off-by: Bing Zhao --- drivers/common/mlx5/mlx5_prm.h | 85 ++ 1 file changed, 85

[dpdk-dev] [PATCH v2 03/17] net/mlx5: use meter color reg for CT

2021-05-04 Thread Bing Zhao
Based on the capacity, 3 registers could be used. Due to the register allocation, only the one REG_C_3 for meter color could be reused right now. Then in the same flow, no more than one ASO action can be supported. Signed-off-by: Bing Zhao --- drivers/net/mlx5/mlx5_flow.c | 4 +++- drivers/net

[dpdk-dev] [PATCH v2 04/17] net/mlx5: initialization of CT management

2021-05-04 Thread Bing Zhao
each bulk for a better management purpose. The ASO QP for CT is initialized, the SQ will be used for both modify and query command. Signed-off-by: Bing Zhao --- drivers/net/mlx5/linux/mlx5_os.c | 13 + drivers/net/mlx5/mlx5.c | 36 +++ drivers/net/mlx5/mlx5.h

[dpdk-dev] [PATCH v2 05/17] common/mlx5: add Dexv CT objects creation

2021-05-04 Thread Bing Zhao
Adding support for connection tracking ASO creation via Devx command. Right now only bulk creation is supported. By default, the objects with zero contents will be created. Before using a single object, the modification via posting a WQE to the ASO CT SQ is needed. Signed-off-by: Bing Zhao

[dpdk-dev] [PATCH v2 06/17] net/mlx5: add modify support for CT

2021-05-04 Thread Bing Zhao
busy waiting for the CQE to be generated. Signed-off-by: Bing Zhao --- drivers/net/mlx5/mlx5.h | 8 + drivers/net/mlx5/mlx5_flow.h | 3 + drivers/net/mlx5/mlx5_flow_aso.c | 252 +++ 3 files changed, 263 insertions(+) diff --git a/drivers/net/mlx5/mlx

[dpdk-dev] [PATCH v2 07/17] net/mlx5: add actions creating for CT

2021-05-04 Thread Bing Zhao
connection tracking context associated with these actions need to be updated via WQE before using for steering. Signed-off-by: Bing Zhao --- drivers/net/mlx5/mlx5.h | 4 + drivers/net/mlx5/mlx5_flow.h| 29 +++- drivers/net/mlx5/mlx5_flow_dv.c | 263 3

[dpdk-dev] [PATCH v2 08/17] net/mlx5: close CT management structure

2021-05-04 Thread Bing Zhao
memory region for query should also be deregistered and then freed. Signed-off-by: Bing Zhao --- drivers/net/mlx5/mlx5.c | 56 drivers/net/mlx5/mlx5_flow_aso.c | 4 +++ 2 files changed, 60 insertions(+) diff --git a/drivers/net/mlx5/mlx5.c b/drivers

[dpdk-dev] [PATCH v2 09/17] net/mlx5: add ASO CT query implementation

2021-05-04 Thread Bing Zhao
-off-by: Bing Zhao --- drivers/net/mlx5/mlx5.h | 10 +- drivers/net/mlx5/mlx5_flow_aso.c | 245 +++ drivers/net/mlx5/mlx5_flow_dv.c | 19 +++ 3 files changed, 273 insertions(+), 1 deletion(-) diff --git a/drivers/net/mlx5/mlx5.h b/drivers/net/mlx5/mlx5.h

[dpdk-dev] [PATCH v2 10/17] net/mlx5: add ASO CT destroy handling

2021-05-04 Thread Bing Zhao
system and will be reused directly from the free list. Signed-off-by: Bing Zhao --- drivers/net/mlx5/mlx5_flow_dv.c | 16 +++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/drivers/net/mlx5/mlx5_flow_dv.c b/drivers/net/mlx5/mlx5_flow_dv.c index 84e7f0b3d3..0fa0671ace

[dpdk-dev] [PATCH v2 11/17] net/mlx5: add translation of CT action

2021-05-04 Thread Bing Zhao
rule, if the context type is CT and the index is valid (non-zero), the release process should be handled. By default, the handling will fall back to try to release the ASO age if any. Signed-off-by: Bing Zhao --- drivers/net/mlx5/mlx5.h | 2 ++ drivers/net/mlx5/mlx5_flow.c | 9

[dpdk-dev] [PATCH v2 12/17] net/mlx5: add translation of CT item

2021-05-04 Thread Bing Zhao
. Signed-off-by: Bing Zhao --- drivers/net/mlx5/mlx5_flow.h| 7 drivers/net/mlx5/mlx5_flow_dv.c | 62 + 2 files changed, 69 insertions(+) diff --git a/drivers/net/mlx5/mlx5_flow.h b/drivers/net/mlx5/mlx5_flow.h index 286e3fb6a4..eb0bb42161 100644 --- a/drivers

[dpdk-dev] [PATCH v2 13/17] net/mlx5: add CT context update

2021-05-04 Thread Bing Zhao
until the hardware status is updated and ready for the next flow creation. Signed-off-by: Bing Zhao --- drivers/net/mlx5/mlx5_flow_dv.c | 56 + 1 file changed, 56 insertions(+) diff --git a/drivers/net/mlx5/mlx5_flow_dv.c b/drivers/net/mlx5/mlx5_flow_dv.c index

[dpdk-dev] [PATCH v2 15/17] net/mlx5: validation of CT item

2021-05-04 Thread Bing Zhao
the state bits conflict should be checked. It is assumed that the flow with CT item will always work on the TCP traffic. Signed-off-by: Bing Zhao --- drivers/net/mlx5/mlx5_flow.h| 3 ++ drivers/net/mlx5/mlx5_flow_dv.c | 51 + 2 files changed, 54 insertions

[dpdk-dev] [PATCH v2 16/17] net/mlx5: add support of CT between two ports

2021-05-04 Thread Bing Zhao
context or query it in current implementation. Signed-off-by: Bing Zhao --- drivers/net/mlx5/mlx5_flow.h| 57 +- drivers/net/mlx5/mlx5_flow_dv.c | 71 + 2 files changed, 110 insertions(+), 18 deletions(-) diff --git a/drivers/net/mlx5

[dpdk-dev] [PATCH v2 14/17] net/mlx5: validation of CT action

2021-05-04 Thread Bing Zhao
. Currently, only the TCP protocol support connection tracking. Signed-off-by: Bing Zhao --- drivers/net/mlx5/mlx5.h | 4 ++ drivers/net/mlx5/mlx5_flow.c| 31 +++ drivers/net/mlx5/mlx5_flow_dv.c | 69 + 3 files changed, 104 insertions(+) diff

[dpdk-dev] [PATCH v2 17/17] doc: update mlx5 support for conntrack

2021-05-04 Thread Bing Zhao
In the release notes and mlx5 NIC document, the support and limitation of connection tracking are added. Signed-off-by: Bing Zhao --- doc/guides/nics/features/default.ini | 1 + doc/guides/nics/features/mlx5.ini | 1 + doc/guides/nics/mlx5.rst | 14 ++ doc

[dpdk-dev] [PATCH v3 00/17] conntrack support in mlx5 PMD

2021-05-04 Thread Bing Zhao
This patch set adds the connection tracking offload support in the mlx5 driver, as well as the documents update. --- v2: code bug fixes, commits clean up and doc update. v3: fix error input pointer for CT MR registering --- Acked-by: Viacheslav Ovsiienko Bing Zhao (17): common/mlx5: add

[dpdk-dev] [PATCH v3 01/17] common/mlx5: add connection tracking object definition

2021-05-04 Thread Bing Zhao
and update, as well as for the query. The capabilities 2 (HCA_CAP_2) layout is also added. The connection tracking related capabilities could be queried via the HCA_CAP_2. Signed-off-by: Bing Zhao --- drivers/common/mlx5/mlx5_prm.h | 85 ++ 1 file changed, 85

[dpdk-dev] [PATCH v3 02/17] common/mlx5: add CT offload capability checking

2021-05-04 Thread Bing Zhao
The following CT creation should also check this capability. With the old driver, the pre-processing macro should be used in order to make the compiling pass. Signed-off-by: Bing Zhao --- drivers/common/mlx5/linux/meson.build | 2 ++ drivers/common/mlx5/mlx5_devx_cmds.c | 3 +++ drivers/common

[dpdk-dev] [PATCH v3 03/17] net/mlx5: use meter color reg for CT

2021-05-04 Thread Bing Zhao
Based on the capacity, 3 registers could be used. Due to the register allocation, only the one REG_C_3 for meter color could be reused right now. Then in the same flow, no more than one ASO action can be supported. Signed-off-by: Bing Zhao --- drivers/net/mlx5/mlx5_flow.c | 4 +++- drivers/net

[dpdk-dev] [PATCH v3 04/17] net/mlx5: initialization of CT management

2021-05-04 Thread Bing Zhao
each bulk for a better management purpose. The ASO QP for CT is initialized, the SQ will be used for both modify and query command. Signed-off-by: Bing Zhao --- drivers/net/mlx5/linux/mlx5_os.c | 13 + drivers/net/mlx5/mlx5.c | 36 +++ drivers/net/mlx5/mlx5.h

[dpdk-dev] [PATCH v3 05/17] common/mlx5: add Dexv CT objects creation

2021-05-04 Thread Bing Zhao
Adding support for connection tracking ASO creation via Devx command. Right now only bulk creation is supported. By default, the objects with zero contents will be created. Before using a single object, the modification via posting a WQE to the ASO CT SQ is needed. Signed-off-by: Bing Zhao

[dpdk-dev] [PATCH v3 06/17] net/mlx5: add modify support for CT

2021-05-04 Thread Bing Zhao
busy waiting for the CQE to be generated. Signed-off-by: Bing Zhao --- drivers/net/mlx5/mlx5.h | 8 + drivers/net/mlx5/mlx5_flow.h | 3 + drivers/net/mlx5/mlx5_flow_aso.c | 252 +++ 3 files changed, 263 insertions(+) diff --git a/drivers/net/mlx5/mlx

[dpdk-dev] [PATCH v3 07/17] net/mlx5: add actions creating for CT

2021-05-04 Thread Bing Zhao
connection tracking context associated with these actions need to be updated via WQE before using for steering. Signed-off-by: Bing Zhao --- drivers/net/mlx5/mlx5.h | 4 + drivers/net/mlx5/mlx5_flow.h| 29 +++- drivers/net/mlx5/mlx5_flow_dv.c | 263 3

[dpdk-dev] [PATCH v3 09/17] net/mlx5: add ASO CT query implementation

2021-05-04 Thread Bing Zhao
-off-by: Bing Zhao --- drivers/net/mlx5/mlx5.h | 10 +- drivers/net/mlx5/mlx5_flow_aso.c | 245 +++ drivers/net/mlx5/mlx5_flow_dv.c | 19 +++ 3 files changed, 273 insertions(+), 1 deletion(-) diff --git a/drivers/net/mlx5/mlx5.h b/drivers/net/mlx5/mlx5.h

[dpdk-dev] [PATCH v3 10/17] net/mlx5: add ASO CT destroy handling

2021-05-04 Thread Bing Zhao
system and will be reused directly from the free list. Signed-off-by: Bing Zhao --- drivers/net/mlx5/mlx5_flow_dv.c | 16 +++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/drivers/net/mlx5/mlx5_flow_dv.c b/drivers/net/mlx5/mlx5_flow_dv.c index 84e7f0b3d3..0fa0671ace

[dpdk-dev] [PATCH v3 08/17] net/mlx5: close CT management structure

2021-05-04 Thread Bing Zhao
memory region for query should also be deregistered and then freed. Signed-off-by: Bing Zhao --- drivers/net/mlx5/mlx5.c | 56 drivers/net/mlx5/mlx5_flow_aso.c | 4 +++ 2 files changed, 60 insertions(+) diff --git a/drivers/net/mlx5/mlx5.c b/drivers

[dpdk-dev] [PATCH v3 11/17] net/mlx5: add translation of CT action

2021-05-04 Thread Bing Zhao
rule, if the context type is CT and the index is valid (non-zero), the release process should be handled. By default, the handling will fall back to try to release the ASO age if any. Signed-off-by: Bing Zhao --- drivers/net/mlx5/mlx5.h | 2 ++ drivers/net/mlx5/mlx5_flow.c | 9

[dpdk-dev] [PATCH v3 12/17] net/mlx5: add translation of CT item

2021-05-04 Thread Bing Zhao
. Signed-off-by: Bing Zhao --- drivers/net/mlx5/mlx5_flow.h| 7 drivers/net/mlx5/mlx5_flow_dv.c | 62 + 2 files changed, 69 insertions(+) diff --git a/drivers/net/mlx5/mlx5_flow.h b/drivers/net/mlx5/mlx5_flow.h index 286e3fb6a4..eb0bb42161 100644 --- a/drivers

[dpdk-dev] [PATCH v3 13/17] net/mlx5: add CT context update

2021-05-04 Thread Bing Zhao
until the hardware status is updated and ready for the next flow creation. Signed-off-by: Bing Zhao --- drivers/net/mlx5/mlx5_flow_dv.c | 56 + 1 file changed, 56 insertions(+) diff --git a/drivers/net/mlx5/mlx5_flow_dv.c b/drivers/net/mlx5/mlx5_flow_dv.c index

[dpdk-dev] [PATCH v3 14/17] net/mlx5: validation of CT action

2021-05-04 Thread Bing Zhao
. Currently, only the TCP protocol support connection tracking. Signed-off-by: Bing Zhao --- drivers/net/mlx5/mlx5.h | 4 ++ drivers/net/mlx5/mlx5_flow.c| 31 +++ drivers/net/mlx5/mlx5_flow_dv.c | 69 + 3 files changed, 104 insertions(+) diff

[dpdk-dev] [PATCH v3 15/17] net/mlx5: validation of CT item

2021-05-04 Thread Bing Zhao
the state bits conflict should be checked. It is assumed that the flow with CT item will always work on the TCP traffic. Signed-off-by: Bing Zhao --- drivers/net/mlx5/mlx5_flow.h| 3 ++ drivers/net/mlx5/mlx5_flow_dv.c | 51 + 2 files changed, 54 insertions

[dpdk-dev] [PATCH v3 16/17] net/mlx5: add support of CT between two ports

2021-05-04 Thread Bing Zhao
context or query it in current implementation. Signed-off-by: Bing Zhao --- drivers/net/mlx5/mlx5_flow.h| 57 +- drivers/net/mlx5/mlx5_flow_dv.c | 71 + 2 files changed, 110 insertions(+), 18 deletions(-) diff --git a/drivers/net/mlx5

[dpdk-dev] [PATCH v3 00/17] conntrack support in mlx5 PMD

2021-05-04 Thread Bing Zhao
This patch set adds the connection tracking offload support in the mlx5 driver, as well as the documents update. --- v2: code bug fixes, commits clean up and doc update. v3: fix error input pointer for CT MR registering --- Acked-by: Viacheslav Ovsiienko Bing Zhao (17): common/mlx5: add

[dpdk-dev] [PATCH v3 02/17] common/mlx5: add CT offload capability checking

2021-05-04 Thread Bing Zhao
The following CT creation should also check this capability. With the old driver, the pre-processing macro should be used in order to make the compiling pass. Signed-off-by: Bing Zhao --- drivers/common/mlx5/linux/meson.build | 2 ++ drivers/common/mlx5/mlx5_devx_cmds.c | 3 +++ drivers/common

[dpdk-dev] [PATCH v3 01/17] common/mlx5: add connection tracking object definition

2021-05-04 Thread Bing Zhao
and update, as well as for the query. The capabilities 2 (HCA_CAP_2) layout is also added. The connection tracking related capabilities could be queried via the HCA_CAP_2. Signed-off-by: Bing Zhao --- drivers/common/mlx5/mlx5_prm.h | 85 ++ 1 file changed, 85

[dpdk-dev] [PATCH v3 03/17] net/mlx5: use meter color reg for CT

2021-05-04 Thread Bing Zhao
Based on the capacity, 3 registers could be used. Due to the register allocation, only the one REG_C_3 for meter color could be reused right now. Then in the same flow, no more than one ASO action can be supported. Signed-off-by: Bing Zhao --- drivers/net/mlx5/mlx5_flow.c | 4 +++- drivers/net

[dpdk-dev] [PATCH v3 04/17] net/mlx5: initialization of CT management

2021-05-04 Thread Bing Zhao
each bulk for a better management purpose. The ASO QP for CT is initialized, the SQ will be used for both modify and query command. Signed-off-by: Bing Zhao --- drivers/net/mlx5/linux/mlx5_os.c | 13 + drivers/net/mlx5/mlx5.c | 36 +++ drivers/net/mlx5/mlx5.h

[dpdk-dev] [PATCH v3 05/17] common/mlx5: add Dexv CT objects creation

2021-05-04 Thread Bing Zhao
Adding support for connection tracking ASO creation via Devx command. Right now only bulk creation is supported. By default, the objects with zero contents will be created. Before using a single object, the modification via posting a WQE to the ASO CT SQ is needed. Signed-off-by: Bing Zhao

[dpdk-dev] [PATCH v3 06/17] net/mlx5: add modify support for CT

2021-05-04 Thread Bing Zhao
busy waiting for the CQE to be generated. Signed-off-by: Bing Zhao --- drivers/net/mlx5/mlx5.h | 8 + drivers/net/mlx5/mlx5_flow.h | 3 + drivers/net/mlx5/mlx5_flow_aso.c | 252 +++ 3 files changed, 263 insertions(+) diff --git a/drivers/net/mlx5/mlx

[dpdk-dev] [PATCH v3 07/17] net/mlx5: add actions creating for CT

2021-05-04 Thread Bing Zhao
connection tracking context associated with these actions need to be updated via WQE before using for steering. Signed-off-by: Bing Zhao --- drivers/net/mlx5/mlx5.h | 4 + drivers/net/mlx5/mlx5_flow.h| 29 +++- drivers/net/mlx5/mlx5_flow_dv.c | 263 3

[dpdk-dev] [PATCH v3 08/17] net/mlx5: close CT management structure

2021-05-04 Thread Bing Zhao
memory region for query should also be deregistered and then freed. Signed-off-by: Bing Zhao --- drivers/net/mlx5/mlx5.c | 56 drivers/net/mlx5/mlx5_flow_aso.c | 4 +++ 2 files changed, 60 insertions(+) diff --git a/drivers/net/mlx5/mlx5.c b/drivers

[dpdk-dev] [PATCH v3 09/17] net/mlx5: add ASO CT query implementation

2021-05-04 Thread Bing Zhao
-off-by: Bing Zhao --- drivers/net/mlx5/mlx5.h | 10 +- drivers/net/mlx5/mlx5_flow_aso.c | 245 +++ drivers/net/mlx5/mlx5_flow_dv.c | 19 +++ 3 files changed, 273 insertions(+), 1 deletion(-) diff --git a/drivers/net/mlx5/mlx5.h b/drivers/net/mlx5/mlx5.h

  1   2   3   4   5   6   7   >