// Copyright 2013, Big Switch Networks, Inc.
//
// LoxiGen is licensed under the Eclipse Public License, version 1.0 (EPL), with
// the following special exception:
//
// LOXI Exception
//
// As a special exception to the terms of the EPL, you may distribute libraries
// generated by LoxiGen (LoxiGen Libraries) under the terms of your choice, provided
// that copyright and licensing notices generated by LoxiGen are not altered or removed
// from the LoxiGen Libraries and the notice provided below is (i) included in
// the LoxiGen Libraries, if distributed in source code form and (ii) included in any
// documentation for the LoxiGen Libraries, if distributed in binary form.
//
// Notice: "Copyright 2013, Big Switch Networks, Inc. This library was generated by the LoxiGen Compiler."
//
// You may not use this file except in compliance with the EPL or LOXI Exception. You may obtain
// a copy of the EPL at:
//
// http://www.eclipse.org/legal/epl-v10.html
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
// WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
// EPL for the specific language governing permissions and limitations
// under the EPL.
//
// Also derived from the OpenFlow header files which have these copyrights:
// Copyright (c) 2008 The Board of Trustees of The Leland Stanford Junior University
// Copyright (c) 2011, 2012 Open Networking Foundation

#version 3

enum macro_definitions {
    OFP_MAX_TABLE_NAME_LEN = 32,
    OFP_MAX_PORT_NAME_LEN = 16,

    OFP_TCP_PORT = 6633,
    OFP_SSL_PORT = 6633,

    OFP_ETH_ALEN = 6,

    OFP_DEFAULT_MISS_SEND_LEN = 128,

    OFP_VLAN_NONE = 0,

    OFP_FLOW_PERMANENT = 0,

    OFP_DEFAULT_PRIORITY = 0x8000,

    OFP_NO_BUFFER = 0xffffffff,

    DESC_STR_LEN = 256,
    SERIAL_NUM_LEN = 32,

    OFPQ_ALL = 0xffffffff,

    OFPQ_MIN_RATE_UNCFG = 0xffff,
    OFPQ_MAX_RATE_UNCFG = 0xffff,
};

enum ofp_port(wire_type=uint32_t) {
    OFPP_MAX = 0xffffff00,
    OFPP_IN_PORT = 0xfffffff8,
    OFPP_TABLE = 0xfffffff9,
    OFPP_NORMAL = 0xfffffffa,
    OFPP_FLOOD = 0xfffffffb,
    OFPP_ALL = 0xfffffffc,
    OFPP_CONTROLLER = 0xfffffffd,
    OFPP_LOCAL = 0xfffffffe,
};

enum ofp_port_no(wire_type=uint32_t, complete=no) {
    OFPP_ANY = 0xffffffff,
};

enum ofp_type(wire_type=uint8_t) {
    OFPT_HELLO = 0,
    OFPT_ERROR = 1,
    OFPT_ECHO_REQUEST = 2,
    OFPT_ECHO_REPLY = 3,
    OFPT_EXPERIMENTER = 4,
    OFPT_FEATURES_REQUEST = 5,
    OFPT_FEATURES_REPLY = 6,
    OFPT_GET_CONFIG_REQUEST = 7,
    OFPT_GET_CONFIG_REPLY = 8,
    OFPT_SET_CONFIG = 9,
    OFPT_PACKET_IN = 10,
    OFPT_FLOW_REMOVED = 11,
    OFPT_PORT_STATUS = 12,
    OFPT_PACKET_OUT = 13,
    OFPT_FLOW_MOD = 14,
    OFPT_GROUP_MOD = 15,
    OFPT_PORT_MOD = 16,
    OFPT_TABLE_MOD = 17,
    OFPT_STATS_REQUEST = 18,
    OFPT_STATS_REPLY = 19,
    OFPT_BARRIER_REQUEST = 20,
    OFPT_BARRIER_REPLY = 21,
    OFPT_QUEUE_GET_CONFIG_REQUEST = 22,
    OFPT_QUEUE_GET_CONFIG_REPLY = 23,
    OFPT_ROLE_REQUEST = 24,
    OFPT_ROLE_REPLY = 25,
};

enum ofp_config_flags(wire_type=uint16_t, bitmask=True) {
    OFPC_FRAG_NORMAL = 0,
    OFPC_FRAG_DROP = 1,
    OFPC_FRAG_REASM = 2,
    OFPC_FRAG_MASK = 3,
    OFPC_INVALID_TTL_TO_CONTROLLER = 4,
};

enum ofp_table_config(wire_type=uint32_t, bitmask=True) {
    OFPTC_TABLE_MISS_CONTROLLER = 0,
    OFPTC_TABLE_MISS_CONTINUE = 1,
    OFPTC_TABLE_MISS_DROP = 2,
    OFPTC_TABLE_MISS_MASK = 3,
};

enum ofp_table(wire_type=uint8_t, complete=False) {
    OFPTT_MAX = 0xfe,
    OFPTT_ALL = 0xff,
};

enum ofp_capabilities(wire_type=uint32_t, bitmask=True) {
    OFPC_FLOW_STATS = 0x1,
    OFPC_TABLE_STATS = 0x2,
    OFPC_PORT_STATS = 0x4,
    OFPC_GROUP_STATS = 0x8,
    OFPC_IP_REASM = 0x20,
    OFPC_QUEUE_STATS = 0x40,
    OFPC_PORT_BLOCKED = 0x100,
};

enum ofp_port_config(wire_type=uint32_t, bitmask=True) {
    OFPPC_PORT_DOWN = 0x1,
    OFPPC_NO_RECV = 0x4,
    OFPPC_NO_FWD = 0x20,
    OFPPC_NO_PACKET_IN = 0x40,
};

enum ofp_port_state(wire_type=uint32_t, bitmask=True) {
    OFPPS_LINK_DOWN = 0x1,
    OFPPS_BLOCKED = 0x2,
    OFPPS_LIVE = 0x4,
};

enum ofp_port_features(wire_type=uint32_t, bitmask=True) {
    OFPPF_10MB_HD = 0x1,
    OFPPF_10MB_FD = 0x2,
    OFPPF_100MB_HD = 0x4,
    OFPPF_100MB_FD = 0x8,
    OFPPF_1GB_HD = 0x10,
    OFPPF_1GB_FD = 0x20,
    OFPPF_10GB_FD = 0x40,
    OFPPF_40GB_FD = 0x80,
    OFPPF_100GB_FD = 0x100,
    OFPPF_1TB_FD = 0x200,
    OFPPF_OTHER = 0x400,
    OFPPF_COPPER = 0x800,
    OFPPF_FIBER = 0x1000,
    OFPPF_AUTONEG = 0x2000,
    OFPPF_PAUSE = 0x4000,
    OFPPF_PAUSE_ASYM = 0x8000,
};

enum ofp_port_reason(wire_type=uint8_t) {
    OFPPR_ADD = 0,
    OFPPR_DELETE = 1,
    OFPPR_MODIFY = 2,
};

enum ofp_match_type(wire_type=uint16_t) {
    OFPMT_STANDARD = 0,
    OFPMT_OXM = 1,
};

enum ofp_oxm_class(wire_type=uint16_t) {
    OFPXMC_NXM_0 = 0,
    OFPXMC_NXM_1 = 1,
    OFPXMC_OPENFLOW_BASIC = 0x8000,
    OFPXMC_EXPERIMENTER = 0xffff,
};

enum ofp_vlan_id(wire_type=uint16_t) {
    OFPVID_NONE = 0,
    OFPVID_PRESENT = 0x1000,
};

enum ofp_action_type(wire_type=uint16_t) {
    OFPAT_OUTPUT = 0,
    OFPAT_COPY_TTL_OUT = 0xb,
    OFPAT_COPY_TTL_IN = 0xc,
    OFPAT_SET_MPLS_TTL = 0xf,
    OFPAT_DEC_MPLS_TTL = 0x10,
    OFPAT_PUSH_VLAN = 0x11,
    OFPAT_POP_VLAN = 0x12,
    OFPAT_PUSH_MPLS = 0x13,
    OFPAT_POP_MPLS = 0x14,
    OFPAT_SET_QUEUE = 0x15,
    OFPAT_GROUP = 0x16,
    OFPAT_SET_NW_TTL = 0x17,
    OFPAT_DEC_NW_TTL = 0x18,
    OFPAT_SET_FIELD = 0x19,
    OFPAT_EXPERIMENTER = 0xffff,
};

enum ofp_controller_max_len(wire_type=uint16_t, complete=False) {
    OFPCML_MAX = 0xffe5,
    OFPCML_NO_BUFFER = 0xffff,
};

enum ofp_instruction_type(wire_type=uint16_t, bitmask=True) {
    OFPIT_GOTO_TABLE = 0x1,
    OFPIT_WRITE_METADATA = 0x2,
    OFPIT_WRITE_ACTIONS = 0x3,
    OFPIT_APPLY_ACTIONS = 0x4,
    OFPIT_CLEAR_ACTIONS = 0x5,
    OFPIT_EXPERIMENTER = 0xffff,
};

enum ofp_flow_mod_command(wire_type=uint8_t) {
    OFPFC_ADD = 0,
    OFPFC_MODIFY = 1,
    OFPFC_MODIFY_STRICT = 2,
    OFPFC_DELETE = 3,
    OFPFC_DELETE_STRICT = 4,
};

enum ofp_flow_mod_flags(wire_type=uint16_t, bitmask=True) {
    OFPFF_SEND_FLOW_REM = 0x1,
    OFPFF_CHECK_OVERLAP = 0x2,
    OFPFF_RESET_COUNTS = 0x4,
};

enum ofp_group(wire_type=uint32_t, complete=False) {
    OFPG_MAX = 0xffffff00,
    OFPG_ALL = 0xfffffffc,
    OFPG_ANY = 0xffffffff,
};

enum ofp_group_mod_command(wire_type=uint16_t) {
    OFPGC_ADD = 0,
    OFPGC_MODIFY = 1,
    OFPGC_DELETE = 2,
};

enum ofp_group_type(wire_type=uint8_t) {
    OFPGT_ALL = 0,
    OFPGT_SELECT = 1,
    OFPGT_INDIRECT = 2,
    OFPGT_FF = 3,
};

enum ofp_packet_in_reason(wire_type=uint8_t) {
    OFPR_NO_MATCH = 0,
    OFPR_ACTION = 1,
    OFPR_INVALID_TTL = 2,
};

enum ofp_flow_removed_reason(wire_type=uint8_t) {
    OFPRR_IDLE_TIMEOUT = 0,
    OFPRR_HARD_TIMEOUT = 1,
    OFPRR_DELETE = 2,
    OFPRR_GROUP_DELETE = 3,
};

enum ofp_error_type(wire_type=uint16_t) {
    OFPET_HELLO_FAILED = 0,
    OFPET_BAD_REQUEST = 1,
    OFPET_BAD_ACTION = 2,
    OFPET_BAD_INSTRUCTION = 3,
    OFPET_BAD_MATCH = 4,
    OFPET_FLOW_MOD_FAILED = 5,
    OFPET_GROUP_MOD_FAILED = 6,
    OFPET_PORT_MOD_FAILED = 7,
    OFPET_TABLE_MOD_FAILED = 8,
    OFPET_QUEUE_OP_FAILED = 9,
    OFPET_SWITCH_CONFIG_FAILED = 10,
    OFPET_ROLE_REQUEST_FAILED = 11,
    OFPET_EXPERIMENTER = 0xffff,
};

enum ofp_hello_failed_code(wire_type=uint16_t) {
    OFPHFC_INCOMPATIBLE = 0,
    OFPHFC_EPERM = 1,
};

enum ofp_bad_request_code(wire_type=uint16_t) {
    OFPBRC_BAD_VERSION = 0,
    OFPBRC_BAD_TYPE = 1,
    OFPBRC_BAD_STAT = 2,
    OFPBRC_BAD_EXPERIMENTER = 3,
    OFPBRC_BAD_EXP_TYPE = 4,
    OFPBRC_EPERM = 5,
    OFPBRC_BAD_LEN = 6,
    OFPBRC_BUFFER_EMPTY = 7,
    OFPBRC_BUFFER_UNKNOWN = 8,
    OFPBRC_BAD_TABLE_ID = 9,
    OFPBRC_IS_SLAVE = 10,
    OFPBRC_BAD_PORT = 11,
    OFPBRC_BAD_PACKET = 12,
};

enum ofp_bad_action_code(wire_type=uint16_t) {
    OFPBAC_BAD_TYPE = 0,
    OFPBAC_BAD_LEN = 1,
    OFPBAC_BAD_EXPERIMENTER = 2,
    OFPBAC_BAD_EXP_TYPE = 3,
    OFPBAC_BAD_OUT_PORT = 4,
    OFPBAC_BAD_ARGUMENT = 5,
    OFPBAC_EPERM = 6,
    OFPBAC_TOO_MANY = 7,
    OFPBAC_BAD_QUEUE = 8,
    OFPBAC_BAD_OUT_GROUP = 9,
    OFPBAC_MATCH_INCONSISTENT = 10,
    OFPBAC_UNSUPPORTED_ORDER = 11,
    OFPBAC_BAD_TAG = 12,
    OFPBAC_BAD_SET_TYPE = 13,
    OFPBAC_BAD_SET_LEN = 14,
    OFPBAC_BAD_SET_ARGUMENT = 15,
};

enum ofp_bad_instruction_code(wire_type=uint16_t) {
    OFPBIC_UNKNOWN_INST = 0,
    OFPBIC_UNSUP_INST = 1,
    OFPBIC_BAD_TABLE_ID = 2,
    OFPBIC_UNSUP_METADATA = 3,
    OFPBIC_UNSUP_METADATA_MASK = 4,
    OFPBIC_BAD_EXPERIMENTER = 5,
    OFPBIC_BAD_EXP_TYPE = 6,
    OFPBIC_BAD_LEN = 7,
    OFPBIC_EPERM = 8,
};

enum ofp_bad_match_code(wire_type=uint16_t) {
    OFPBMC_BAD_TYPE = 0,
    OFPBMC_BAD_LEN = 1,
    OFPBMC_BAD_TAG = 2,
    OFPBMC_BAD_DL_ADDR_MASK = 3,
    OFPBMC_BAD_NW_ADDR_MASK = 4,
    OFPBMC_BAD_WILDCARDS = 5,
    OFPBMC_BAD_FIELD = 6,
    OFPBMC_BAD_VALUE = 7,
    OFPBMC_BAD_MASK = 8,
    OFPBMC_BAD_PREREQ = 9,
    OFPBMC_DUP_FIELD = 10,
    OFPBMC_EPERM = 11,
};

enum ofp_flow_mod_failed_code(wire_type=uint16_t) {
    OFPFMFC_UNKNOWN = 0,
    OFPFMFC_TABLE_FULL = 1,
    OFPFMFC_BAD_TABLE_ID = 2,
    OFPFMFC_OVERLAP = 3,
    OFPFMFC_EPERM = 4,
    OFPFMFC_BAD_TIMEOUT = 5,
    OFPFMFC_BAD_COMMAND = 6,
    OFPFMFC_BAD_FLAGS = 7,
};

enum ofp_group_mod_failed_code(wire_type=uint16_t) {
    OFPGMFC_GROUP_EXISTS = 0,
    OFPGMFC_INVALID_GROUP = 1,
    OFPGMFC_WEIGHT_UNSUPPORTED = 2,
    OFPGMFC_OUT_OF_GROUPS = 3,
    OFPGMFC_OUT_OF_BUCKETS = 4,
    OFPGMFC_CHAINING_UNSUPPORTED = 5,
    OFPGMFC_WATCH_UNSUPPORTED = 6,
    OFPGMFC_LOOP = 7,
    OFPGMFC_UNKNOWN_GROUP = 8,
    OFPGMFC_CHAINED_GROUP = 9,
    OFPGMFC_BAD_TYPE = 10,
    OFPGMFC_BAD_COMMAND = 11,
    OFPGMFC_BAD_BUCKET = 12,
    OFPGMFC_BAD_WATCH = 13,
    OFPGMFC_EPERM = 14,
};

enum ofp_port_mod_failed_code(wire_type=uint16_t) {
    OFPPMFC_BAD_PORT = 0,
    OFPPMFC_BAD_HW_ADDR = 1,
    OFPPMFC_BAD_CONFIG = 2,
    OFPPMFC_BAD_ADVERTISE = 3,
    OFPPMFC_EPERM = 4,
};

enum ofp_table_mod_failed_code(wire_type=uint16_t) {
    OFPTMFC_BAD_TABLE = 0,
    OFPTMFC_BAD_CONFIG = 1,
    OFPTMFC_EPERM = 2,
};

enum ofp_queue_op_failed_code(wire_type=uint16_t) {
    OFPQOFC_BAD_PORT = 0,
    OFPQOFC_BAD_QUEUE = 1,
    OFPQOFC_EPERM = 2,
};

enum ofp_switch_config_failed_code(wire_type=uint16_t) {
    OFPSCFC_BAD_FLAGS = 0,
    OFPSCFC_BAD_LEN = 1,
    OFPSCFC_EPERM = 2,
};

enum ofp_role_request_failed_code (wire_type=uint16_t){
    OFPRRFC_STALE = 0,
    OFPRRFC_UNSUP = 1,
    OFPRRFC_BAD_ROLE = 2,
};

enum ofp_stats_types(wire_type=uint16_t) {
    OFPST_DESC = 0,
    OFPST_FLOW = 1,
    OFPST_AGGREGATE = 2,
    OFPST_TABLE = 3,
    OFPST_PORT = 4,
    OFPST_QUEUE = 5,
    OFPST_GROUP = 6,
    OFPST_GROUP_DESC = 7,
    OFPST_GROUP_FEATURES = 8,
    OFPST_EXPERIMENTER = 0xffff,
};

enum ofp_stats_reply_flags(wire_type=uint16_t, bitmask=True) {
    OFPSF_REPLY_MORE = 0x1,
};

enum ofp_group_capabilities(wire_type=uint32_t, bitmask=True) {
    OFPGFC_SELECT_WEIGHT = 0x1,
    OFPGFC_SELECT_LIVENESS = 0x2,
    OFPGFC_CHAINING = 0x4,
    OFPGFC_CHAINING_CHECKS = 0x8,
};

enum ofp_queue_properties(wire_type=uint16_t) {
    OFPQT_MIN_RATE = 0x1,
    OFPQT_MAX_RATE = 0x2,
    OFPQT_EXPERIMENTER = 0xffff,
};

enum ofp_controller_role(wire_type=uint32_t) {
    OFPCR_ROLE_NOCHANGE = 0,
    OFPCR_ROLE_EQUAL = 1,
    OFPCR_ROLE_MASTER = 2,
    OFPCR_ROLE_SLAVE = 3,
};

struct of_header {
    uint8_t version;
    uint8_t type;
    uint16_t length;
    uint32_t xid;
};

struct of_hello {
    uint8_t version;
    uint8_t type == 0;
    uint16_t length;
    uint32_t xid;
};

struct of_echo_request {
    uint8_t version;
    uint8_t type == 2;
    uint16_t length;
    uint32_t xid;
    of_octets_t data;
};

struct of_echo_reply {
    uint8_t version;
    uint8_t type == 3;
    uint16_t length;
    uint32_t xid;
    of_octets_t data;
};

struct of_experimenter {
    uint8_t version;
    uint8_t type == 4;
    uint16_t length;
    uint32_t xid;
    uint32_t experimenter;
    uint32_t subtype;
    of_octets_t data;
};

struct of_barrier_request {
    uint8_t version;
    uint8_t type == 20;
    uint16_t length;
    uint32_t xid;
};

struct of_barrier_reply {
    uint8_t version;
    uint8_t type == 21;
    uint16_t length;
    uint32_t xid;
};

struct of_get_config_request {
    uint8_t version;
    uint8_t type == 7;
    uint16_t length;
    uint32_t xid;
};

struct of_get_config_reply {
    uint8_t version;
    uint8_t type == 8;
    uint16_t length;
    uint32_t xid;
    uint16_t flags;
    uint16_t miss_send_len;
};

struct of_set_config {
    uint8_t version;
    uint8_t type == 9;
    uint16_t length;
    uint32_t xid;
    uint16_t flags;
    uint16_t miss_send_len;
};

struct of_table_mod {
    uint8_t version;
    uint8_t type == 17;
    uint16_t length;
    uint32_t xid;
    uint8_t table_id;
    pad(3);
    uint32_t config;
};

struct of_port_desc {
    of_port_no_t port_no;
    pad(4);
    of_mac_addr_t hw_addr;
    pad(2);
    of_port_name_t name;
    uint32_t config;
    uint32_t state;
    uint32_t curr;
    uint32_t advertised;
    uint32_t supported;
    uint32_t peer;
    uint32_t curr_speed;
    uint32_t max_speed;
};

struct of_features_request {
    uint8_t version;
    uint8_t type == 5;
    uint16_t length;
    uint32_t xid;
};

struct of_features_reply {
    uint8_t version;
    uint8_t type == 6;
    uint16_t length;
    uint32_t xid;
    uint64_t datapath_id;
    uint32_t n_buffers;
    uint8_t n_tables;
    pad(3);
    uint32_t capabilities;
    uint32_t reserved;
    list(of_port_desc_t) ports;
};

struct of_port_status {
    uint8_t version;
    uint8_t type == 12;
    uint16_t length;
    uint32_t xid;
    uint8_t reason;
    pad(7);
    of_port_desc_t desc;
};

struct of_port_mod {
    uint8_t version;
    uint8_t type == 16;
    uint16_t length;
    uint32_t xid;
    of_port_no_t port_no;
    pad(4);
    of_mac_addr_t hw_addr;
    pad(2);
    uint32_t config;
    uint32_t mask;
    uint32_t advertise;
    pad(4);
};

struct of_match_v3 {
    uint16_t type == 1;
    uint16_t length;
    list(of_oxm_t) oxm_list;
};

struct of_action_output {
    uint16_t type == 0;
    uint16_t len;
    of_port_no_t port;
    uint16_t max_len;
    pad(6);
};

struct of_action_copy_ttl_out {
    uint16_t type == 11;
    uint16_t len;
    pad(4);
};

struct of_action_copy_ttl_in {
    uint16_t type == 12;
    uint16_t len;
    pad(4);
};

struct of_action_set_mpls_ttl {
    uint16_t type == 15;
    uint16_t len;
    uint8_t mpls_ttl;
    pad(3);
};

struct of_action_dec_mpls_ttl {
    uint16_t type == 16;
    uint16_t len;
    pad(4);
};

struct of_action_push_vlan {
    uint16_t type == 17;
    uint16_t len;
    uint16_t ethertype;
    pad(2);
};

struct of_action_pop_vlan {
    uint16_t type == 18;
    uint16_t len;
    pad(4);
};

struct of_action_push_mpls {
    uint16_t type == 19;
    uint16_t len;
    uint16_t ethertype;
    pad(2);
};

struct of_action_pop_mpls {
    uint16_t type == 20;
    uint16_t len;
    uint16_t ethertype;
    pad(2);
};

struct of_action_set_queue {
    uint16_t type == 21;
    uint16_t len;
    uint32_t queue_id;
};

struct of_action_group {
    uint16_t type == 22;
    uint16_t len;
    uint32_t group_id;
};

struct of_action_set_nw_ttl {
    uint16_t type == 23;
    uint16_t len;
    uint8_t nw_ttl;
    pad(3);
};

struct of_action_dec_nw_ttl {
    uint16_t type == 24;
    uint16_t len;
    pad(4);
};

struct of_action_set_field {
    uint16_t type == 25;
    uint16_t len;
    of_oxm_t field;
};

struct of_action_experimenter {
    uint16_t type == 65535;
    uint16_t len;
    uint32_t experimenter;
    of_octets_t data;
};

struct of_action {
    uint16_t type;
    uint16_t len;
    pad(4);
};

struct of_instruction {
    uint16_t type;
    uint16_t len;
    pad(4);
};

struct of_instruction_goto_table {
    uint16_t type == 1;
    uint16_t len;
    uint8_t table_id;
    pad(3);
};

struct of_instruction_write_metadata {
    uint16_t type == 2;
    uint16_t len;
    pad(4);
    uint64_t metadata;
    uint64_t metadata_mask;
};

struct of_instruction_write_actions {
    uint16_t type == 3;
    uint16_t len;
    pad(4);
    list(of_action_t) actions;
};

struct of_instruction_apply_actions {
    uint16_t type == 4;
    uint16_t len;
    pad(4);
    list(of_action_t) actions;
};

struct of_instruction_clear_actions {
    uint16_t type == 5;
    uint16_t len;
    pad(4);
};

struct of_instruction_experimenter {
    uint16_t type == 65535;
    uint16_t len;
    uint32_t experimenter;
    of_octets_t data;
};

struct of_flow_add {
    uint8_t version;
    uint8_t type == 14;
    uint16_t length;
    uint32_t xid;
    uint64_t cookie;
    uint64_t cookie_mask;
    uint8_t table_id;
    of_fm_cmd_t _command == 0;
    uint16_t idle_timeout;
    uint16_t hard_timeout;
    uint16_t priority;
    uint32_t buffer_id;
    of_port_no_t out_port;
    uint32_t out_group;
    uint16_t flags;
    pad(2);
    of_match_t match;
    list(of_instruction_t) instructions;
};

struct of_flow_modify {
    uint8_t version;
    uint8_t type == 14;
    uint16_t length;
    uint32_t xid;
    uint64_t cookie;
    uint64_t cookie_mask;
    uint8_t table_id;
    of_fm_cmd_t _command == 1;
    uint16_t idle_timeout;
    uint16_t hard_timeout;
    uint16_t priority;
    uint32_t buffer_id;
    of_port_no_t out_port;
    uint32_t out_group;
    uint16_t flags;
    pad(2);
    of_match_t match;
    list(of_instruction_t) instructions;
};

struct of_flow_modify_strict {
    uint8_t version;
    uint8_t type == 14;
    uint16_t length;
    uint32_t xid;
    uint64_t cookie;
    uint64_t cookie_mask;
    uint8_t table_id;
    of_fm_cmd_t _command == 2;
    uint16_t idle_timeout;
    uint16_t hard_timeout;
    uint16_t priority;
    uint32_t buffer_id;
    of_port_no_t out_port;
    uint32_t out_group;
    uint16_t flags;
    pad(2);
    of_match_t match;
    list(of_instruction_t) instructions;
};

struct of_flow_delete {
    uint8_t version;
    uint8_t type == 14;
    uint16_t length;
    uint32_t xid;
    uint64_t cookie;
    uint64_t cookie_mask;
    uint8_t table_id;
    of_fm_cmd_t _command == 3;
    uint16_t idle_timeout;
    uint16_t hard_timeout;
    uint16_t priority;
    uint32_t buffer_id;
    of_port_no_t out_port;
    uint32_t out_group;
    uint16_t flags;
    pad(2);
    of_match_t match;
    list(of_instruction_t) instructions;
};

struct of_flow_delete_strict {
    uint8_t version;
    uint8_t type == 14;
    uint16_t length;
    uint32_t xid;
    uint64_t cookie;
    uint64_t cookie_mask;
    uint8_t table_id;
    of_fm_cmd_t _command == 4;
    uint16_t idle_timeout;
    uint16_t hard_timeout;
    uint16_t priority;
    uint32_t buffer_id;
    of_port_no_t out_port;
    uint32_t out_group;
    uint16_t flags;
    pad(2);
    of_match_t match;
    list(of_instruction_t) instructions;
};

struct of_bucket {
    uint16_t len;
    uint16_t weight;
    of_port_no_t watch_port;
    uint32_t watch_group;
    pad(4);
    list(of_action_t) actions;
};

struct of_group_mod {
    uint8_t version;
    uint8_t type == 15;
    uint16_t length;
    uint32_t xid;
    uint16_t command;
    uint8_t group_type;
    pad(1);
    uint32_t group_id;
    list(of_bucket_t) buckets;
};

struct of_packet_out {
    uint8_t version;
    uint8_t type == 13;
    uint16_t length;
    uint32_t xid;
    uint32_t buffer_id;
    of_port_no_t in_port;
    uint16_t actions_len;
    pad(6);
    list(of_action_t) actions;
    of_octets_t data;
};

struct of_packet_in {
    uint8_t version;
    uint8_t type == 10;
    uint16_t length;
    uint32_t xid;
    uint32_t buffer_id;
    uint16_t total_len;
    uint8_t reason;
    uint8_t table_id;
    of_match_t match;
    pad(2);
    of_octets_t data; /* FIXME: Ensure total_len gets updated */
};

struct of_flow_removed {
    uint8_t version;
    uint8_t type == 11;
    uint16_t length;
    uint32_t xid;
    uint64_t cookie;
    uint16_t priority;
    uint8_t reason;
    uint8_t table_id;
    uint32_t duration_sec;
    uint32_t duration_nsec;
    uint16_t idle_timeout;
    uint16_t hard_timeout;
    uint64_t packet_count;
    uint64_t byte_count;
    of_match_t match;
};

struct of_error_msg {
    uint8_t version;
    uint8_t type == 1;
    uint16_t length;
    uint32_t xid;
    uint16_t err_type;
    uint16_t code;
    of_octets_t data;
};

// struct of_error_experimenter_msg {
//    uint8_t version;
//    uint8_t type;
//    uint16_t length;
//    uint32_t xid;
//    uint16_t err_type;
//    uint16_t subtype;
//    uint32_t experimenter;
//    of_octets_t data;
//};

// STATS ENTRIES: flow, table, port, queue, group stats, group desc stats
// FIXME: Verify disambiguation w/ length in object and entry

struct of_flow_stats_entry {
    uint16_t length;
    uint8_t table_id;
    pad(1);
    uint32_t duration_sec;
    uint32_t duration_nsec;
    uint16_t priority;
    uint16_t idle_timeout;
    uint16_t hard_timeout;
    pad(6);
    uint64_t cookie;
    uint64_t packet_count;
    uint64_t byte_count;
    of_match_t match;
    list(of_instruction_t) instructions;
};

struct of_table_stats_entry {
    uint8_t table_id;
    pad(7);
    of_table_name_t name;
    of_match_bmap_t match;
    of_wc_bmap_t wildcards;
    uint32_t write_actions;
    uint32_t apply_actions;
    uint64_t write_setfields;
    uint64_t apply_setfields;
    uint64_t metadata_match;
    uint64_t metadata_write;
    uint32_t instructions;
    uint32_t config;
    uint32_t max_entries;
    uint32_t active_count;
    uint64_t lookup_count;
    uint64_t matched_count;
};

struct of_port_stats_entry {
    of_port_no_t port_no;
    pad(4);
    uint64_t rx_packets;
    uint64_t tx_packets;
    uint64_t rx_bytes;
    uint64_t tx_bytes;
    uint64_t rx_dropped;
    uint64_t tx_dropped;
    uint64_t rx_errors;
    uint64_t tx_errors;
    uint64_t rx_frame_err;
    uint64_t rx_over_err;
    uint64_t rx_crc_err;
    uint64_t collisions;
};

struct of_queue_stats_entry {
    of_port_no_t port_no;
    uint32_t queue_id;
    uint64_t tx_bytes;
    uint64_t tx_packets;
    uint64_t tx_errors;
};

struct of_bucket_counter {
    uint64_t packet_count;
    uint64_t byte_count;
};

struct of_group_stats_entry {
    uint16_t length;
    pad(2);
    uint32_t group_id;
    uint32_t ref_count;
    pad(4);
    uint64_t packet_count;
    uint64_t byte_count;
    list(of_bucket_counter_t) bucket_stats;
};

struct of_group_desc_stats_entry {
    uint16_t length;
    uint8_t type;
    pad(1);
    uint32_t group_id;
    list(of_bucket_t) buckets;
};

// STATS: 
//  Desc, flow, agg, table, port, queue, group, group_desc, group_feat, experi

struct of_desc_stats_request {
    uint8_t version;
    uint8_t type == 18;
    uint16_t length;
    uint32_t xid;
    uint16_t stats_type == 0;
    uint16_t flags;
    pad(4);
};

struct of_desc_stats_reply {
    uint8_t version;
    uint8_t type == 19;
    uint16_t length;
    uint32_t xid;
    uint16_t stats_type == 0;
    uint16_t flags;
    pad(4);
    of_desc_str_t mfr_desc;
    of_desc_str_t hw_desc;
    of_desc_str_t sw_desc;
    of_serial_num_t serial_num;
    of_desc_str_t dp_desc;
};

struct of_flow_stats_request {
    uint8_t version;
    uint8_t type == 18;
    uint16_t length;
    uint32_t xid;
    uint16_t stats_type == 1;
    uint16_t flags;
    pad(4);
    uint8_t table_id;
    pad(3);
    of_port_no_t out_port;
    uint32_t out_group;
    pad(4);
    uint64_t cookie;
    uint64_t cookie_mask;
    of_match_t match;
};

struct of_flow_stats_reply {
    uint8_t version;
    uint8_t type == 19;
    uint16_t length;
    uint32_t xid;
    uint16_t stats_type == 1;
    uint16_t flags;
    pad(4);
    list(of_flow_stats_entry_t) entries;
};

struct of_aggregate_stats_request {
    uint8_t version;
    uint8_t type == 18;
    uint16_t length;
    uint32_t xid;
    uint16_t stats_type == 2;
    uint16_t flags;
    pad(4);
    uint8_t table_id;
    pad(3);
    of_port_no_t out_port;
    uint32_t out_group;
    pad(4);
    uint64_t cookie;
    uint64_t cookie_mask;
    of_match_t match;
};

struct of_aggregate_stats_reply {
    uint8_t version;
    uint8_t type == 19;
    uint16_t length;
    uint32_t xid;
    uint16_t stats_type == 2;
    uint16_t flags;
    pad(4);
    uint64_t packet_count;
    uint64_t byte_count;
    uint32_t flow_count;
    pad(4);
};

struct of_table_stats_request {
    uint8_t version;
    uint8_t type == 18;
    uint16_t length;
    uint32_t xid;
    uint16_t stats_type == 3;
    uint16_t flags;
    pad(4);
};

struct of_table_stats_reply {
    uint8_t version;
    uint8_t type == 19;
    uint16_t length;
    uint32_t xid;
    uint16_t stats_type == 3;
    uint16_t flags;
    pad(4);
    list(of_table_stats_entry_t) entries;
};

struct of_port_stats_request {
    uint8_t version;
    uint8_t type == 18;
    uint16_t length;
    uint32_t xid;
    uint16_t stats_type == 4;
    uint16_t flags;
    pad(4);
    of_port_no_t port_no;
    pad(4);
};

struct of_port_stats_reply {
    uint8_t version;
    uint8_t type == 19;
    uint16_t length;
    uint32_t xid;
    uint16_t stats_type == 4;
    uint16_t flags;
    pad(4);
    list(of_port_stats_entry_t) entries;
};

struct of_queue_stats_request {
    uint8_t version;
    uint8_t type == 18;
    uint16_t length;
    uint32_t xid;
    uint16_t stats_type == 5;
    uint16_t flags;
    pad(4);
    of_port_no_t port_no;
    uint32_t queue_id;
};

struct of_queue_stats_reply {
    uint8_t version;
    uint8_t type == 19;
    uint16_t length;
    uint32_t xid;
    uint16_t stats_type == 5;
    uint16_t flags;
    pad(4);
    list(of_queue_stats_entry_t) entries;
};

struct of_group_stats_request {
    uint8_t version;
    uint8_t type == 18;
    uint16_t length;
    uint32_t xid;
    uint16_t stats_type == 6;
    uint16_t flags;
    pad(4);
    uint32_t group_id;
    pad(4);
};

struct of_group_stats_reply {
    uint8_t version;
    uint8_t type == 19;
    uint16_t length;
    uint32_t xid;
    uint16_t stats_type == 6;
    uint16_t flags;
    pad(4);
    list(of_group_stats_entry_t) entries;
};

struct of_group_desc_stats_request {
    uint8_t version;
    uint8_t type == 18;
    uint16_t length;
    uint32_t xid;
    uint16_t stats_type == 7;
    uint16_t flags;
    pad(4);
};

struct of_group_desc_stats_reply {
    uint8_t version;
    uint8_t type == 19;
    uint16_t length;
    uint32_t xid;
    uint16_t stats_type == 7;
    uint16_t flags;
    pad(4);
    list(of_group_desc_stats_entry_t) entries;
};

struct of_group_features_stats_request {
    uint8_t version;
    uint8_t type == 18;
    uint16_t length;
    uint32_t xid;
    uint16_t stats_type == 8;
    uint16_t flags;
    pad(4);
};

struct of_group_features_stats_reply {
    uint8_t version;
    uint8_t type == 19;
    uint16_t length;
    uint32_t xid;
    uint16_t stats_type == 8;
    uint16_t flags;
    pad(4);
    uint32_t types;
    uint32_t capabilities;
    uint32_t max_groups_all;
    uint32_t max_groups_select;
    uint32_t max_groups_indirect;
    uint32_t max_groups_ff;
    uint32_t actions_all;
    uint32_t actions_select;
    uint32_t actions_indirect;
    uint32_t actions_ff;
};

struct of_experimenter_stats_request {
    uint8_t version;
    uint8_t type == 18;
    uint16_t length;
    uint32_t xid;
    uint16_t stats_type == 0xffff;
    uint16_t flags;
    pad(4);
    uint32_t experimenter;
    uint32_t subtype;
    of_octets_t data;
};

struct of_experimenter_stats_reply {
    uint8_t version;
    uint8_t type == 19;
    uint16_t length;
    uint32_t xid;
    uint16_t stats_type == 0xffff;
    uint16_t flags;
    pad(4);
    uint32_t experimenter;
    uint32_t subtype;
    of_octets_t data;
};

// END OF STATS OBJECTS

struct of_queue_prop {
    uint16_t type;
    uint16_t len;
    pad(4);
};

struct of_queue_prop_min_rate {
    uint16_t type == 1;
    uint16_t len;
    pad(4);
    uint16_t rate;
    pad(6);
};

struct of_queue_prop_max_rate {
    uint16_t type == 2;
    uint16_t len;
    pad(4);
    uint16_t rate;
    pad(6);
};

struct of_queue_prop_experimenter {
    uint16_t type == 65535;
    uint16_t len;
    pad(4);
    uint32_t experimenter;
    pad(4);
    of_octets_t data;
};

struct of_packet_queue {
    uint32_t queue_id;
    of_port_no_t port;
    uint16_t len;
    pad(6);
    list(of_queue_prop_t) properties;
};

struct of_queue_get_config_request {
    uint8_t version;
    uint8_t type == 22;
    uint16_t length;
    uint32_t xid;
    of_port_no_t port;
    pad(4);
};

struct of_queue_get_config_reply {
    uint8_t version;
    uint8_t type == 23;
    uint16_t length;
    uint32_t xid;
    of_port_no_t port;
    pad(4);
    list(of_packet_queue_t) queues;
};

struct of_role_request {
    uint8_t version;
    uint8_t type == 24;
    uint16_t length;
    uint32_t xid;
    uint32_t role;
    pad(4);
    uint64_t generation_id;
};

struct of_role_reply {
    uint8_t version;
    uint8_t type == 25;
    uint16_t length;
    uint32_t xid;
    of_octets_t data;
};
