Re: [ovs-dev] How to define enum raw constants for two new vendor actions

2016-03-20 Thread Ajmer Singh
Thanks Ben! I will update the name as per your comment. can you please answer 2nd part of the question? I have to write encode,decode,parse and format functions for this new action. I have updated decode and encode as per previously defined actions but find it difficult for "parse" and format func

Re: [ovs-dev] How to define enum raw constants for two new vendor actions

2016-03-19 Thread Ben Pfaff
Your action structures are wrong because they are not based on the OpenFlow experimenter action format. Please refer to the OpenFlow specification for details. On Wed, Mar 16, 2016 at 06:06:30PM +0530, Ajmer Singh wrote: > Hi Ben, > > I have started adding OFPAT_ENCAP_GTP action in ofp-actions.c

Re: [ovs-dev] How to define enum raw constants for two new vendor actions

2016-03-19 Thread Ajmer Singh
Hi Ben, I have started adding OFPAT_ENCAP_GTP action in ofp-actions.c file as following: taking reference of already added action "OFPAT_ENQUEUE". I have prepared the structure of Action, also written encode and decode for this new action. but not able to understand how its *parse_ENCAP_GTP* and *

Re: [ovs-dev] How to define enum raw constants for two new vendor actions

2016-03-19 Thread Ben Pfaff
On Fri, Mar 18, 2016 at 11:29:39AM +0530, Ajmer Singh wrote: > Thanks Ben! I will update the name as per your comment. > > can you please answer 2nd part of the question? I have to write > encode,decode,parse and format functions for this new action. I have > updated decode and encode as per previ

Re: [ovs-dev] How to define enum raw constants for two new vendor actions

2016-03-19 Thread Ajmer Singh
Hi Ben, This new "ENCAP_GTP" action structure will be used as a payload in below action experimenter header structure. also the new structure is a multiple of 8 Bytes as per openflow specification. An Experimenter action uses the following structure and fields: /* Action header for OFPAT_EXPERIME

Re: [ovs-dev] How to define enum raw constants for two new vendor actions

2016-03-19 Thread Ben Pfaff
You didn't mention that part. It makes a difference. It's deceptive to use the name OFPAT_ENCAP_GTP because the OFPAT_ prefix implies that this is a standard action. Please choose your own prefix. On Thu, Mar 17, 2016 at 05:30:26PM +0530, Ajmer Singh wrote: > Hi Ben, > > This new "ENCAP_GTP" a

Re: [ovs-dev] How to define enum raw constants for two new vendor actions

2016-03-15 Thread Ben Pfaff
Please don't drop the mailing list. OK, so you'll have to add code to support the new vendor actions, some in build-aux/extract-ofp-msgs, some in ofp-actions.c. If it's your vendor code then you can use any types you want. On Tue, Mar 15, 2016 at 11:36:20AM +0530, Ajmer Singh wrote: > Hi Ben, >

Re: [ovs-dev] How to define enum raw constants for two new vendor actions

2016-03-14 Thread Ben Pfaff
On Mon, Mar 14, 2016 at 06:47:34PM +0530, Ajmer Singh wrote: > Hi, > I have a requirement of adding GTP headers in open Vswitch source code. We > need to define 2 new actions: STRIP_GTP and ENCAP_GTP. these are the > extensions. > > As per openflow specifications 1.0 and 1.1. If we add our 2 new a