From: Stephen Hemminger <stephen@networkplumber.org>
To: Junlong Wang <wang.junlong1@zte.com.cn>
Cc: dev@dpdk.org
Subject: Re: [PATCH v1 3/3] net/zxdh: modify RSS related issues
Date: Mon, 16 Jun 2025 09:22:42 -0700 [thread overview]
Message-ID: <20250616092242.04edbb86@hermes.local> (raw)
In-Reply-To: <20250607023020.3051575-3-wang.junlong1@zte.com.cn>
On Sat, 7 Jun 2025 10:30:20 +0800
Junlong Wang <wang.junlong1@zte.com.cn> wrote:
> modify rss related issues in testing process.
Better commit message please. Should have Fixes: tabg.
>
> Signed-off-by: Junlong Wang <wang.junlong1@zte.com.cn>
> ---
> drivers/net/zxdh/zxdh_ethdev.c | 1 +
> drivers/net/zxdh/zxdh_ethdev_ops.c | 66 +++++++++++++++++++-----------
> drivers/net/zxdh/zxdh_ethdev_ops.h | 4 +-
> drivers/net/zxdh/zxdh_msg.c | 12 +++---
> drivers/net/zxdh/zxdh_tables.c | 8 ++--
> 5 files changed, 54 insertions(+), 37 deletions(-)
>
> diff --git a/drivers/net/zxdh/zxdh_ethdev.c b/drivers/net/zxdh/zxdh_ethdev.c
> index 9512aff99c..a245ab24ce 100644
> --- a/drivers/net/zxdh/zxdh_ethdev.c
> +++ b/drivers/net/zxdh/zxdh_ethdev.c
> @@ -66,6 +66,7 @@ zxdh_dev_infos_get(struct rte_eth_dev *dev,
> dev_info->rx_offload_capa |= RTE_ETH_RX_OFFLOAD_TCP_LRO;
> dev_info->rx_offload_capa |= RTE_ETH_RX_OFFLOAD_RSS_HASH;
>
> + dev_info->hash_key_size = ZXDH_RSS_HASH_KEY_LEN;
> dev_info->reta_size = RTE_ETH_RSS_RETA_SIZE_256;
> dev_info->flow_type_rss_offloads = ZXDH_RSS_HF;
>
> diff --git a/drivers/net/zxdh/zxdh_ethdev_ops.c b/drivers/net/zxdh/zxdh_ethdev_ops.c
> index c16271aeaf..86517d571a 100644
> --- a/drivers/net/zxdh/zxdh_ethdev_ops.c
> +++ b/drivers/net/zxdh/zxdh_ethdev_ops.c
> @@ -289,7 +289,7 @@ zxdh_link_info_get(struct rte_eth_dev *dev, struct rte_eth_link *link)
> zxdh_pci_read_dev_config(hw, offsetof(struct zxdh_net_config, status),
> &status, sizeof(status));
>
> - link->link_status = status;
> + link->link_status = status & hw->admin_status;
>
> if (status == RTE_ETH_LINK_DOWN) {
> link->link_speed = RTE_ETH_SPEED_NUM_UNKNOWN;
> @@ -1207,7 +1207,7 @@ zxdh_rss_hf_to_hw(uint64_t hf)
> }
>
> static uint64_t
> -zxdh_rss_hf_to_eth(uint32_t hw_hf)
> +zxdh_rss_hf_to_eth(uint64_t hw_hf)
> {
> uint64_t hf = 0;
>
> @@ -1245,7 +1245,7 @@ zxdh_rss_hash_update(struct rte_eth_dev *dev,
> hw_hf_new = zxdh_rss_hf_to_hw(rss_conf->rss_hf);
> hw_hf_old = zxdh_rss_hf_to_hw(old_rss_conf->rss_hf);
>
> - if ((hw_hf_new != hw_hf_old || !!rss_conf->rss_hf))
> + if ((hw_hf_new != hw_hf_old || hw->rss_enable != (!!rss_conf->rss_hf)))
You don't needs so many () here. Just:
if (hw_hf_new != hw_hf_old || hw->rss_enable != !!rss_conf->rss_hf)
next prev parent reply other threads:[~2025-06-16 16:23 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-06-07 2:30 [PATCH v1 1/3] net/zxdh: modify some MAC config issues Junlong Wang
2025-06-07 2:30 ` [PATCH v1 2/3] net/zxdh: modify some VLAN related issues Junlong Wang
2025-06-16 16:20 ` Stephen Hemminger
2025-06-07 2:30 ` [PATCH v1 3/3] net/zxdh: modify RSS " Junlong Wang
2025-06-16 16:22 ` Stephen Hemminger [this message]
2025-06-12 0:14 ` [PATCH v1 1/3] net/zxdh: modify some MAC config issues Thomas Monjalon
2025-06-12 1:18 ` Junlong Wang
2025-06-16 16:16 ` Stephen Hemminger
2025-06-17 2:04 ` [PATCH v2 1/5] net/zxdh: fix meson.build issus in compilation Junlong Wang
2025-06-17 2:05 ` [PATCH v2 2/5] net/zxdh: modify some MAC config issues Junlong Wang
2025-06-17 2:05 ` [PATCH v2 3/5] net/zxdh: modify some VLAN related issues Junlong Wang
2025-06-17 2:05 ` [PATCH v2 4/5] net/zxdh: modify RSS " Junlong Wang
2025-06-17 2:05 ` [PATCH v2 5/5] net/zxdh: add support VLAN TPID set ops Junlong Wang
2025-06-17 3:32 ` zhoumin
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=20250616092242.04edbb86@hermes.local \
--to=stephen@networkplumber.org \
--cc=dev@dpdk.org \
--cc=wang.junlong1@zte.com.cn \
/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).