[v1 1/4] ethdev: add IPv4/IPv6 ECN header rewrite action

Ori Kam orika at nvidia.com
Thu Jun 2 07:48:27 CEST 2022



> -----Original Message-----
> From: Ferruh Yigit <ferruh.yigit at xilinx.com>
> Sent: Wednesday, June 1, 2022 9:51 PM
> To: Sean Zhang (Networking SW) <xiazhang at nvidia.com>; Ori Kam <orika at nvidia.com>; Xiaoyun Li
> <xiaoyun.li at intel.com>; Aman Singh <aman.deep.singh at intel.com>; Yuying Zhang
> <yuying.zhang at intel.com>; NBU-Contact-Thomas Monjalon (EXTERNAL) <thomas at monjalon.net>;
> Andrew Rybchenko <andrew.rybchenko at oktetlabs.ru>
> Cc: dev at dpdk.org; Jiawei(Jonny) Wang <jiaweiw at nvidia.com>; Alexander Kozyrev
> <akozyrev at nvidia.com>
> Subject: Re: [v1 1/4] ethdev: add IPv4/IPv6 ECN header rewrite action
> 
> On 4/2/2022 8:11 AM, Sean Zhang wrote:
> > From: Jiawei Wang <jiaweiw at nvidia.com>
> >
> > This patch introduces the IPv4/IPv6 ECN modify field support, and
> > adds the testpmd CLI commands support.
> >
> > Usage:
> > 	modify_field op set dst_type ipv4_ecn src_type ...
> >
> > For example:
> >
> > flow create 0 ingress group 1 pattern eth / ipv4 /  end actions
> > 	modify_field op set dst_type ipv4_ecn src_type value src_value
> > 	0x03 width 2 / queue index 0 / end
> >
> > Signed-off-by: Jiawei Wang <jiaweiw at nvidia.com>
> > ---
> >   app/test-pmd/cmdline_flow.c | 3 ++-
> >   lib/ethdev/rte_flow.h       | 2 ++
> >   2 files changed, 4 insertions(+), 1 deletion(-)
> >
> > diff --git a/app/test-pmd/cmdline_flow.c b/app/test-pmd/cmdline_flow.c
> > index fc4a6d9cca..3250add834 100644
> > --- a/app/test-pmd/cmdline_flow.c
> > +++ b/app/test-pmd/cmdline_flow.c
> > @@ -795,7 +795,8 @@ static const char *const modify_field_ids[] = {
> >   	"tcp_seq_num", "tcp_ack_num", "tcp_flags",
> >   	"udp_port_src", "udp_port_dst",
> >   	"vxlan_vni", "geneve_vni", "gtp_teid",
> > -	"tag", "mark", "meta", "pointer", "value", NULL
> > +	"tag", "mark", "meta", "pointer", "value",
> > +	"ipv4_ecn", "ipv6_ecn", NULL
> >   };
> >
> >   /** Maximum number of subsequent tokens and arguments on the stack. */
> > diff --git a/lib/ethdev/rte_flow.h b/lib/ethdev/rte_flow.h
> > index d8827dd184..1b56f23cba 100644
> > --- a/lib/ethdev/rte_flow.h
> > +++ b/lib/ethdev/rte_flow.h
> > @@ -3690,6 +3690,8 @@ enum rte_flow_field_id {
> >   	RTE_FLOW_FIELD_META,		/**< Metadata value. */
> >   	RTE_FLOW_FIELD_POINTER,		/**< Memory pointer. */
> >   	RTE_FLOW_FIELD_VALUE,		/**< Immediate value. */
> > +	RTE_FLOW_FIELD_IPV4_ECN,	/**< IPv4 ECN. */
> > +	RTE_FLOW_FIELD_IPV6_ECN,	/**< IPv6 ECN. */
> >   };
> >
> >   /**
> 
> cc'ed Alexander.
> 
> Patch looks good to me, only perhaps release notes can be updated, what
> do you think?
> 
> @Ori, @Alex, do you have any objection/comment?

Acked-by: Ori Kam <orika at nvidia.com>
Best,
Ori


More information about the dev mailing list