Message ID | 20210118082826.1261-1-xuan.ding@intel.com (mailing list archive) |
---|---|
State | Accepted, archived |
Delegated to: | Qi Zhang |
Headers | show |
Series | [v2] net/iavf: fix VIRTHCNL_OP_SET_RSS_HENA handling | expand |
Context | Check | Description |
---|---|---|
ci/iol-mellanox-Performance | success | Performance Testing PASS |
ci/iol-mellanox-Performance | success | Performance Testing PASS |
ci/iol-testing | fail | Testing issues |
ci/iol-abi-testing | success | Testing PASS |
ci/iol-testing | warning | Testing issues |
ci/iol-abi-testing | success | Testing PASS |
ci/iol-mellanox-Functional | success | Functional Testing PASS |
ci/iol-mellanox-Functional | success | Functional Testing PASS |
ci/iol-intel-Performance | success | Performance Testing PASS |
ci/iol-intel-Functional | success | Functional Testing PASS |
ci/iol-intel-Performance | success | Performance Testing PASS |
ci/iol-intel-Functional | success | Functional Testing PASS |
ci/iol-broadcom-Functional | success | Functional Testing PASS |
ci/iol-broadcom-Functional | success | Functional Testing PASS |
ci/Intel-compilation | fail | Compilation issues |
ci/checkpatch | success | coding style OK |
> -----Original Message----- > From: Ding, Xuan <xuan.ding@intel.com> > Sent: Monday, January 18, 2021 4:28 PM > To: Zhang, Qi Z <qi.z.zhang@intel.com>; Wu, Jingjing <jingjing.wu@intel.com>; > Xing, Beilei <beilei.xing@intel.com> > Cc: dev@dpdk.org; Ding, Xuan <xuan.ding@intel.com>; stable@dpdk.org > Subject: [PATCH v2] net/iavf: fix VIRTHCNL_OP_SET_RSS_HENA handling > > Allow error to be returned for VIRTCHNL_OP_SET_RSS_HENA when set hena = 0. > Add warning that PF does not support hena = 0 now. Actually this is not a fix, it's a workaround to handle some defect in legacy kernel driver. So changed title and commit log as below: Title: workaround RSS cleanup failure handling Allow to ignore error returned from virtual channel command VIRTCHNL_OP_SET_RSS_HENA with hena = 0 due to some legacy kernel driver does not support this. Add warning message when this happen. > > Fixes: 95f2f0e9fc2a6("net/iavf: improve default RSS") The fix line should be removed. > Cc: stable@dpdk.org > > Signed-off-by: Xuan Ding <xuan.ding@intel.com> Acked by: Qi Zhang <qi.z.zhang@intel.com> Applied to dpdk-next-net-intel. Thanks Qi
Hi Qi, > -----Original Message----- > From: Zhang, Qi Z <qi.z.zhang@intel.com> > Sent: Tuesday, January 19, 2021 11:45 AM > To: Ding, Xuan <xuan.ding@intel.com>; Wu, Jingjing <jingjing.wu@intel.com>; > Xing, Beilei <beilei.xing@intel.com> > Cc: dev@dpdk.org; stable@dpdk.org > Subject: RE: [PATCH v2] net/iavf: fix VIRTHCNL_OP_SET_RSS_HENA handling > > > > > -----Original Message----- > > From: Ding, Xuan <xuan.ding@intel.com> > > Sent: Monday, January 18, 2021 4:28 PM > > To: Zhang, Qi Z <qi.z.zhang@intel.com>; Wu, Jingjing <jingjing.wu@intel.com>; > > Xing, Beilei <beilei.xing@intel.com> > > Cc: dev@dpdk.org; Ding, Xuan <xuan.ding@intel.com>; stable@dpdk.org > > Subject: [PATCH v2] net/iavf: fix VIRTHCNL_OP_SET_RSS_HENA handling > > > > Allow error to be returned for VIRTCHNL_OP_SET_RSS_HENA when set hena = > 0. > > Add warning that PF does not support hena = 0 now. > > Actually this is not a fix, it’s a workaround to handle some defect in legacy > kernel driver. > So changed title and commit log as below: > > Title: workaround RSS cleanup failure handling > > Allow to ignore error returned from virtual channel command > VIRTCHNL_OP_SET_RSS_HENA with hena = 0 due to some legacy > kernel driver does not support this. Add warning message when > this happen. > > > > > Fixes: 95f2f0e9fc2a6("net/iavf: improve default RSS") > > The fix line should be removed. > > > Cc: stable@dpdk.org Since fix line is removed, should CC to stable also be removed? Thanks for your correction. Regards, Xuan > > > > Signed-off-by: Xuan Ding <xuan.ding@intel.com> > > Acked by: Qi Zhang <qi.z.zhang@intel.com> > > Applied to dpdk-next-net-intel. > > Thanks > Qi
> -----Original Message----- > From: Ding, Xuan <xuan.ding@intel.com> > Sent: Tuesday, January 19, 2021 12:35 PM > To: Zhang, Qi Z <qi.z.zhang@intel.com>; Wu, Jingjing <jingjing.wu@intel.com>; > Xing, Beilei <beilei.xing@intel.com> > Cc: dev@dpdk.org; stable@dpdk.org > Subject: RE: [PATCH v2] net/iavf: fix VIRTHCNL_OP_SET_RSS_HENA handling > > Hi Qi, > > > -----Original Message----- > > From: Zhang, Qi Z <qi.z.zhang@intel.com> > > Sent: Tuesday, January 19, 2021 11:45 AM > > To: Ding, Xuan <xuan.ding@intel.com>; Wu, Jingjing > > <jingjing.wu@intel.com>; Xing, Beilei <beilei.xing@intel.com> > > Cc: dev@dpdk.org; stable@dpdk.org > > Subject: RE: [PATCH v2] net/iavf: fix VIRTHCNL_OP_SET_RSS_HENA > > handling > > > > > > > > > -----Original Message----- > > > From: Ding, Xuan <xuan.ding@intel.com> > > > Sent: Monday, January 18, 2021 4:28 PM > > > To: Zhang, Qi Z <qi.z.zhang@intel.com>; Wu, Jingjing > > > <jingjing.wu@intel.com>; Xing, Beilei <beilei.xing@intel.com> > > > Cc: dev@dpdk.org; Ding, Xuan <xuan.ding@intel.com>; stable@dpdk.org > > > Subject: [PATCH v2] net/iavf: fix VIRTHCNL_OP_SET_RSS_HENA handling > > > > > > Allow error to be returned for VIRTCHNL_OP_SET_RSS_HENA when set > > > hena = > > 0. > > > Add warning that PF does not support hena = 0 now. > > > > Actually this is not a fix, it's a workaround to handle some defect in > > legacy kernel driver. > > So changed title and commit log as below: > > > > Title: workaround RSS cleanup failure handling > > > > Allow to ignore error returned from virtual channel command > > VIRTCHNL_OP_SET_RSS_HENA with hena = 0 due to some legacy > > kernel driver does not support this. Add warning message when > > this happen. > > > > > > > > Fixes: 95f2f0e9fc2a6("net/iavf: improve default RSS") > > > > The fix line should be removed. > > > > > Cc: stable@dpdk.org > > Since fix line is removed, should CC to stable also be removed? Sometime we can still have CC stable to hint backport, even its not a fix. But for this patch, I think its not necessary, as the patch to enable hena=0 belongs to this release, so no workaround need to backport, thanks for the capture. > Thanks for your correction. > > Regards, > Xuan > > > > > > > Signed-off-by: Xuan Ding <xuan.ding@intel.com> > > > > Acked by: Qi Zhang <qi.z.zhang@intel.com> > > > > Applied to dpdk-next-net-intel. > > > > Thanks > > Qi >
diff --git a/drivers/net/iavf/iavf_ethdev.c b/drivers/net/iavf/iavf_ethdev.c index e22c62ed00..46857875ea 100644 --- a/drivers/net/iavf/iavf_ethdev.c +++ b/drivers/net/iavf/iavf_ethdev.c @@ -1250,11 +1250,15 @@ iavf_dev_rss_hash_update(struct rte_eth_dev *dev, if (rss_conf->rss_hf == 0) return 0; - /* Overwritten default RSS. */ + /* Clear existing RSS. */ ret = iavf_set_hena(adapter, 0); + + /* It is a workaround, temporarily allow error to be returned + * due to possible lack of PF handling for hena = 0. + */ if (ret) - PMD_DRV_LOG(ERR, "%s Remove rss vsi fail %d", - __func__, ret); + PMD_DRV_LOG(WARNING, "fail to clean existing RSS," + "lack PF support"); /* Set new RSS configuration. */ ret = iavf_rss_hash_set(adapter, rss_conf->rss_hf, true); @@ -2174,10 +2178,12 @@ iavf_dev_init(struct rte_eth_dev *eth_dev) /* Set hena = 0 to ask PF to cleanup all existing RSS. */ ret = iavf_set_hena(adapter, 0); - if (ret) { - PMD_DRV_LOG(ERR, "fail to disable default PF RSS"); - return ret; - } + if (ret) + /* It is a workaround, temporarily allow error to be returned + * due to possible lack of PF handling for hena = 0. + */ + PMD_DRV_LOG(WARNING, "fail to disable default RSS," + "lack PF support"); return 0; }
Allow error to be returned for VIRTCHNL_OP_SET_RSS_HENA when set hena = 0. Add warning that PF does not support hena = 0 now. Fixes: 95f2f0e9fc2a6("net/iavf: improve default RSS") Cc: stable@dpdk.org Signed-off-by: Xuan Ding <xuan.ding@intel.com> --- v2: * Modify the commit log to avoid a spelling error. --- drivers/net/iavf/iavf_ethdev.c | 20 +++++++++++++------- 1 file changed, 13 insertions(+), 7 deletions(-)