[ovs-dev] [PATCH 2/4] ofproto: Add enum ofp_table_config

Simon Horman horms at verge.net.au
Wed Nov 13 00:14:05 UTC 2013


On Tue, Nov 12, 2013 at 08:47:45AM -0800, Ben Pfaff wrote:
> On Tue, Nov 12, 2013 at 04:45:51PM +0900, Simon Horman wrote:
> > Cc: Andy Zhou <azhou at nicira.com>
> > Signed-off-by: Simon Horman <horms at verge.net.au>
> > ---
> >  include/openflow/openflow-common.h | 8 ++++++++
> >  1 file changed, 8 insertions(+)
> > 
> > diff --git a/include/openflow/openflow-common.h b/include/openflow/openflow-common.h
> > index 234bf96..17ba915 100644
> > --- a/include/openflow/openflow-common.h
> > +++ b/include/openflow/openflow-common.h
> > @@ -475,4 +475,12 @@ enum ofp_table {
> >                                  flow stats and flow deletes. */
> >  };
> >  
> > +enum ofp_table_config {
> > +    OFPTC_TABLE_MISS_CONTROLLER = 0,    /* Send to controller. */
> > +    OFPTC_TABLE_MISS_CONTINUE = 1 << 0, /* Continue to the next table in the
> > +                                           pipeline (OpenFlow 1.0 behavior). */
> > +    OFPTC_TABLE_MISS_DROP = 1 << 1,     /* Drop the packet. */
> > +    OFPTC_TABLE_MISS_MASK = 3
> > +};
> 
> I know that at least some version of the standard writes it that way but
> the constants don't make any sense in that form.  0 << 0, 1 << 0, 2 <<
> 0, 3 << 0 are a lot more sensible.  So I changed the constants to read
> that way and applied this.

Thanks.



More information about the dev mailing list