DPDK patches and discussions
 help / color / mirror / Atom feed
From: Tal Shnaiderman <talshn@nvidia.com>
To: <dev@dpdk.org>
Cc: <thomas@monjalon.net>, <matan@nvidia.com>, <rasland@nvidia.com>,
	<asafp@nvidia.com>, <viacheslavo@nvidia.com>, <eilong@nvidia.com>,
	<kcollins@nvidia.com>, <idanhac@nvidia.com>
Subject: [dpdk-dev] [RFC PATCH 02/12] common/mlx5: read software parsing capabilities from DevX
Date: Wed, 15 Sep 2021 13:43:38 +0300	[thread overview]
Message-ID: <20210915104348.12920-3-talshn@nvidia.com> (raw)
In-Reply-To: <20210915104348.12920-1-talshn@nvidia.com>

mlx5 in Windows needs the software parsing hca capabilities
to query the NIC for TSO and Checksum offloading support.

Added the capability as part of the capabilities
queried by the PMD using DevX.

Signed-off-by: Tal Shnaiderman <talshn@nvidia.com>
---
 drivers/common/mlx5/mlx5_devx_cmds.c | 6 ++++++
 drivers/common/mlx5/mlx5_devx_cmds.h | 3 +++
 2 files changed, 9 insertions(+)

diff --git a/drivers/common/mlx5/mlx5_devx_cmds.c b/drivers/common/mlx5/mlx5_devx_cmds.c
index 56407cc332..70ba74e112 100644
--- a/drivers/common/mlx5/mlx5_devx_cmds.c
+++ b/drivers/common/mlx5/mlx5_devx_cmds.c
@@ -991,6 +991,12 @@ mlx5_devx_cmd_query_hca_attr(void *ctx,
 					hcattr, tunnel_lro_gre);
 	attr->tunnel_lro_vxlan = MLX5_GET(per_protocol_networking_offload_caps,
 					  hcattr, tunnel_lro_vxlan);
+	attr->swp = MLX5_GET(per_protocol_networking_offload_caps,
+					  hcattr, swp);
+	attr->swp_csum = MLX5_GET(per_protocol_networking_offload_caps,
+					  hcattr, swp_csum);
+	attr->swp_lso = MLX5_GET(per_protocol_networking_offload_caps,
+					  hcattr, swp_lso);
 	attr->lro_max_msg_sz_mode = MLX5_GET
 					(per_protocol_networking_offload_caps,
 					 hcattr, lro_max_msg_sz_mode);
diff --git a/drivers/common/mlx5/mlx5_devx_cmds.h b/drivers/common/mlx5/mlx5_devx_cmds.h
index e576e30f24..caa444bc15 100644
--- a/drivers/common/mlx5/mlx5_devx_cmds.h
+++ b/drivers/common/mlx5/mlx5_devx_cmds.h
@@ -116,6 +116,9 @@ struct mlx5_hca_attr {
 	uint32_t lro_cap:1;
 	uint32_t tunnel_lro_gre:1;
 	uint32_t tunnel_lro_vxlan:1;
+	uint32_t swp:1;
+	uint32_t swp_csum:1;
+	uint32_t swp_lso:1;
 	uint32_t lro_max_msg_sz_mode:2;
 	uint32_t lro_timer_supported_periods[MLX5_LRO_NUM_SUPP_PERIODS];
 	uint16_t lro_min_mss_size;
-- 
2.16.1.windows.4


  parent reply	other threads:[~2021-09-15 10:44 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-09-15 10:43 [dpdk-dev] [RFC PATCH 00/12] Expand NIC offloads support on Windows Tal Shnaiderman
2021-09-15 10:43 ` [dpdk-dev] [RFC PATCH 01/12] net/mlx5: fix software parsing support query Tal Shnaiderman
2021-09-15 10:43 ` Tal Shnaiderman [this message]
2021-09-15 10:43 ` [dpdk-dev] [RFC PATCH 03/12] net/mlx5: query software parsing support on Windows Tal Shnaiderman
2021-09-15 10:43 ` [dpdk-dev] [RFC PATCH 04/12] net/mlx5: fix tunneling support query Tal Shnaiderman
2021-09-15 10:43 ` [dpdk-dev] [RFC PATCH 05/12] common/mlx5: read tunneling capabilities from DevX Tal Shnaiderman
2021-09-15 10:43 ` [dpdk-dev] [RFC PATCH 06/12] net/mlx5: query tunneling support on Windows Tal Shnaiderman
2021-09-15 10:43 ` [dpdk-dev] [RFC PATCH 07/12] common/mlx5: read TSO capability from DevX Tal Shnaiderman
2021-09-15 10:43 ` [dpdk-dev] [RFC PATCH 08/12] net/mlx5: support TSO offload on Windows Tal Shnaiderman
2021-09-15 10:43 ` [dpdk-dev] [RFC PATCH 09/12] common/mlx5: read VLAN capability from DevX Tal Shnaiderman
2021-09-15 10:43 ` [dpdk-dev] [RFC PATCH 10/12] net/mlx5: support VLAN stripping offload on Windows Tal Shnaiderman
2021-09-15 10:43 ` [dpdk-dev] [RFC PATCH 11/12] common/mlx5: read FCS scattering capability from DevX Tal Shnaiderman
2021-09-15 10:43 ` [dpdk-dev] [RFC PATCH 12/12] net/mlx5: support keep-CRC offload on Windows Tal Shnaiderman

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20210915104348.12920-3-talshn@nvidia.com \
    --to=talshn@nvidia.com \
    --cc=asafp@nvidia.com \
    --cc=dev@dpdk.org \
    --cc=eilong@nvidia.com \
    --cc=idanhac@nvidia.com \
    --cc=kcollins@nvidia.com \
    --cc=matan@nvidia.com \
    --cc=rasland@nvidia.com \
    --cc=thomas@monjalon.net \
    --cc=viacheslavo@nvidia.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).