[PATCH v9 3/9] net/hns3: report RSS hash algorithms capability

Jie Hai haijie1 at huawei.com
Thu Nov 2 09:20:14 CET 2023


The hns3 driver should reports RSS hash algorithm capability
to support updating RSS hash algorithm by
rte_eth_dev_rss_hash_update() or rte_eth_dev_configure().

Signed-off-by: Jie Hai <haijie1 at huawei.com>
Acked-by: Huisong Li <lihuisong at huawei.com>
Acked-by: Chengwen Feng <fengchengwen at huawei.com>
---
 drivers/net/hns3/hns3_common.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/drivers/net/hns3/hns3_common.c b/drivers/net/hns3/hns3_common.c
index 9327adbdc113..ff205426fab8 100644
--- a/drivers/net/hns3/hns3_common.c
+++ b/drivers/net/hns3/hns3_common.c
@@ -133,6 +133,10 @@ hns3_dev_infos_get(struct rte_eth_dev *eth_dev, struct rte_eth_dev_info *info)
 	info->reta_size = hw->rss_ind_tbl_size;
 	info->hash_key_size = hw->rss_key_size;
 	info->flow_type_rss_offloads = HNS3_ETH_RSS_SUPPORT;
+	info->rss_algo_capa = RTE_ETH_HASH_ALGO_CAPA_MASK(DEFAULT) |
+			      RTE_ETH_HASH_ALGO_CAPA_MASK(TOEPLITZ) |
+			      RTE_ETH_HASH_ALGO_CAPA_MASK(SIMPLE_XOR) |
+			      RTE_ETH_HASH_ALGO_CAPA_MASK(SYMMETRIC_TOEPLITZ);
 
 	info->default_rxportconf.burst_size = HNS3_DEFAULT_PORT_CONF_BURST_SIZE;
 	info->default_txportconf.burst_size = HNS3_DEFAULT_PORT_CONF_BURST_SIZE;
-- 
2.30.0



More information about the dev mailing list