X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=include%2Fopenflow%2Fopenflow-1.1.h;h=f7c2e78bca0bdabf9467d8a7e9c27a445e675b4b;hb=fa04edcedfe5285fd8ad3a4d70fecb38df18293d;hp=9785db456aa32a0a1126311687c9f742385a6d84;hpb=307975da7111cc223a9e2b859a0b12532fa4f2c8;p=sliver-openvswitch.git diff --git a/include/openflow/openflow-1.1.h b/include/openflow/openflow-1.1.h index 9785db456..f7c2e78bc 100644 --- a/include/openflow/openflow-1.1.h +++ b/include/openflow/openflow-1.1.h @@ -67,8 +67,16 @@ * an OpenFlow 1.0 reserved port number to or from, respectively, the * corresponding OpenFlow 1.1 reserved port number. */ -#define OFPP11_MAX 0xffffff00 -#define OFPP11_OFFSET (OFPP11_MAX - OFPP_MAX) +#define OFPP11_MAX OFP11_PORT_C(0xffffff00) +#define OFPP11_OFFSET 0xffff0000 /* OFPP11_MAX - OFPP_MAX */ + +/* Reserved wildcard port used only for flow mod (delete) and flow stats + * requests. Selects all flows regardless of output port + * (including flows with no output port) + * + * Define it via OFPP_NONE (0xFFFF) so that OFPP_ANY is still an enum ofp_port + */ +#define OFPP_ANY OFPP_NONE /* OpenFlow 1.1 port config flags are just the common flags. */ #define OFPPC11_ALL \ @@ -119,6 +127,7 @@ struct ofp11_port { ovs_be32 curr_speed; /* Current port bitrate in kbps. */ ovs_be32 max_speed; /* Max port bitrate in kbps */ }; +OFP_ASSERT(sizeof(struct ofp11_port) == 64); /* Modify behavior of the physical port */ struct ofp11_port_mod { @@ -195,8 +204,8 @@ enum ofp11_action_type { OFPAT11_PUSH_VLAN, /* Push a new VLAN tag */ OFPAT11_POP_VLAN, /* Pop the outer VLAN tag */ - OFPAT11_PUSH_MPLS, /* Push a new MPLS tag */ - OFPAT11_POP_MPLS, /* Pop the outer MPLS tag */ + OFPAT11_PUSH_MPLS, /* Push a new MPLS Label Stack Entry */ + OFPAT11_POP_MPLS, /* Pop the outer MPLS Label Stack Entry */ OFPAT11_SET_QUEUE, /* Set queue id when outputting to a port */ OFPAT11_GROUP, /* Apply group. */ OFPAT11_SET_NW_TTL, /* IP TTL. */ @@ -580,7 +589,8 @@ struct ofp11_flow_stats { when this is not an exact-match entry. */ ovs_be16 idle_timeout; /* Number of seconds idle before expiration. */ ovs_be16 hard_timeout; /* Number of seconds before expiration. */ - uint8_t pad2[6]; /* Align to 64-bits. */ + ovs_be16 flags; /* OF 1.3: Set of OFPFF*. */ + uint8_t pad2[4]; /* Align to 64-bits. */ ovs_be64 cookie; /* Opaque controller-issued identifier. */ ovs_be64 packet_count; /* Number of packets in flow. */ ovs_be64 byte_count; /* Number of bytes in flow. */ @@ -743,7 +753,7 @@ struct ofp11_packet_in { ovs_be16 total_len; /* Full length of frame. */ uint8_t reason; /* Reason packet is being sent (one of OFPR_*) */ uint8_t table_id; /* ID of the table that was looked up */ - uint8_t data[0]; /* Ethernet frame, halfway through 32-bit word, + /* uint8_t data[0]; Ethernet frame, halfway through 32-bit word, so the IP header is 32-bit aligned. The amount of data is inferred from the length field in the header. Because of padding,