[ovs-dev] [PATCH 1/5] openflow-1.4.h: Add bundle structure definitions

Ben Pfaff blp at nicira.com
Mon Mar 3 21:00:27 UTC 2014


On Mon, Mar 03, 2014 at 03:22:31PM +0200, Alexandru Copot wrote:
> Signed-off-by: Alexandru Copot <alex.mihai.c at gmail.com>
> Cc: Daniel Baluta <dbaluta at ixiacom.com>
> ---
>  include/openflow/openflow-1.4.h | 114 ++++++++++++++++++++++++++++++++++++++++
>  1 file changed, 114 insertions(+)
> 
> diff --git a/include/openflow/openflow-1.4.h b/include/openflow/openflow-1.4.h
> index 332a0d3..a6645b9 100644
> --- a/include/openflow/openflow-1.4.h
> +++ b/include/openflow/openflow-1.4.h
> @@ -153,4 +153,118 @@ struct ofp14_role_prop_experimenter {
>  };
>  OFP_ASSERT(sizeof(struct ofp14_role_prop_experimenter) == 12);
>  
> +/* OFPET_EXPERIMENTER: Error message (datapath -> controller). */
> +struct ofp_error_experimenter_msg {
> +    ovs_be16 type;           /* OFPET_EXPERIMENTER. */
> +    ovs_be16 exp_type;       /* Experimenter defined. */
> +    ovs_be32 experimenter;   /* Experimenter ID which takes the same form
> +                                as in struct ofp_experimenter_header. */
> +
> +    /* Variable-length data. Interpreted based on
> +       the type and code. No padding. */
> +    uint8_t data[0];
> +};
> +OFP_ASSERT(sizeof(struct ofp_error_experimenter_msg) == 8);

The above data structure isn't needed; OVS already handles experimenter
error codes through infrastructure in ofp-error.h.  You can update that
file with any new error types or codes.

The various generic "property" definitions here have the same form as
those already used various places in OpenFlow and in particular in the
"table features" definitions in OpenFlow 1.3.  I'd prefer to handle them
generically rather than building up new infrastructure for each instance
of such properties in OpenFlow.  I'm working on that for "table
features" but I've been pretty slow about it.  Maybe I can catch up
soon.



More information about the dev mailing list