diff mbox series

[v3,2/2] net/iavf: fix wrong RSS hash update

Message ID 20210305060424.21917-1-wenjun1.wu@intel.com (mailing list archive)
State Superseded
Delegated to: Qi Zhang
Headers show
Series [v3,1/2] net/ice: fix wrong RSS hash update | expand

Checks

Context Check Description
ci/iol-abi-testing success Testing PASS
ci/iol-testing success Testing PASS
ci/github-robot success github build: passed
ci/travis-robot success travis build: passed
ci/iol-intel-Performance success Performance Testing PASS
ci/iol-mellanox-Performance success Performance Testing PASS
ci/iol-mellanox-Functional success Functional Testing PASS
ci/intel-Testing success Testing PASS
ci/Intel-compilation success Compilation OK
ci/checkpatch success coding style OK

Commit Message

Wenjun Wu March 5, 2021, 6:04 a.m. UTC
This patch change judgment statements to disable RSS for vf
when users need to disable RSS or RSS hash function configured
is not supported.

Fixes: 95f2f0e9fc2a ("net/iavf: improve default RSS")
Cc: stable@dpdk.org

Signed-off-by: Wenjun Wu <wenjun1.wu@intel.com>

---
v3: fix the same issue for both pf and vf.
---
 drivers/net/iavf/iavf_ethdev.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

Comments

Ferruh Yigit March 24, 2021, 2:46 p.m. UTC | #1
On 3/5/2021 6:04 AM, Wenjun Wu wrote:
> This patch change judgment statements to disable RSS for vf
> when users need to disable RSS or RSS hash function configured
> is not supported.
> 
> Fixes: 95f2f0e9fc2a ("net/iavf: improve default RSS")
> Cc: stable@dpdk.org
> 
> Signed-off-by: Wenjun Wu <wenjun1.wu@intel.com>
> 

for record,
1/2 merged to next-net-intel, but there is v4 for iavf one and this version is 
not merged.
diff mbox series

Patch

diff --git a/drivers/net/iavf/iavf_ethdev.c b/drivers/net/iavf/iavf_ethdev.c
index 4d3772202..d2d950aa6 100644
--- a/drivers/net/iavf/iavf_ethdev.c
+++ b/drivers/net/iavf/iavf_ethdev.c
@@ -1250,8 +1250,10 @@  iavf_dev_rss_hash_update(struct rte_eth_dev *dev,
 	if (ret)
 		return ret;
 
-	if (rss_conf->rss_hf == 0)
+	if (rss_conf->rss_hf == 0) {
+		vf->rss_hf = 0;
 		return 0;
+	}
 
 	if (vf->vf_res->vf_cap_flags & VIRTCHNL_VF_OFFLOAD_ADV_RSS_PF) {
 		/* Clear existing RSS. */