mirror of
https://github.com/openvswitch/ovs
synced 2025-10-25 15:07:05 +00:00
ofp-actions: Centralize all OpenFlow action code for maintainability.
Until now, knowledge about OpenFlow has been somewhat scattered around the tree. Some of it is in ofp-actions, some of it is in ofp-util, some in separate files for individual actions, and most of the wire format declarations are in include/openflow. This commit centralizes all of that in ofp-actions. Encoding and decoding OpenFlow actions was previously broken up by OpenFlow version. This was OK with only OpenFlow 1.0 and 1.1, but each additional version added a new wrapper around the existing ones, which started to become hard to understand. This commit merges all of the processing for the different versions, to the extent that they are similar, making the version differences clearer. Previously, ofp-actions contained OpenFlow encoding and decoding, plus ofpact formatting, but OpenFlow parsing was separated into ofp-parse, which seems an odd division. This commit moves the parsing code into ofp-actions with the rest of the code. Before this commit, the four main bits of code associated with a particular ofpact--OpenFlow encoding and decoding, ofpact formatting and parsing--were all found far away from each other. This often made it hard to see what was going on for a particular ofpact, since you had to search around to many different pieces of code. This commit reorganizes so that all of the code for a given ofpact is in a single place. As a code refactoring, this commit has little visible behavioral change. The update to ofproto-dpif.at illustrates one minor bug fix as a side effect: a flow that was added with the action "dec_ttl" (a standard OpenFlow action) was previously formatted as "dec_ttl(0)" (using a Nicira extension to specifically direct packets bounced to the controller because of too-low TTL), but after this commit it is correctly formatted as "dec_ttl". The other visible effect is to drop support for the Nicira extension dec_ttl action in OpenFlow 1.1 and later in favor of the equivalent standard action. It seems unlikely that anyone was really using the Nicira extension in OF1.1 or later. Signed-off-by: Ben Pfaff <blp@nicira.com> Acked-by: Jarno Rajahalme <jrajahalme@nicira.com>
This commit is contained in:
File diff suppressed because it is too large
Load Diff
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2008, 2009, 2010, 2011, 2012, 2013 Nicira, Inc.
|
||||
* Copyright (c) 2008, 2009, 2010, 2011, 2012, 2013, 2014 Nicira, Inc.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -170,46 +170,6 @@ struct ofp10_packet_in {
|
||||
};
|
||||
OFP_ASSERT(sizeof(struct ofp10_packet_in) == 12);
|
||||
|
||||
enum ofp10_action_type {
|
||||
OFPAT10_OUTPUT, /* Output to switch port. */
|
||||
OFPAT10_SET_VLAN_VID, /* Set the 802.1q VLAN id. */
|
||||
OFPAT10_SET_VLAN_PCP, /* Set the 802.1q priority. */
|
||||
OFPAT10_STRIP_VLAN, /* Strip the 802.1q header. */
|
||||
OFPAT10_SET_DL_SRC, /* Ethernet source address. */
|
||||
OFPAT10_SET_DL_DST, /* Ethernet destination address. */
|
||||
OFPAT10_SET_NW_SRC, /* IP source address. */
|
||||
OFPAT10_SET_NW_DST, /* IP destination address. */
|
||||
OFPAT10_SET_NW_TOS, /* IP ToS (DSCP field, 6 bits). */
|
||||
OFPAT10_SET_TP_SRC, /* TCP/UDP source port. */
|
||||
OFPAT10_SET_TP_DST, /* TCP/UDP destination port. */
|
||||
OFPAT10_ENQUEUE, /* Output to queue. */
|
||||
OFPAT10_VENDOR = 0xffff
|
||||
};
|
||||
|
||||
/* Action structure for OFPAT10_OUTPUT, which sends packets out 'port'.
|
||||
* When the 'port' is the OFPP_CONTROLLER, 'max_len' indicates the max
|
||||
* number of bytes to send. A 'max_len' of zero means no bytes of the
|
||||
* packet should be sent. */
|
||||
struct ofp10_action_output {
|
||||
ovs_be16 type; /* OFPAT10_OUTPUT. */
|
||||
ovs_be16 len; /* Length is 8. */
|
||||
ovs_be16 port; /* Output port. */
|
||||
ovs_be16 max_len; /* Max length to send to controller. */
|
||||
};
|
||||
OFP_ASSERT(sizeof(struct ofp10_action_output) == 8);
|
||||
|
||||
/* OFPAT10_ENQUEUE action struct: send packets to given queue on port. */
|
||||
struct ofp10_action_enqueue {
|
||||
ovs_be16 type; /* OFPAT10_ENQUEUE. */
|
||||
ovs_be16 len; /* Len is 16. */
|
||||
ovs_be16 port; /* Port that queue belongs. Should
|
||||
refer to a valid physical port
|
||||
(i.e. < OFPP_MAX) or OFPP_IN_PORT. */
|
||||
uint8_t pad[6]; /* Pad for 64-bit alignment. */
|
||||
ovs_be32 queue_id; /* Where to enqueue the packets. */
|
||||
};
|
||||
OFP_ASSERT(sizeof(struct ofp10_action_enqueue) == 16);
|
||||
|
||||
/* Send packet (controller -> datapath). */
|
||||
struct ofp10_packet_out {
|
||||
ovs_be32 buffer_id; /* ID assigned by datapath or UINT32_MAX. */
|
||||
@@ -311,9 +271,9 @@ struct ofp10_flow_mod {
|
||||
output port. A value of OFPP_NONE
|
||||
indicates no restriction. */
|
||||
ovs_be16 flags; /* One of OFPFF_*. */
|
||||
struct ofp_action_header actions[0]; /* The action length is inferred
|
||||
from the length field in the
|
||||
header. */
|
||||
|
||||
/* Followed by OpenFlow actions whose length is inferred from the length
|
||||
* field in the OpenFlow header. */
|
||||
};
|
||||
OFP_ASSERT(sizeof(struct ofp10_flow_mod) == 64);
|
||||
|
||||
@@ -374,7 +334,7 @@ struct ofp10_flow_stats {
|
||||
ovs_32aligned_be64 cookie; /* Opaque controller-issued identifier. */
|
||||
ovs_32aligned_be64 packet_count; /* Number of packets in flow. */
|
||||
ovs_32aligned_be64 byte_count; /* Number of bytes in flow. */
|
||||
struct ofp_action_header actions[0]; /* Actions. */
|
||||
/* Followed by OpenFlow actions whose length is inferred from 'length'. */
|
||||
};
|
||||
OFP_ASSERT(sizeof(struct ofp10_flow_stats) == 88);
|
||||
|
||||
|
||||
@@ -181,38 +181,6 @@ enum ofp11_capabilities {
|
||||
OFPC11_GROUP_STATS = 1 << 3, /* Group statistics. */
|
||||
};
|
||||
|
||||
enum ofp11_action_type {
|
||||
OFPAT11_OUTPUT, /* Output to switch port. */
|
||||
OFPAT11_SET_VLAN_VID, /* Set the 802.1q VLAN id. */
|
||||
OFPAT11_SET_VLAN_PCP, /* Set the 802.1q priority. */
|
||||
OFPAT11_SET_DL_SRC, /* Ethernet source address. */
|
||||
OFPAT11_SET_DL_DST, /* Ethernet destination address. */
|
||||
OFPAT11_SET_NW_SRC, /* IP source address. */
|
||||
OFPAT11_SET_NW_DST, /* IP destination address. */
|
||||
OFPAT11_SET_NW_TOS, /* IP ToS (DSCP field, 6 bits). */
|
||||
OFPAT11_SET_NW_ECN, /* IP ECN (2 bits). */
|
||||
OFPAT11_SET_TP_SRC, /* TCP/UDP/SCTP source port. */
|
||||
OFPAT11_SET_TP_DST, /* TCP/UDP/SCTP destination port. */
|
||||
OFPAT11_COPY_TTL_OUT, /* Copy TTL "outwards" -- from next-to-outermost
|
||||
to outermost */
|
||||
OFPAT11_COPY_TTL_IN, /* Copy TTL "inwards" -- from outermost to
|
||||
next-to-outermost */
|
||||
OFPAT11_SET_MPLS_LABEL, /* MPLS label */
|
||||
OFPAT11_SET_MPLS_TC, /* MPLS TC */
|
||||
OFPAT11_SET_MPLS_TTL, /* MPLS TTL */
|
||||
OFPAT11_DEC_MPLS_TTL, /* Decrement MPLS TTL */
|
||||
|
||||
OFPAT11_PUSH_VLAN, /* Push a new VLAN tag */
|
||||
OFPAT11_POP_VLAN, /* Pop the outer VLAN 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. */
|
||||
OFPAT11_DEC_NW_TTL, /* Decrement IP TTL. */
|
||||
OFPAT11_EXPERIMENTER = 0xffff
|
||||
};
|
||||
|
||||
#define OFPMT11_STANDARD_LENGTH 88
|
||||
|
||||
struct ofp11_match_header {
|
||||
@@ -340,97 +308,6 @@ struct ofp11_instruction_experimenter {
|
||||
};
|
||||
OFP_ASSERT(sizeof(struct ofp11_instruction_experimenter) == 8);
|
||||
|
||||
/* Action structure for OFPAT_OUTPUT, which sends packets out 'port'.
|
||||
* When the 'port' is the OFPP_CONTROLLER, 'max_len' indicates the max
|
||||
* number of bytes to send. A 'max_len' of zero means no bytes of the
|
||||
* packet should be sent.*/
|
||||
struct ofp11_action_output {
|
||||
ovs_be16 type; /* OFPAT11_OUTPUT. */
|
||||
ovs_be16 len; /* Length is 16. */
|
||||
ovs_be32 port; /* Output port. */
|
||||
ovs_be16 max_len; /* Max length to send to controller. */
|
||||
uint8_t pad[6]; /* Pad to 64 bits. */
|
||||
};
|
||||
OFP_ASSERT(sizeof(struct ofp11_action_output) == 16);
|
||||
|
||||
/* Action structure for OFPAT_GROUP. */
|
||||
struct ofp11_action_group {
|
||||
ovs_be16 type; /* OFPAT11_GROUP. */
|
||||
ovs_be16 len; /* Length is 8. */
|
||||
ovs_be32 group_id; /* Group identifier. */
|
||||
};
|
||||
OFP_ASSERT(sizeof(struct ofp11_action_group) == 8);
|
||||
|
||||
/* OFPAT_SET_QUEUE action struct: send packets to given queue on port. */
|
||||
struct ofp11_action_set_queue {
|
||||
ovs_be16 type; /* OFPAT11_SET_QUEUE. */
|
||||
ovs_be16 len; /* Len is 8. */
|
||||
ovs_be32 queue_id; /* Queue id for the packets. */
|
||||
};
|
||||
OFP_ASSERT(sizeof(struct ofp11_action_set_queue) == 8);
|
||||
|
||||
/* Action structure for OFPAT11_SET_MPLS_LABEL. */
|
||||
struct ofp11_action_mpls_label {
|
||||
ovs_be16 type; /* OFPAT11_SET_MPLS_LABEL. */
|
||||
ovs_be16 len; /* Length is 8. */
|
||||
ovs_be32 mpls_label; /* MPLS label */
|
||||
};
|
||||
OFP_ASSERT(sizeof(struct ofp11_action_mpls_label) == 8);
|
||||
|
||||
/* Action structure for OFPAT11_SET_MPLS_TC. */
|
||||
struct ofp11_action_mpls_tc {
|
||||
ovs_be16 type; /* OFPAT11_SET_MPLS_TC. */
|
||||
ovs_be16 len; /* Length is 8. */
|
||||
uint8_t mpls_tc; /* MPLS TC */
|
||||
uint8_t pad[3];
|
||||
};
|
||||
OFP_ASSERT(sizeof(struct ofp11_action_mpls_tc) == 8);
|
||||
|
||||
/* Action structure for OFPAT11_SET_MPLS_TTL. */
|
||||
struct ofp11_action_mpls_ttl {
|
||||
ovs_be16 type; /* OFPAT11_SET_MPLS_TTL. */
|
||||
ovs_be16 len; /* Length is 8. */
|
||||
uint8_t mpls_ttl; /* MPLS TTL */
|
||||
uint8_t pad[3];
|
||||
};
|
||||
OFP_ASSERT(sizeof(struct ofp11_action_mpls_ttl) == 8);
|
||||
|
||||
/* Action structure for OFPAT11_SET_NW_ECN. */
|
||||
struct ofp11_action_nw_ecn {
|
||||
ovs_be16 type; /* OFPAT11_SET_TW_SRC/DST. */
|
||||
ovs_be16 len; /* Length is 8. */
|
||||
uint8_t nw_ecn; /* IP ECN (2 bits). */
|
||||
uint8_t pad[3];
|
||||
};
|
||||
OFP_ASSERT(sizeof(struct ofp11_action_nw_ecn) == 8);
|
||||
|
||||
/* Action structure for OFPAT11_SET_NW_TTL. */
|
||||
struct ofp11_action_nw_ttl {
|
||||
ovs_be16 type; /* OFPAT11_SET_NW_TTL. */
|
||||
ovs_be16 len; /* Length is 8. */
|
||||
uint8_t nw_ttl; /* IP TTL */
|
||||
uint8_t pad[3];
|
||||
};
|
||||
OFP_ASSERT(sizeof(struct ofp11_action_nw_ttl) == 8);
|
||||
|
||||
/* Action structure for OFPAT11_PUSH_VLAN/MPLS. */
|
||||
struct ofp11_action_push {
|
||||
ovs_be16 type; /* OFPAT11_PUSH_VLAN/MPLS. */
|
||||
ovs_be16 len; /* Length is 8. */
|
||||
ovs_be16 ethertype; /* Ethertype */
|
||||
uint8_t pad[2];
|
||||
};
|
||||
OFP_ASSERT(sizeof(struct ofp11_action_push) == 8);
|
||||
|
||||
/* Action structure for OFPAT11_POP_MPLS. */
|
||||
struct ofp11_action_pop_mpls {
|
||||
ovs_be16 type; /* OFPAT11_POP_MPLS. */
|
||||
ovs_be16 len; /* Length is 8. */
|
||||
ovs_be16 ethertype; /* Ethertype */
|
||||
uint8_t pad[2];
|
||||
};
|
||||
OFP_ASSERT(sizeof(struct ofp11_action_pop_mpls) == 8);
|
||||
|
||||
/* Configure/Modify behavior of a flow table */
|
||||
struct ofp11_table_mod {
|
||||
uint8_t table_id; /* ID of the table, 0xFF indicates all tables */
|
||||
|
||||
@@ -110,22 +110,18 @@ enum oxm12_ofb_match_fields {
|
||||
OFPXMT12_OFB_IPV6_ND_TLL, /* Target link-layer for ND. */
|
||||
OFPXMT12_OFB_MPLS_LABEL, /* MPLS label. */
|
||||
OFPXMT12_OFB_MPLS_TC, /* MPLS TC. */
|
||||
#define OFPXMT12_MASK ((1ULL << (OFPXMT12_OFB_MPLS_TC + 1)) - 1)
|
||||
|
||||
/* Following added in OpenFlow 1.3 */
|
||||
OFPXMT13_OFB_MPLS_BOS, /* MPLS BoS bit. */
|
||||
OFPXMT13_OFB_PBB_ISID, /* PBB I-SID. */
|
||||
OFPXMT13_OFB_TUNNEL_ID, /* Logical Port Metadata */
|
||||
OFPXMT13_OFB_IPV6_EXTHDR, /* IPv6 Extension Header pseudo-field */
|
||||
#define OFPXMT13_MASK ((1ULL << (OFPXMT13_OFB_IPV6_EXTHDR + 1)) - 1)
|
||||
|
||||
/* Following added in OpenFlow 1.4. */
|
||||
OFPXMT14_OFB_PBB_UCA = 41, /* PBB UCA header field. */
|
||||
#define OFPXMT14_MASK (1ULL << OFPXMT14_OFB_PBB_UCA)
|
||||
|
||||
/* Following added in OpenFlow 1.5. */
|
||||
OFPXMT15_OFB_TCP_FLAGS = 42, /* TCP flags. */
|
||||
#define OFPXMT15_MASK (1ULL << OFPXMT15_OFB_TCP_FLAGS)
|
||||
};
|
||||
|
||||
/* OXM implementation makes use of NXM as they are the same format
|
||||
@@ -230,10 +226,6 @@ struct ofp12_oxm_experimenter_header {
|
||||
};
|
||||
OFP_ASSERT(sizeof(struct ofp12_oxm_experimenter_header) == 8);
|
||||
|
||||
enum ofp12_action_type {
|
||||
OFPAT12_SET_FIELD = 25, /* Set a header field using OXM TLV format. */
|
||||
};
|
||||
|
||||
enum ofp12_controller_max_len {
|
||||
OFPCML12_MAX = 0xffe5, /* maximum max_len value which can be used
|
||||
* to request a specific byte length. */
|
||||
@@ -242,18 +234,6 @@ enum ofp12_controller_max_len {
|
||||
* sent to the controller. */
|
||||
};
|
||||
|
||||
/* Action structure for OFPAT12_SET_FIELD. */
|
||||
struct ofp12_action_set_field {
|
||||
ovs_be16 type; /* OFPAT12_SET_FIELD. */
|
||||
ovs_be16 len; /* Length is padded to 64 bits. */
|
||||
ovs_be32 dst; /* OXM TLV header */
|
||||
/* Followed by:
|
||||
* - Exactly ((oxm_len + 4) + 7)/8*8 - (oxm_len + 4) (between 0 and 7)
|
||||
* bytes of all-zero bytes
|
||||
*/
|
||||
};
|
||||
OFP_ASSERT(sizeof(struct ofp12_action_set_field) == 8);
|
||||
|
||||
/* OpenFlow 1.2 specific flags
|
||||
* (struct ofp12_flow_mod, member flags). */
|
||||
enum ofp12_flow_mod_flags {
|
||||
|
||||
@@ -99,27 +99,6 @@ struct ofp13_instruction_meter {
|
||||
};
|
||||
OFP_ASSERT(sizeof(struct ofp13_instruction_meter) == 8);
|
||||
|
||||
enum ofp13_action_type {
|
||||
OFPAT13_OUTPUT = 0, /* Output to switch port. */
|
||||
OFPAT13_COPY_TTL_OUT = 11, /* Copy TTL "outwards" -- from next-to-outermost
|
||||
to outermost */
|
||||
OFPAT13_COPY_TTL_IN = 12, /* Copy TTL "inwards" -- from outermost to
|
||||
next-to-outermost */
|
||||
OFPAT13_SET_MPLS_TTL = 15, /* MPLS TTL */
|
||||
OFPAT13_DEC_MPLS_TTL = 16, /* Decrement MPLS TTL */
|
||||
OFPAT13_PUSH_VLAN = 17, /* Push a new VLAN tag */
|
||||
OFPAT13_POP_VLAN = 18, /* Pop the outer VLAN tag */
|
||||
OFPAT13_PUSH_MPLS = 19, /* Push a new MPLS Label Stack Entry */
|
||||
OFPAT13_POP_MPLS = 20, /* Pop the outer MPLS Label Stack Entry */
|
||||
OFPAT13_SET_QUEUE = 21, /* Set queue id when outputting to a port */
|
||||
OFPAT13_GROUP = 22, /* Apply group. */
|
||||
OFPAT13_SET_NW_TTL = 23, /* IP TTL. */
|
||||
OFPAT13_DEC_NW_TTL = 24, /* Decrement IP TTL. */
|
||||
OFPAT13_SET_FIELD = 25, /* Set a header field using OXM TLV format. */
|
||||
OFPAT13_PUSH_PBB = 26, /* Push a new PBB service tag (I-TAG) */
|
||||
OFPAT13_POP_PBB = 27 /* Pop the outer PBB service tag (I-TAG) */
|
||||
};
|
||||
|
||||
/* enum ofp_config_flags value OFPC_INVALID_TTL_TO_CONTROLLER
|
||||
* is deprecated in OpenFlow 1.3 */
|
||||
|
||||
|
||||
@@ -286,82 +286,6 @@ enum ofp_flow_mod_flags {
|
||||
OFPFF_CHECK_OVERLAP = 1 << 1, /* Check for overlapping entries first. */
|
||||
};
|
||||
|
||||
/* Action header for OFPAT10_VENDOR and OFPAT11_EXPERIMEMNTER.
|
||||
* The rest of the body is vendor-defined. */
|
||||
struct ofp_action_vendor_header {
|
||||
ovs_be16 type; /* OFPAT10_VENDOR. */
|
||||
ovs_be16 len; /* Length is a multiple of 8. */
|
||||
ovs_be32 vendor; /* Vendor ID, which takes the same form
|
||||
as in "struct ofp_vendor_header". */
|
||||
};
|
||||
OFP_ASSERT(sizeof(struct ofp_action_vendor_header) == 8);
|
||||
|
||||
/* Action header that is common to all actions. The length includes the
|
||||
* header and any padding used to make the action 64-bit aligned.
|
||||
* NB: The length of an action *must* always be a multiple of eight. */
|
||||
struct ofp_action_header {
|
||||
ovs_be16 type; /* One of OFPAT*. */
|
||||
ovs_be16 len; /* Length of action, including this
|
||||
header. This is the length of action,
|
||||
including any padding to make it
|
||||
64-bit aligned. */
|
||||
uint8_t pad[4];
|
||||
};
|
||||
OFP_ASSERT(sizeof(struct ofp_action_header) == 8);
|
||||
|
||||
/* Action structure for OFPAT10_SET_VLAN_VID and OFPAT11_SET_VLAN_VID. */
|
||||
struct ofp_action_vlan_vid {
|
||||
ovs_be16 type; /* Type. */
|
||||
ovs_be16 len; /* Length is 8. */
|
||||
ovs_be16 vlan_vid; /* VLAN id. */
|
||||
uint8_t pad[2];
|
||||
};
|
||||
OFP_ASSERT(sizeof(struct ofp_action_vlan_vid) == 8);
|
||||
|
||||
/* Action structure for OFPAT10_SET_VLAN_PCP and OFPAT11_SET_VLAN_PCP. */
|
||||
struct ofp_action_vlan_pcp {
|
||||
ovs_be16 type; /* Type. */
|
||||
ovs_be16 len; /* Length is 8. */
|
||||
uint8_t vlan_pcp; /* VLAN priority. */
|
||||
uint8_t pad[3];
|
||||
};
|
||||
OFP_ASSERT(sizeof(struct ofp_action_vlan_pcp) == 8);
|
||||
|
||||
/* Action structure for OFPAT10_SET_DL_SRC/DST and OFPAT11_SET_DL_SRC/DST. */
|
||||
struct ofp_action_dl_addr {
|
||||
ovs_be16 type; /* Type. */
|
||||
ovs_be16 len; /* Length is 16. */
|
||||
uint8_t dl_addr[OFP_ETH_ALEN]; /* Ethernet address. */
|
||||
uint8_t pad[6];
|
||||
};
|
||||
OFP_ASSERT(sizeof(struct ofp_action_dl_addr) == 16);
|
||||
|
||||
/* Action structure for OFPAT10_SET_NW_SRC/DST and OFPAT11_SET_NW_SRC/DST. */
|
||||
struct ofp_action_nw_addr {
|
||||
ovs_be16 type; /* Type. */
|
||||
ovs_be16 len; /* Length is 8. */
|
||||
ovs_be32 nw_addr; /* IP address. */
|
||||
};
|
||||
OFP_ASSERT(sizeof(struct ofp_action_nw_addr) == 8);
|
||||
|
||||
/* Action structure for OFPAT10_SET_NW_TOS and OFPAT11_SET_NW_TOS. */
|
||||
struct ofp_action_nw_tos {
|
||||
ovs_be16 type; /* Type.. */
|
||||
ovs_be16 len; /* Length is 8. */
|
||||
uint8_t nw_tos; /* DSCP in high 6 bits, rest ignored. */
|
||||
uint8_t pad[3];
|
||||
};
|
||||
OFP_ASSERT(sizeof(struct ofp_action_nw_tos) == 8);
|
||||
|
||||
/* Action structure for OFPAT10_SET_TP_SRC/DST and OFPAT11_SET_TP_SRC/DST. */
|
||||
struct ofp_action_tp_port {
|
||||
ovs_be16 type; /* Type. */
|
||||
ovs_be16 len; /* Length is 8. */
|
||||
ovs_be16 tp_port; /* TCP/UDP port. */
|
||||
uint8_t pad[2];
|
||||
};
|
||||
OFP_ASSERT(sizeof(struct ofp_action_tp_port) == 8);
|
||||
|
||||
/* Why was this flow removed? */
|
||||
enum ofp_flow_removed_reason {
|
||||
OFPRR_IDLE_TIMEOUT, /* Flow idle time exceeded idle_timeout. */
|
||||
|
||||
Reference in New Issue
Block a user