DPDK patches and discussions
 help / color / mirror / Atom feed
From: "Zhao1, Wei" <wei.zhao1@intel.com>
To: "Guo, Jia" <jia.guo@intel.com>, "dev@dpdk.org" <dev@dpdk.org>
Cc: "stable@dpdk.org" <stable@dpdk.org>,
	"Xing, Beilei" <beilei.xing@intel.com>
Subject: Re: [dpdk-dev] [PATCH] net/i40e: fix flow FDIR enable issue
Date: Wed, 20 May 2020 03:22:30 +0000	[thread overview]
Message-ID: <MWHPR11MB13919F5336A492579055DE2AB7B60@MWHPR11MB1391.namprd11.prod.outlook.com> (raw)
In-Reply-To: <b0efaac3-da2c-07c5-2ab6-e7fe3faea5ea@intel.com>


Hi, guojia

> -----Original Message-----
> From: Guo, Jia <jia.guo@intel.com>
> Sent: Wednesday, May 20, 2020 11:19 AM
> To: Zhao1, Wei <wei.zhao1@intel.com>; dev@dpdk.org
> Cc: stable@dpdk.org; Xing, Beilei <beilei.xing@intel.com>
> Subject: Re: [PATCH] net/i40e: fix flow FDIR enable issue
> 
> hi, zhaowei
> 
> On 5/19/2020 3:16 PM, Wei Zhao wrote:
> > When we flush flow FDIR, all queues are disabled for FDIR.
> > If FDIR rule is created again, then the flow list is empty, as it is
> > the first time to create rule after flush fdir filter, so we need to
> > enable FDRI for all queues. And also, disable FDIR
> 
> 
> typo: FDRI -> FDIR, and could you modify something commit if you agree on
> below inline comment. Thanks.

Ok,

> 
> 
> > for queues should be done in function i40e_flow_flush_fdir_filter().
> >
> > Cc: stable@dpdk.org
> > Fixes: 1491f63c7559 ("net/i40e: fix flush of flow director filter")
> > Fixes: 6ae9b2b5e8c2 ("net/i40e: cache flow director enable value in Rx
> queue")
> >
> > Signed-off-by: Wei Zhao <wei.zhao1@intel.com>
> > ---
> >   drivers/net/i40e/i40e_flow.c | 12 +++++++++---
> >   1 file changed, 9 insertions(+), 3 deletions(-)
> >
> > diff --git a/drivers/net/i40e/i40e_flow.c b/drivers/net/i40e/i40e_flow.c
> > index 25c77e7aa..94fc73092 100644
> > --- a/drivers/net/i40e/i40e_flow.c
> > +++ b/drivers/net/i40e/i40e_flow.c
> > @@ -3462,6 +3462,12 @@ i40e_flow_parse_fdir_filter(struct rte_eth_dev
> *dev,
> >   		}
> >   	}
> >
> > +	/* If the flow list is empty, it is the first time to create
> > +	 * rule after flush fdir filter, so enable fdir.
> > +	 */
> 
> 
> So either flush fdir filter or destroy the last fdir, it will result the
> flow list to be empty, could it simply as "If create the first fdir
> rule, enable fdir" or?


Ok


> 
> 
> > +	if (TAILQ_EMPTY(&pf->fdir.fdir_list))
> > +		i40e_fdir_rx_proc_enable(dev, 1);
> > +
> >   	return 0;
> >   err:
> >   	i40e_fdir_teardown(pf);
> > @@ -5330,9 +5336,6 @@ i40e_flow_flush(struct rte_eth_dev *dev, struct
> rte_flow_error *error)
> >   		return -rte_errno;
> >   	}
> >
> > -	/* Disable FDIR processing as all FDIR rules are now flushed */
> > -	i40e_fdir_rx_proc_enable(dev, 0);
> > -
> >   	return ret;
> >   }
> >
> > @@ -5368,6 +5371,9 @@ i40e_flow_flush_fdir_filter(struct i40e_pf *pf)
> >   		for (pctype = I40E_FILTER_PCTYPE_NONF_IPV4_UDP;
> >   		     pctype <= I40E_FILTER_PCTYPE_L2_PAYLOAD; pctype++)
> >   			pf->fdir.inset_flag[pctype] = 0;
> > +
> > +		/* Disable FDIR processing as all FDIR rules are now flushed */
> > +		i40e_fdir_rx_proc_enable(dev, 0);
> >   	}
> >
> >   	return ret;

  reply	other threads:[~2020-05-20  3:22 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-05-19  7:16 Wei Zhao
2020-05-19  9:36 ` Cui, LunyuanX
2020-05-20  3:18 ` Jeff Guo
2020-05-20  3:22   ` Zhao1, Wei [this message]
2020-05-20  4:13 ` Xing, Beilei
2020-05-20  5:13   ` Zhao1, Wei
2020-05-20  7:37     ` Xing, Beilei
2020-05-20  7:43       ` Zhao1, Wei
2020-05-21  8:03 ` [dpdk-dev] [PATCH v2] " Wei Zhao
2020-05-21 14:27   ` Jeff Guo
2020-05-22  0:59     ` Zhao1, Wei
2020-05-22  2:16       ` Jeff Guo
2020-05-22  9:18   ` Ye Xiaolong

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=MWHPR11MB13919F5336A492579055DE2AB7B60@MWHPR11MB1391.namprd11.prod.outlook.com \
    --to=wei.zhao1@intel.com \
    --cc=beilei.xing@intel.com \
    --cc=dev@dpdk.org \
    --cc=jia.guo@intel.com \
    --cc=stable@dpdk.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).