[dpdk-dev] app/testpmd: add meter to the actions table

Message ID 1515678563-13424-1-git-send-email-tdu@semihalf.com (mailing list archive)
State Superseded, archived
Delegated to: Thomas Monjalon
Headers

Checks

Context Check Description
ci/checkpatch success coding style OK
ci/Intel-compilation success Compilation OK

Commit Message

Tomasz Duszynski Jan. 11, 2018, 1:49 p.m. UTC
  Since METER action is supported by the testpmd application
suitable entry should exist in flow actions information table.

Without that testpmd will return error on adding a new flow to
the list of flows attached to a given port.

Signed-off-by: Tomasz Duszynski <tdu@semihalf.com>
---
 app/test-pmd/config.c | 1 +
 1 file changed, 1 insertion(+)
  

Comments

Cristian Dumitrescu Jan. 11, 2018, 6:33 p.m. UTC | #1
> -----Original Message-----
> From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Tomasz Duszynski
> Sent: Thursday, January 11, 2018 1:49 PM
> To: dev@dpdk.org
> Cc: Lu, Wenzhuo <wenzhuo.lu@intel.com>; Wu, Jingjing
> <jingjing.wu@intel.com>; Tomasz Duszynski <tdu@semihalf.com>
> Subject: [dpdk-dev] [PATCH] app/testpmd: add meter to the actions table
> 
> Since METER action is supported by the testpmd application
> suitable entry should exist in flow actions information table.
> 
> Without that testpmd will return error on adding a new flow to
> the list of flows attached to a given port.
> 
> Signed-off-by: Tomasz Duszynski <tdu@semihalf.com>
> ---
>  app/test-pmd/config.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/app/test-pmd/config.c b/app/test-pmd/config.c
> index 0a84481..4ad19fb 100644
> --- a/app/test-pmd/config.c
> +++ b/app/test-pmd/config.c
> @@ -1038,6 +1038,7 @@ static const struct {
>  	MK_FLOW_ACTION(RSS, sizeof(struct rte_flow_action_rss)), /*
> +queue[] */
>  	MK_FLOW_ACTION(PF, 0),
>  	MK_FLOW_ACTION(VF, sizeof(struct rte_flow_action_vf)),
> +	MK_FLOW_ACTION(METER, sizeof(struct rte_flow_action_meter)),
>  };
> 
>  /** Compute storage space needed by action configuration. */
> --
> 2.7.4

Adding Jasvinder to this thread.
  
Jasvinder Singh Jan. 12, 2018, 1:07 p.m. UTC | #2
> -----Original Message-----
> From: Dumitrescu, Cristian
> Sent: Thursday, January 11, 2018 6:34 PM
> To: Tomasz Duszynski <tdu@semihalf.com>; dev@dpdk.org
> Cc: Lu, Wenzhuo <wenzhuo.lu@intel.com>; Wu, Jingjing
> <jingjing.wu@intel.com>; Singh, Jasvinder <jasvinder.singh@intel.com>
> Subject: RE: [dpdk-dev] [PATCH] app/testpmd: add meter to the actions
> table
> 
> 
> > -----Original Message-----
> > From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Tomasz Duszynski
> > Sent: Thursday, January 11, 2018 1:49 PM
> > To: dev@dpdk.org
> > Cc: Lu, Wenzhuo <wenzhuo.lu@intel.com>; Wu, Jingjing
> > <jingjing.wu@intel.com>; Tomasz Duszynski <tdu@semihalf.com>
> > Subject: [dpdk-dev] [PATCH] app/testpmd: add meter to the actions
> > table
> >
> > Since METER action is supported by the testpmd application suitable
> > entry should exist in flow actions information table.
> >
> > Without that testpmd will return error on adding a new flow to the
> > list of flows attached to a given port.
> >
> > Signed-off-by: Tomasz Duszynski <tdu@semihalf.com>
> > ---
> >  app/test-pmd/config.c | 1 +
> >  1 file changed, 1 insertion(+)
> >
> > diff --git a/app/test-pmd/config.c b/app/test-pmd/config.c index
> > 0a84481..4ad19fb 100644
> > --- a/app/test-pmd/config.c
> > +++ b/app/test-pmd/config.c
> > @@ -1038,6 +1038,7 @@ static const struct {
> >  	MK_FLOW_ACTION(RSS, sizeof(struct rte_flow_action_rss)), /*
> > +queue[] */
> >  	MK_FLOW_ACTION(PF, 0),
> >  	MK_FLOW_ACTION(VF, sizeof(struct rte_flow_action_vf)),
> > +	MK_FLOW_ACTION(METER, sizeof(struct rte_flow_action_meter)),
> >  };
> >
> >  /** Compute storage space needed by action configuration. */
> > --
> > 2.7.4
> 
> Adding Jasvinder to this thread.

The above change looks fine to me.

Acked-by: Jasvinder Singh <jasvinder.singh@intel.com>
  
Tomasz Duszynski Jan. 22, 2018, 7:28 a.m. UTC | #3
On Fri, Jan 12, 2018 at 01:07:34PM +0000, Singh, Jasvinder wrote:
>
>
> > -----Original Message-----
> > From: Dumitrescu, Cristian
> > Sent: Thursday, January 11, 2018 6:34 PM
> > To: Tomasz Duszynski <tdu@semihalf.com>; dev@dpdk.org
> > Cc: Lu, Wenzhuo <wenzhuo.lu@intel.com>; Wu, Jingjing
> > <jingjing.wu@intel.com>; Singh, Jasvinder <jasvinder.singh@intel.com>
> > Subject: RE: [dpdk-dev] [PATCH] app/testpmd: add meter to the actions
> > table
> >
> >
> > > -----Original Message-----
> > > From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Tomasz Duszynski
> > > Sent: Thursday, January 11, 2018 1:49 PM
> > > To: dev@dpdk.org
> > > Cc: Lu, Wenzhuo <wenzhuo.lu@intel.com>; Wu, Jingjing
> > > <jingjing.wu@intel.com>; Tomasz Duszynski <tdu@semihalf.com>
> > > Subject: [dpdk-dev] [PATCH] app/testpmd: add meter to the actions
> > > table
> > >
> > > Since METER action is supported by the testpmd application suitable
> > > entry should exist in flow actions information table.
> > >
> > > Without that testpmd will return error on adding a new flow to the
> > > list of flows attached to a given port.
> > >
> > > Signed-off-by: Tomasz Duszynski <tdu@semihalf.com>
> > > ---
> > >  app/test-pmd/config.c | 1 +
> > >  1 file changed, 1 insertion(+)
> > >
> > > diff --git a/app/test-pmd/config.c b/app/test-pmd/config.c index
> > > 0a84481..4ad19fb 100644
> > > --- a/app/test-pmd/config.c
> > > +++ b/app/test-pmd/config.c
> > > @@ -1038,6 +1038,7 @@ static const struct {
> > >  	MK_FLOW_ACTION(RSS, sizeof(struct rte_flow_action_rss)), /*
> > > +queue[] */
> > >  	MK_FLOW_ACTION(PF, 0),
> > >  	MK_FLOW_ACTION(VF, sizeof(struct rte_flow_action_vf)),
> > > +	MK_FLOW_ACTION(METER, sizeof(struct rte_flow_action_meter)),
> > >  };
> > >
> > >  /** Compute storage space needed by action configuration. */
> > > --
> > > 2.7.4
> >
> > Adding Jasvinder to this thread.
>
> The above change looks fine to me.
>
> Acked-by: Jasvinder Singh <jasvinder.singh@intel.com>

Since I cannot see any objections can you pick up this one?

--
- Tomasz Duszyński
  

Patch

diff --git a/app/test-pmd/config.c b/app/test-pmd/config.c
index 0a84481..4ad19fb 100644
--- a/app/test-pmd/config.c
+++ b/app/test-pmd/config.c
@@ -1038,6 +1038,7 @@  static const struct {
 	MK_FLOW_ACTION(RSS, sizeof(struct rte_flow_action_rss)), /* +queue[] */
 	MK_FLOW_ACTION(PF, 0),
 	MK_FLOW_ACTION(VF, sizeof(struct rte_flow_action_vf)),
+	MK_FLOW_ACTION(METER, sizeof(struct rte_flow_action_meter)),
 };
 
 /** Compute storage space needed by action configuration. */