[dpdk-dev] [PATCH 3/3] net/i40e: remove teardown when flush FDIR filter

Xing, Beilei beilei.xing at intel.com
Tue Apr 28 03:13:26 CEST 2020



> -----Original Message-----
> From: Zhao1, Wei <wei.zhao1 at intel.com>
> Sent: Monday, April 27, 2020 3:15 PM
> To: dev at dpdk.org
> Cc: Xing, Beilei <beilei.xing at intel.com>; maxime.leroy at 6wind.com;
> stable at dpdk.org; Zhao1, Wei <wei.zhao1 at intel.com>
> Subject: [PATCH 3/3] net/i40e: remove teardown when flush FDIR filter
> 
> When we flush FDIR filter, we can not call i40e_fdir_teardown() function as it
> will free vsi used for FDIR, then the vsi->base_queue will be freed from pf-
> >qp_pool, but vsi->base_queue can only get once when do dev init in
> i40e_pf_setup(). If we free it, it will never be alloc again.

Then we should teardown fdir in dev_uninit, right?

> 
> Bugzilla ID: 404
> Fixes: 2e67a7fbf3ff ("net/i40e: config flow director automatically")
> Cc: stable at dpdk.org
> 
> Signed-off-by: Wei Zhao <wei.zhao1 at intel.com>
> ---
>  drivers/net/i40e/i40e_flow.c | 3 ---
>  1 file changed, 3 deletions(-)
> 
> diff --git a/drivers/net/i40e/i40e_flow.c b/drivers/net/i40e/i40e_flow.c index
> 1533d5abb..65f877866 100644
> --- a/drivers/net/i40e/i40e_flow.c
> +++ b/drivers/net/i40e/i40e_flow.c
> @@ -5145,7 +5145,6 @@ i40e_flow_destroy(struct rte_eth_dev *dev,
> 
>  		/* If the last flow is destroyed, disable fdir. */
>  		if (!ret && TAILQ_EMPTY(&pf->fdir.fdir_list)) {
> -			i40e_fdir_teardown(pf);
>  			i40e_fdir_rx_proc_enable(dev, 0);
>  		}
>  		break;
> @@ -5343,8 +5342,6 @@ i40e_flow_flush_fdir_filter(struct i40e_pf *pf)
>  			pf->fdir.inset_flag[pctype] = 0;
>  	}
> 
> -	i40e_fdir_teardown(pf);
> -
>  	return ret;
>  }
> 
> --
> 2.19.1



More information about the dev mailing list