[v2] net/ice: fix missing MTU value setting

Message ID 20220408014308.254310-1-kevinx.liu@intel.com (mailing list archive)
State Accepted, archived
Delegated to: Qi Zhang
Headers
Series [v2] net/ice: fix missing MTU value setting |

Checks

Context Check Description
ci/checkpatch success coding style OK
ci/iol-aarch64-unit-testing success Testing PASS
ci/iol-intel-Functional success Functional Testing PASS
ci/iol-intel-Performance success Performance Testing PASS
ci/iol-aarch64-compile-testing success Testing PASS
ci/iol-x86_64-unit-testing success Testing PASS
ci/iol-abi-testing success Testing PASS
ci/iol-x86_64-compile-testing success Testing PASS

Commit Message

Kevin Liu April 8, 2022, 1:43 a.m. UTC
  In the DCF module, Missing maximum and minimum
MTU value settings.

This patch adds the settings of the maximum and
minimum MTU to correctly calculate the MTU value.

Fixes: bf89db4409bb ("net/ice: complete device info get in DCF")
Cc: stable@dpdk.org

v2:
- update fixline

Signed-off-by: Kevin Liu <kevinx.liu@intel.com>
---
 drivers/net/ice/ice_dcf_ethdev.c | 2 ++
 1 file changed, 2 insertions(+)
  

Comments

Qi Zhang May 18, 2022, 3:48 a.m. UTC | #1
> -----Original Message-----
> From: Liu, KevinX <kevinx.liu@intel.com>
> Sent: Friday, April 8, 2022 9:43 AM
> To: dev@dpdk.org
> Cc: Yang, Qiming <qiming.yang@intel.com>; Zhang, Qi Z
> <qi.z.zhang@intel.com>; Yang, SteveX <stevex.yang@intel.com>; Liu, KevinX
> <kevinx.liu@intel.com>; stable@dpdk.org
> Subject: [PATCH v2] net/ice: fix missing MTU value setting
> 
> In the DCF module, Missing maximum and minimum MTU value settings.
> 
> This patch adds the settings of the maximum and minimum MTU to correctly
> calculate the MTU value.
> 
> Fixes: bf89db4409bb ("net/ice: complete device info get in DCF")
> Cc: stable@dpdk.org

Fix for current version no need cc stable.

> 
> v2:
> - update fixline
> 

Change log should not be part of commit log

Please remind these next time.

> Signed-off-by: Kevin Liu <kevinx.liu@intel.com>

Acked-by: Qi Zhang <qi.z.zhang@intel.com>

Applied to dpdk-next-net-intel.

Thanks
Qi
  
Thomas Monjalon June 3, 2022, 9:17 a.m. UTC | #2
18/05/2022 05:48, Zhang, Qi Z:
> > From: Liu, KevinX <kevinx.liu@intel.com>
> > Subject: [PATCH v2] net/ice: fix missing MTU value setting
> > 
> > In the DCF module, Missing maximum and minimum MTU value settings.
> > 
> > This patch adds the settings of the maximum and minimum MTU to correctly
> > calculate the MTU value.
> > 
> > Fixes: bf89db4409bb ("net/ice: complete device info get in DCF")
> > Cc: stable@dpdk.org
> 
> Fix for current version no need cc stable.

It is a patch from 20.08, so need Cc stable.
In any case, you should run devtools/check-git-log.sh
  
Qi Zhang June 4, 2022, 1:21 a.m. UTC | #3
> -----Original Message-----
> From: Thomas Monjalon <thomas@monjalon.net>
> Sent: Friday, June 3, 2022 5:17 PM
> To: Zhang, Qi Z <qi.z.zhang@intel.com>
> Cc: Liu, KevinX <kevinx.liu@intel.com>; dev@dpdk.org; stable@dpdk.org; Yang,
> Qiming <qiming.yang@intel.com>; Yang, SteveX <stevex.yang@intel.com>;
> stable@dpdk.org; Mcnamara, John <john.mcnamara@intel.com>;
> ferruh.yigit@amd.com; andrew.rybchenko@oktetlabs.ru
> Subject: Re: [PATCH v2] net/ice: fix missing MTU value setting
> 
> 18/05/2022 05:48, Zhang, Qi Z:
> > > From: Liu, KevinX <kevinx.liu@intel.com>
> > > Subject: [PATCH v2] net/ice: fix missing MTU value setting
> > >
> > > In the DCF module, Missing maximum and minimum MTU value settings.
> > >
> > > This patch adds the settings of the maximum and minimum MTU to
> > > correctly calculate the MTU value.
> > >
> > > Fixes: bf89db4409bb ("net/ice: complete device info get in DCF")
> > > Cc: stable@dpdk.org
> >
> > Fix for current version no need cc stable.
> 
> It is a patch from 20.08, so need Cc stable.

Yes, it is. I messed it up with another patch , have fixed this in dpdk-next-net-intel.

> In any case, you should run devtools/check-git-log.sh

Of cause I did.  but I didn't notice the tool will skip cc stable warning if the fix belongs to the current release, thanks for you hint.

> 
>
  

Patch

diff --git a/drivers/net/ice/ice_dcf_ethdev.c b/drivers/net/ice/ice_dcf_ethdev.c
index 8005eb2ab8..0da267db1f 100644
--- a/drivers/net/ice/ice_dcf_ethdev.c
+++ b/drivers/net/ice/ice_dcf_ethdev.c
@@ -713,6 +713,8 @@  ice_dcf_dev_info_get(struct rte_eth_dev *dev,
 	dev_info->reta_size = hw->vf_res->rss_lut_size;
 	dev_info->flow_type_rss_offloads = ICE_RSS_OFFLOAD_ALL;
 	dev_info->dev_capa &= ~RTE_ETH_DEV_CAPA_FLOW_RULE_KEEP;
+	dev_info->max_mtu = dev_info->max_rx_pktlen - ICE_ETH_OVERHEAD;
+	dev_info->min_mtu = RTE_ETHER_MIN_MTU;
 
 	dev_info->rx_offload_capa =
 		RTE_ETH_RX_OFFLOAD_VLAN_STRIP |