diff --git a/c_gen/c_code_gen.py b/c_gen/c_code_gen.py
index 9add81b00..d138103d5 100644
--- a/c_gen/c_code_gen.py
+++ b/c_gen/c_code_gen.py
@@ -659,10 +659,13 @@ def base_h_content(out):
/* Currently these are categorized as scalars */
typedef char of_port_name_t[OF_MAX_PORT_NAME_LEN];
+typedef char of_app_code_t[OF_APP_CODE_LEN];
typedef char of_table_name_t[OF_MAX_TABLE_NAME_LEN];
typedef char of_desc_str_t[OF_DESC_STR_LEN];
typedef char of_serial_num_t[OF_SERIAL_NUM_LEN];
typedef char of_str64_t[64];
+typedef char of_str32_t[32];
+typedef char of_str6_t[6];
typedef struct of_bitmap_128_s {
uint64_t hi;
diff --git a/c_gen/c_test_gen.py b/c_gen/c_test_gen.py
index 955f34f6e..50d496b1b 100644
--- a/c_gen/c_test_gen.py
+++ b/c_gen/c_test_gen.py
@@ -93,6 +93,8 @@ def var_name_map(m_type):
of_desc_str_t="desc_str",
of_serial_num_t="ser_num",
of_str64_t="str64",
+ of_str32_t="str32",
+ of_str6_t="str6",
of_mac_addr_t="mac_addr",
of_ipv6_t="ipv6",
# Non-scalars; more TBD
@@ -107,6 +109,9 @@ def var_name_map(m_type):
of_bitmap_128_t="bitmap_128",
of_bitmap_512_t="bitmap_512",
of_checksum_128_t="checksum_128",
+ #Circuit extensions
+ of_app_code_t="app_code",
+ of_sig_id_t="sig_id",
)
if m_type.find("of_list_") == 0:
@@ -121,7 +126,8 @@ def var_name_map(m_type):
string_types = [ "of_port_name_t", "of_table_name_t",
"of_desc_str_t", "of_serial_num_t", "of_mac_addr_t",
"of_ipv6_t", "of_bitmap_128_t", "of_checksum_128_t",
- "of_str64_t", "of_bitmap_512_t"]
+ "of_str64_t", "of_str32_t", "of_str6_t",
+ "of_app_code_t", "of_bitmap_512_t"]
scalar_types = integer_types[:]
scalar_types.extend(string_types)
diff --git a/c_gen/of_g_legacy.py b/c_gen/of_g_legacy.py
index 9c0722cae..fe58e5662 100644
--- a/c_gen/of_g_legacy.py
+++ b/c_gen/of_g_legacy.py
@@ -86,7 +86,9 @@
OF_MAX_PORT_NAME_LEN = 16,
OF_ETH_ALEN = 6,
OF_DESC_STR_LEN = 256,
- OF_SERIAL_NUM_LEN = 32
+ OF_SERIAL_NUM_LEN = 32,
+ OF_APP_CODE_LEN = 15,
+ OF_SIGID_LEN=6,
)
## List of mixed data types
@@ -199,6 +201,8 @@
of_serial_num_t = dict(bytes=ofp_constants["OF_SERIAL_NUM_LEN"],
short_name="ser_num"),
of_str64_t = dict(bytes=64, short_name="str64"),
+ of_str32_t = dict(bytes=32, short_name="str32"),
+ of_str6_t = dict(bytes=6, short_name="str6"),
of_match_v1_t = dict(bytes=40, to_w="match_v1_hton",
from_w="match_v1_ntoh",
short_name="match_v1"),
@@ -215,6 +219,10 @@
of_bitmap_128_t = dict(bytes=16, short_name="bitmap_128"),
of_bitmap_512_t = dict(bytes=64, short_name="bitmap_512"),
of_checksum_128_t = dict(bytes=16, short_name="checksum_128"),
+ of_app_code_t = dict(bytes=ofp_constants["OF_APP_CODE_LEN"],
+ short_name="app_code"),
+ of_sig_id_t = dict(bytes=ofp_constants["OF_SIGID_LEN"],
+ short_name="sig_id"),
)
of_scalar_types = ["char", "uint8_t", "uint16_t", "uint32_t", "uint64_t",
@@ -222,7 +230,7 @@
"of_match_bmap_t", "of_port_name_t", "of_table_name_t",
"of_desc_str_t", "of_serial_num_t", "of_mac_addr_t",
"of_ipv6_t", "of_ipv4_t", "of_bitmap_128_t", "of_checksum_128_t",
- "of_str64_t", "of_bitmap_512_t"]
+ "of_str64_t", "of_str32_t", "of_str6_t", "of_bitmap_512_t"]
##
# LOXI identifiers
diff --git a/c_gen/templates/loci_dump.h b/c_gen/templates/loci_dump.h
index 89c5f2a83..2eb11b77b 100644
--- a/c_gen/templates/loci_dump.h
+++ b/c_gen/templates/loci_dump.h
@@ -91,6 +91,8 @@ typedef int (*loci_obj_dump_f)(loci_writer_f writer, void *cookie, of_object_t *
#define LOCI_DUMP_desc_str(writer, cookie, val) LOCI_DUMP_string(writer, cookie, val)
#define LOCI_DUMP_ser_num(writer, cookie, val) LOCI_DUMP_string(writer, cookie, val)
#define LOCI_DUMP_str64(writer, cookie, val) LOCI_DUMP_string(writer, cookie, val)
+#define LOCI_DUMP_str6(writer, cookie, val) LOCI_DUMP_string(writer, cookie, val)
+#define LOCI_DUMP_str32(writer, cookie, val) LOCI_DUMP_string(writer, cookie, val)
int loci_dump_match(loci_writer_f writer, void* cookie, of_match_t *match);
#define LOCI_DUMP_match(writer, cookie, val) loci_dump_match(writer, cookie, &val)
diff --git a/c_gen/templates/loci_show.h b/c_gen/templates/loci_show.h
index dc35959ca..6aa2f81ab 100644
--- a/c_gen/templates/loci_show.h
+++ b/c_gen/templates/loci_show.h
@@ -105,6 +105,8 @@ typedef int (*loci_obj_show_f)(loci_writer_f writer,
#define LOCI_SHOW_desc_str(writer, cookie, val) LOCI_SHOW_string(writer, cookie, val)
#define LOCI_SHOW_ser_num(writer, cookie, val) LOCI_SHOW_string(writer, cookie, val)
#define LOCI_SHOW_str64(writer, cookie, val) LOCI_SHOW_string(writer, cookie, val)
+#define LOCI_SHOW_str6(writer, cookie, val) LOCI_SHOW_string(writer, cookie, val)
+#define LOCI_SHOW_str32(writer, cookie, val) LOCI_SHOW_string(writer, cookie, val)
int loci_show_match(loci_writer_f writer, void *cookie, of_match_t *match);
#define LOCI_SHOW_match(writer, cookie, val) loci_show_match(writer, cookie, &val)
diff --git a/c_gen/templates/of_wire_buf.h b/c_gen/templates/of_wire_buf.h
index 9ade2c42d..4edc3a6bc 100644
--- a/c_gen/templates/of_wire_buf.h
+++ b/c_gen/templates/of_wire_buf.h
@@ -888,6 +888,52 @@ _wbuf_octets_get(of_wire_buffer_t *wbuf, int offset, uint8_t *dst, int bytes) {
#define of_wire_buffer_checksum_128_set(buf, offset, checksum) \
(of_wire_buffer_u64_set(buf, offset, checksum.hi), of_wire_buffer_u64_set(buf, offset+8, checksum.lo))
+/**
+ * Get a str32 string from a wire buffer
+ * @param wbuf The pointer to the wire buffer structure
+ * @param offset Offset in the wire buffer
+ * @param s The string
+ *
+ * Uses the octets function.
+ */
+
+#define of_wire_buffer_str32_get(buf, offset, s) \
+ _wbuf_octets_get(buf, offset, (uint8_t *)s, 32)
+
+/**
+ * Set a str32 string in a wire buffer
+ * @param wbuf The pointer to the wire buffer structure
+ * @param offset Offset in the wire buffer
+ * @param s Where to store the str32
+ *
+ * Uses the octets function.
+ */
+
+#define of_wire_buffer_str32_set(buf, offset, s) \
+ _wbuf_octets_set(buf, offset, (uint8_t *)s, 32)
+
+/**
+ * Get a str6 string from a wire buffer
+ * @param wbuf The pointer to the wire buffer structure
+ * @param offset Offset in the wire buffer
+ * @param s The string
+ *
+ * Uses the octets function.
+ */
+
+#define of_wire_buffer_str6_get(buf, offset, s) \
+ _wbuf_octets_get(buf, offset, (uint8_t *)s, 6)
+/**
+ * Set a str6 string in a wire buffer
+ * @param wbuf The pointer to the wire buffer structure
+ * @param offset Offset in the wire buffer
+ * @param s Where to store the str6
+ *
+ * Uses the octets function.
+ */
+
+#define of_wire_buffer_str6_set(buf, offset, s) \
+ _wbuf_octets_set(buf, offset, (uint8_t *)s, 6)
/**
* Get a bitmap_512 from a wire buffer
diff --git a/java_gen/java_type.py b/java_gen/java_type.py
index c007d5218..58a49880c 100644
--- a/java_gen/java_type.py
+++ b/java_gen/java_type.py
@@ -355,10 +355,13 @@ def gen_fixed_length_string_jtype(length):
default="MacAddress.NONE")
port_name = gen_fixed_length_string_jtype(16)
+app_code = gen_fixed_length_string_jtype(15)
desc_str = gen_fixed_length_string_jtype(256)
serial_num = gen_fixed_length_string_jtype(32)
table_name = gen_fixed_length_string_jtype(32)
str64 = gen_fixed_length_string_jtype(64)
+str32 = gen_fixed_length_string_jtype(32)
+str6 = gen_fixed_length_string_jtype(6)
ipv4 = JType("IPv4Address") \
.op(read="IPv4Address.read4Bytes(bb)", \
write="$name.write4Bytes(bb)",
@@ -512,6 +515,9 @@ def gen_fixed_length_string_jtype(length):
.op(read="OFBufferId.of(bb.readInt())", write="bb.writeInt($name.getInt())", default="OFBufferId.NO_BUFFER")
lag_id = JType("LagId") \
.op(version=ANY, read="LagId.read4Bytes(bb)", write="$name.write4Bytes(bb)", default="LagId.NONE")
+
+sig_id = JType("CircuitSignalID") \
+ .op(version=ANY, read="CircuitSignalID.read6Bytes(bb)", write="$name.write6Bytes(bb)", default="CircuitSignalID.NONE")
vrf = JType("VRF") \
.op(version=ANY, read="VRF.read4Bytes(bb)", write="$name.write4Bytes(bb)", default="VRF.ZERO")
class_id = JType("ClassId") \
@@ -572,6 +578,8 @@ def gen_fixed_length_string_jtype(length):
'of_port_name_t': port_name,
'of_table_name_t': table_name,
'of_str64_t': str64,
+ 'of_str32_t': str32,
+ 'of_str6_t': str6,
'of_ipv4_t': ipv4,
'of_ipv6_t': ipv6,
'of_wc_bmap_t': flow_wildcards,
@@ -581,6 +589,8 @@ def gen_fixed_length_string_jtype(length):
'of_bitmap_512_t': port_bitmap_512,
'of_checksum_128_t': u128,
'of_bsn_vport_t': bsn_vport,
+ 'of_app_code_t': app_code,
+ 'of_sig_id_t': sig_id,
'of_table_desc_t': table_desc,
}
@@ -756,6 +766,10 @@ def gen_fixed_length_string_jtype(length):
'of_bsn_log': { 'data': var_string },
'of_features_reply' : { 'auxiliary_id' : of_aux_id},
+ 'of_oxm_och_sigtype' : { 'value' : u8obj },
+ 'of_oxm_och_sigtype_basic' : { 'value' : u8obj },
+ 'of_oxm_och_sigid' : {'value' : sig_id},
+ 'of_oxm_och_sigid_basic' : {'value' : sig_id},
'of_bundle_add_msg' : { 'data' : of_message },
}
diff --git a/java_gen/pre-written/pom.xml b/java_gen/pre-written/pom.xml
index 58ddab398..9e217717d 100644
--- a/java_gen/pre-written/pom.xml
+++ b/java_gen/pre-written/pom.xml
@@ -11,8 +11,8 @@
org.projectfloodlight
openflowj
0.9.0-SNAPSHOT
- jar
-
+ bundle
+
OpenFlowJ-Loxi
OpenFlowJ API supporting OpenFlow versions 1.0 through 1.3.1, generated by LoxiGen
http://www.projectfloodlight.org/projects/
@@ -224,30 +224,19 @@
${env.BUILD_ID}
${env.BUILD_TAG}
${env.JOB_NAME}
-i ${env.NODE_NAME}
+ ${env.NODE_NAME}
-
-
diff --git a/java_gen/pre-written/src/main/java/org/projectfloodlight/openflow/protocol/match/MatchField.java b/java_gen/pre-written/src/main/java/org/projectfloodlight/openflow/protocol/match/MatchField.java
index 11a570584..aad24b6e1 100644
--- a/java_gen/pre-written/src/main/java/org/projectfloodlight/openflow/protocol/match/MatchField.java
+++ b/java_gen/pre-written/src/main/java/org/projectfloodlight/openflow/protocol/match/MatchField.java
@@ -28,6 +28,7 @@
import org.projectfloodlight.openflow.types.UDF;
import org.projectfloodlight.openflow.types.VRF;
import org.projectfloodlight.openflow.types.VlanPcp;
+import org.projectfloodlight.openflow.types.CircuitSignalID;
public class MatchField> {
private final String name;
@@ -259,6 +260,22 @@ private MatchField(final String name, final MatchFields id, Prerequisite>... p
public final static MatchField BSN_VLAN_XLATE_PORT_GROUP_ID =
new MatchField("bsn_vlan_xlate_port_group_id", MatchFields.BSN_VLAN_XLATE_PORT_GROUP_ID);
+ public final static MatchField OCH_SIGTYPE =
+ new MatchField("och_sigtype",
+ MatchFields.OCH_SIGTYPE);
+
+ public final static MatchField OCH_SIGTYPE_BASIC =
+ new MatchField("och_sigtype_basic",
+ MatchFields.OCH_SIGTYPE_BASIC);
+
+ public final static MatchField OCH_SIGID =
+ new MatchField("och_sigid",
+ MatchFields.OCH_SIGID);
+
+ public final static MatchField OCH_SIGID_BASIC =
+ new MatchField("och_sigid_basic",
+ MatchFields.OCH_SIGID);
+
public final static MatchField BSN_L2_CACHE_HIT =
new MatchField("bsn_l2_cache_hit", MatchFields.BSN_L2_CACHE_HIT);
diff --git a/java_gen/pre-written/src/main/java/org/projectfloodlight/openflow/protocol/match/MatchFields.java b/java_gen/pre-written/src/main/java/org/projectfloodlight/openflow/protocol/match/MatchFields.java
index 73aa24f3e..13aeb63f7 100644
--- a/java_gen/pre-written/src/main/java/org/projectfloodlight/openflow/protocol/match/MatchFields.java
+++ b/java_gen/pre-written/src/main/java/org/projectfloodlight/openflow/protocol/match/MatchFields.java
@@ -69,4 +69,8 @@ public enum MatchFields {
BSN_INNER_ETH_DST,
BSN_INNER_ETH_SRC,
BSN_INNER_VLAN_VID,
+ OCH_SIGTYPE,
+ OCH_SIGTYPE_BASIC,
+ OCH_SIGID,
+ OCH_SIGID_BASIC,
}
diff --git a/java_gen/pre-written/src/main/java/org/projectfloodlight/openflow/types/CircuitSignalID.java b/java_gen/pre-written/src/main/java/org/projectfloodlight/openflow/types/CircuitSignalID.java
new file mode 100644
index 000000000..7a304f679
--- /dev/null
+++ b/java_gen/pre-written/src/main/java/org/projectfloodlight/openflow/types/CircuitSignalID.java
@@ -0,0 +1,137 @@
+package org.projectfloodlight.openflow.types;
+
+import com.google.common.collect.ComparisonChain;
+import org.jboss.netty.buffer.ChannelBuffer;
+import org.projectfloodlight.openflow.exceptions.OFParseError;
+
+import com.google.common.hash.PrimitiveSink;
+
+
+public class CircuitSignalID implements OFValueType {
+ static final int length = 6;
+
+ private byte gridType;
+ private byte channelSpacing ;
+ private short channelNumber;
+ private short spectralWidth;
+
+ public static final CircuitSignalID NONE = new CircuitSignalID((byte)0,
+ (byte)0,
+ (short)0,
+ (short)0);
+
+
+ public CircuitSignalID(byte gridType, byte channelSpacing,
+ short channelNumber,
+ short spectralWidth)
+ {
+ this.gridType = gridType;
+ this.channelSpacing = channelSpacing;
+ this.channelNumber = channelNumber;
+ this.spectralWidth = spectralWidth;
+
+ }
+
+ @Override
+ public int getLength() {
+ return length;
+ }
+
+ public byte getGridType() {
+ return gridType;
+ }
+
+ public byte getChannelSpacing() {
+ return channelSpacing;
+ }
+
+ public short getChannelNumber() {
+ return channelNumber;
+ }
+
+ public short getSpectralWidth() {
+ return spectralWidth;
+ }
+
+ public void write6Bytes(ChannelBuffer c) {
+ c.writeByte(gridType);
+ c.writeByte(channelSpacing);
+ c.writeShort(channelNumber);
+ c.writeShort(spectralWidth);
+ }
+
+ public static CircuitSignalID read6Bytes(ChannelBuffer c) throws OFParseError {
+ return new CircuitSignalID((byte)c.readUnsignedByte(),
+ (byte)c.readUnsignedByte(),
+ (short)c.readUnsignedShort(),
+ (short)c.readUnsignedShort());
+ }
+
+ @Override
+ public boolean equals(Object o) {
+ if (this == o) return true;
+ if (o == null || getClass() != o.getClass()) return false;
+
+ CircuitSignalID that = (CircuitSignalID) o;
+
+ if (channelNumber != that.channelNumber) return false;
+ if (channelSpacing != that.channelSpacing) return false;
+ if (gridType != that.gridType) return false;
+ if (spectralWidth != that.spectralWidth) return false;
+
+ return true;
+ }
+
+ @Override
+ public int hashCode() {
+ int result = (int) gridType;
+ result = 31 * result + (int) channelSpacing;
+ result = 31 * result + (int) channelNumber;
+ result = 31 * result + (int) spectralWidth;
+ return result;
+ }
+
+ @Override
+ public String toString() {
+ return "CircuitSignalID{" +
+ "gridType=" + gridType +
+ ", channelSpacing=" + channelSpacing +
+ ", channelNumber=" + channelNumber +
+ ", spectralWidth=" + spectralWidth +
+ '}';
+ }
+
+ @Override
+ public CircuitSignalID applyMask(CircuitSignalID mask) {
+ return new CircuitSignalID((byte) (this.gridType & mask.gridType),
+ (byte) (this.channelSpacing & mask
+ .channelSpacing),
+ (short) (this.channelNumber & mask
+ .channelNumber),
+ (short) (this.spectralWidth & mask
+ .spectralWidth));
+ }
+
+
+ @Override
+ public int compareTo(CircuitSignalID o) {
+ return ComparisonChain.start()
+ .compare(gridType,o.gridType)
+ .compare(channelSpacing,o.channelSpacing)
+ .compare(channelNumber,o.channelNumber)
+ .compare(spectralWidth,o.spectralWidth)
+ .result();
+ }
+
+
+ @Override
+ public void putTo(PrimitiveSink sink) {
+ sink.putByte(gridType);
+ sink.putByte(channelSpacing);
+ sink.putShort(channelNumber);
+ sink.putShort(spectralWidth);
+ }
+
+
+
+}
diff --git a/java_gen/pre-written/src/test/java/org/projectfloodlight/protocol/OFOxmTest.java b/java_gen/pre-written/src/test/java/org/projectfloodlight/protocol/OFOxmTest.java
index 8482886b9..04034cca2 100644
--- a/java_gen/pre-written/src/test/java/org/projectfloodlight/protocol/OFOxmTest.java
+++ b/java_gen/pre-written/src/test/java/org/projectfloodlight/protocol/OFOxmTest.java
@@ -59,4 +59,6 @@ public void testGetCanonicalNormalMask() {
OFOxm canonical = ipv4SrcMasked.getCanonical();
assertEquals(ipv4SrcMasked, canonical);
}
+
+
}
diff --git a/java_gen/pre-written/src/test/java/org/projectfloodlight/protocol/match/MatchFieldIteration13Test.java b/java_gen/pre-written/src/test/java/org/projectfloodlight/protocol/match/MatchFieldIteration13Test.java
index b654a5386..1bd3efee1 100644
--- a/java_gen/pre-written/src/test/java/org/projectfloodlight/protocol/match/MatchFieldIteration13Test.java
+++ b/java_gen/pre-written/src/test/java/org/projectfloodlight/protocol/match/MatchFieldIteration13Test.java
@@ -1,10 +1,22 @@
package org.projectfloodlight.protocol.match;
+import org.junit.Test;
import org.projectfloodlight.openflow.protocol.OFFactories;
import org.projectfloodlight.openflow.protocol.OFVersion;
+import org.projectfloodlight.openflow.protocol.match.Match;
+import org.projectfloodlight.openflow.protocol.match.MatchField;
+import org.projectfloodlight.openflow.types.U8;
public class MatchFieldIteration13Test extends MatchFieldIterationBase {
public MatchFieldIteration13Test() {
super(OFFactories.getFactory(OFVersion.OF_13));
}
+
+ @Test
+ public void matchCircuitFields()
+ {
+ Match.Builder builder = factory.buildMatchV3().setExact(MatchField
+ .OCH_SIGTYPE, U8.ZERO);
+
+ }
}
diff --git a/java_gen/pre-written/src/test/java/org/projectfloodlight/protocol/match/MatchFieldIterationBase.java b/java_gen/pre-written/src/test/java/org/projectfloodlight/protocol/match/MatchFieldIterationBase.java
index 9c72e37fb..892c5a07e 100644
--- a/java_gen/pre-written/src/test/java/org/projectfloodlight/protocol/match/MatchFieldIterationBase.java
+++ b/java_gen/pre-written/src/test/java/org/projectfloodlight/protocol/match/MatchFieldIterationBase.java
@@ -25,7 +25,7 @@
public class MatchFieldIterationBase {
- private OFFactory factory;
+ protected OFFactory factory;
protected MatchFieldIterationBase(OFFactory factory) {
this.factory = factory;
diff --git a/java_gen/templates/custom/OFPortDesc.java b/java_gen/templates/custom/OFPortDesc.java
index ccfbedb13..a2f05cf85 100644
--- a/java_gen/templates/custom/OFPortDesc.java
+++ b/java_gen/templates/custom/OFPortDesc.java
@@ -13,7 +13,7 @@ public boolean isEnabled() {
* Returns the current generation ID of this port.
*
* The generationId is reported by the switch as a @{link OFPortDescProp} in
- * @link{OFPortDescStatsReply} and @link{OFPortStatus} messages. If the
+ * {@link OFPortDescStatsReply} and {@link OFPortStatus} messages. If the
* current OFPortDesc does not contain a generation Id, returns U64.ZERO;
*
* For OpenFlow versions earlier than 1.4, always returns U64.ZERO;
diff --git a/java_gen/templates/custom/interface/OFPortDesc.java b/java_gen/templates/custom/interface/OFPortDesc.java
index 247464de1..45e2dfb86 100644
--- a/java_gen/templates/custom/interface/OFPortDesc.java
+++ b/java_gen/templates/custom/interface/OFPortDesc.java
@@ -12,7 +12,7 @@
* Returns the current generation ID of this port.
*
* The generationId is reported by the switch as a @{link OFPortDescProp} in
- * @link{OFPortDescStatsReply} and @link{OFPortStatus} messages. If the
+ * {@link OFPortDescStatsReply} and {@link OFPortStatus} messages. If the
* current OFPortDesc does not contain a generation Id, returns U64.ZERO;
*
* For OpenFlow versions earlier than 1.4, always returns U64.ZERO;
diff --git a/loxi_ir/ir_offset.py b/loxi_ir/ir_offset.py
index 5eff8e084..64c01b6dd 100644
--- a/loxi_ir/ir_offset.py
+++ b/loxi_ir/ir_offset.py
@@ -25,7 +25,8 @@
OF_MAX_PORT_NAME_LEN = 16,
OF_ETH_ALEN = 6,
OF_DESC_STR_LEN = 256,
- OF_SERIAL_NUM_LEN = 32
+ OF_SERIAL_NUM_LEN = 32,
+ OF_APP_CODE_LEN = 15
)
@@ -103,12 +104,16 @@
of_desc_str_t = (ofp_constants["OF_DESC_STR_LEN"], True),
of_serial_num_t = (ofp_constants["OF_SERIAL_NUM_LEN"], True),
of_str64_t = (64, True),
+ of_str32_t = (32, True),
+ of_str6_t = (6, True),
of_match_v1_t = (40, True),
of_match_v2_t = (88, True),
of_match_v3_t = (8, False),
of_octets_t = (0, False),
of_bitmap_128_t = (16, True),
of_checksum_128_t = (16, True),
+ of_app_code_t = (15,True),
+ of_sig_id_t = (6, True),
of_bitmap_512_t = (64, True),
)
diff --git a/openflow_input/calient b/openflow_input/calient
new file mode 100644
index 000000000..8a54b2caf
--- /dev/null
+++ b/openflow_input/calient
@@ -0,0 +1,65 @@
+// Copyright 2013, Big Switch Networks, Inc.
+// Copyright 2015, Open Networking Laboratory
+//
+// 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 4
+
+struct of_calient_stats_request : of_experimenter_stats_request {
+ uint8_t version;
+ uint8_t type == 18;
+ uint16_t length;
+ uint32_t xid;
+ uint16_t stats_type == 0xffff;
+ enum ofp_stats_request_flags flags;
+ pad(4);
+ uint32_t experimenter == 0x0080F958;
+ uint32_t subtype == ?;
+};
+
+struct of_calient_stats_reply : of_experimenter_stats_reply {
+ uint8_t version;
+ uint8_t type == 19;
+ uint16_t length;
+ uint32_t xid;
+ uint16_t stats_type == 0xffff;
+ enum ofp_stats_reply_flags flags;
+ pad(4);
+ uint32_t experimenter == 0x0080F958;
+ uint32_t subtype == ?;
+};
+
+enum ofp_calient_ocs_alarm(wire_type=uint8_t, bitmask=True){
+ OFPOCSALM_CLEAR = 1, /* Clear- no alarm */
+ OFPOCSALM_MINOR = 2, /* loss is greater than 5.25 */
+ OFPOCSALM_MAJOR = 3, /* loss is greater than 7.25 */
+ OFPOCSALM_CRITICAL = 4, /* loss is greater than 10.25 */
+};
+
diff --git a/openflow_input/calient_flow_stats b/openflow_input/calient_flow_stats
new file mode 100644
index 000000000..7c732dfc9
--- /dev/null
+++ b/openflow_input/calient_flow_stats
@@ -0,0 +1,116 @@
+// Copyright 2013, Big Switch Networks, Inc.
+// Copyright 2015, Open Networking Laboratory
+//
+// 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 4
+
+struct of_calient_flow_stats_request : of_calient_stats_request {
+ uint8_t version;
+ uint8_t type == 18;
+ uint16_t length;
+ uint32_t xid;
+ uint16_t stats_type == 0xffff;
+ enum ofp_stats_request_flags flags;
+ pad(4);
+ uint32_t experimenter == 0x0080F958;
+ uint32_t subtype == 2; /* OFPEMPFS = 2 */
+ uint8_t table_id; /* Recommended to be set to 0. Ignored */
+ pad(3);
+ uint32_t out_port; /* Require matching entries to include this as an output port.
+ A value of OFPP_ANY indicates no restriction. Ignored */
+ uint32_t out_group; /* Require matching entries to include this as an output group.
+ A value of OFPP_ANY indicates no restriction. Ignored */
+ pad(4); /* Align to 64 bits */
+ uint64_t cookie; /* Ignored */
+ uint64_t cookie_mask; /* Ignored */
+ of_match_t match; /* Fields to match. Variable size */
+};
+
+enum ofp_calient_cflow_admin_state(wire_type=uint8_t, bitmask=True){
+ OFPCAS_InService = 1, /* when the connection is activated */
+ OFPCAS_UnderManagement = 2,/*Default Connection state – (when connection is not activated)*/
+};
+
+
+enum ofp_calient_cflow_operational_state(wire_type=uint8_t, bitmask=True){
+ OFPCOS_InService = 1, /* When connection is activated */
+ OFPCOS_OutOfService = 2,/*When connection has a critical alarm ( activated or otherwise) */
+ OFPCOS_Ready = 3, /*When AS state is UnderManagement */
+ OFPCOS_Degraded = 4, /*When connection is activated and has a Major alarm */
+};
+
+enum ofp_calient_cflow_Capability(wire_type=uint8_t, bitmask=True){
+ OFPCCS_Ok = 1, /* Connection has been made successfully */
+ OFPCCS_Failed = 2, /* Connection has Failed */
+ OFPCCS_Initializing = 3,/* Connection making is in progress */
+};
+
+struct of_calient_flow_stats_entry {
+ uint16_t length;
+ uint8_t table_id; /* Ignored */
+ pad(1);
+ uint32_t duration_sec; /* Not supported for now */
+ uint32_t duration_nsec; /* Not supported for now */
+ uint16_t priority; /* Not supported */
+ uint16_t idle_timeout; /* Set to 0 as entries must be explicitly removed */
+ uint16_t hard_timeout; /* Set to 0 as entries must be explicitly removed */
+ enum ofp_flow_mod_flags flags;
+ pad(4);
+ uint64_t cookie; /* Ignored */
+ enum ofp_calient_cflow_admin_state admin_status; /* AS = IS(Activated)/UMA */
+ enum ofp_calient_cflow_operational_state oper_status; /* OS = UMA/OOS */
+ enum ofp_calient_cflow_Capability oper_capability; /* OC = FAIL/OK/INIT */
+ enum ofp_calient_ocs_alarm alarm; /* Alarm = NA/MJ/MN/CR */
+ of_str6_t port_power;
+ pad(2);
+ of_str6_t connected_port_power;
+ pad(2);
+ of_str64_t cflow_name; /* Connection name */
+ of_match_t match;
+};
+
+
+struct of_calient_flow_stats_reply : of_calient_stats_reply {
+ uint8_t version;
+ uint8_t type == 19;
+ uint16_t length;
+ uint32_t xid;
+ uint16_t stats_type == 0xffff;
+ enum ofp_stats_reply_flags flags;
+ pad(4);
+ uint32_t experimenter == 0x0080F958;
+ uint32_t subtype == 2;
+ uint16_t data_length;
+ pad(6);
+ list(of_calient_flow_stats_entry_t)flow_stats;
+};
+
+
diff --git a/openflow_input/calient_port_desc_stats b/openflow_input/calient_port_desc_stats
new file mode 100644
index 000000000..70dcd3d75
--- /dev/null
+++ b/openflow_input/calient_port_desc_stats
@@ -0,0 +1,124 @@
+// Copyright 2013, Big Switch Networks, Inc.
+// Copyright 2015, Open Networking Laboratory
+//
+// 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 4
+
+struct of_calient_port_desc_stats_request : of_calient_stats_request {
+ uint8_t version;
+ uint8_t type == 18;
+ uint16_t length;
+ uint32_t xid;
+ uint16_t stats_type == 0xffff;
+ enum ofp_stats_request_flags flags;
+ pad(4);
+ uint32_t experimenter == 0x0080F958;
+ uint32_t subtype == 1;
+};
+
+
+struct of_calient_port_desc_prop {
+ uint16_t type == ?; /* One of OFPPDPT_*. */
+ uint16_t length; /* Length in bytes of this property. */
+};
+
+
+enum ofp_calient_optical_port_admin_state(wire_type=uint8_t, bitmask=True){
+ OFPAS_IN_SERVICE = 1, /*Circuit Port in Service*/
+ OFPAS_OUT_OF_SERVICE = 2, /*Circuit Port out of Service*/
+ OFPAS_OOS_NP = 3 /*Circuit Port out of Service, not provisioned*/
+};
+
+enum ofp_calient_optical_port_oper_state(wire_type=uint8_t, bitmask=True){
+ OFPOS_IN_SERVICE = 8, /*Circuit Port in Service*/
+ OFPOS_OUT_OF_SERVICE = 16 /*Circuit Port out of Service*/
+};
+
+enum ofp_calient_optical_port_oper_capability(wire_type=uint8_t, bitmask=True){
+ OFPCS_NoHardware = 1, /* when port is not in connection */
+ OFPCS_Ok = 2, /* port is in Connection which is made successfully */
+ OFPCS_Failed = 3, /* when port is in Connection which is Failed */
+ OFPCS_Initializing = 4,/* when port is in Connection which is being made */
+};
+
+
+
+
+
+struct of_calient_port_desc_prop_optical : of_calient_port_desc_prop{
+ uint16_t type == 2; /* OFPPDPT_OPTICAL_CIRCUIT */
+ uint16_t length; /* Length in bytes of this property. */
+ enum ofp_calient_optical_port_admin_state in_admin_status;
+ enum ofp_calient_optical_port_oper_state in_oper_status;
+ enum ofp_calient_optical_port_oper_capability in_oper_capability;
+ enum ofp_calient_optical_port_admin_state out_admin_status;
+ enum ofp_calient_optical_port_oper_state out_oper_status;
+ enum ofp_calient_optical_port_oper_capability out_oper_capability;
+ of_str6_t inport_power; /* Input Port Power */
+ of_str6_t outport_power; /* Output Port Power */
+ pad(2);
+ uint64_t in_peer_node; /* Peer node datapath id connected to the input optical port */
+ uint64_t out_peer_node; /* Peer node datapath id connected to the output optical port */
+ uint16_t in_peer_port; /* Peer port number connected to the input optical port */
+ uint16_t out_peer_port; /* Peer port number connected to the output optical port */
+ pad(4);
+ of_str32_t in_circuit_id; /* Circuit Id associated with the input port */
+ of_str32_t out_circuit_id; /* Circuit id associated with the output port */
+ of_str64_t in_alias; /* Alias(name) for the input port */
+ of_str64_t out_alias; /* Alias(name) for the output port */
+};
+
+struct of_calient_port_desc_stats_entry {
+ uint16_t length;
+ pad(2);
+ of_port_no_t port_no;
+ of_mac_addr_t hw_addr;
+ pad(2);
+ of_port_name_t name; /* Not used.NULL */
+ uint32_t config; /* Not used. Always 0. */
+ uint32_t state; /* Not used. Always 0. */
+ list(of_calient_port_desc_prop_t) properties;
+};
+
+struct of_calient_port_desc_stats_reply : of_calient_stats_reply {
+ uint8_t version;
+ uint8_t type == 19;
+ uint16_t length;
+ uint32_t xid;
+ uint16_t stats_type == 0xffff;
+ enum ofp_stats_reply_flags flags;
+ pad(4);
+ uint32_t experimenter == 0x0080F958;
+ uint32_t subtype == 1;
+ list(of_calient_port_desc_stats_entry_t)port_desc;
+};
+
+
diff --git a/openflow_input/calient_port_stats b/openflow_input/calient_port_stats
new file mode 100644
index 000000000..9e6cf4bc0
--- /dev/null
+++ b/openflow_input/calient_port_stats
@@ -0,0 +1,86 @@
+// Copyright 2013, Big Switch Networks, Inc.
+// Copyright 2015, Open Networking Laboratory
+//
+// 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 4
+
+struct of_calient_port_stats_request : of_calient_stats_request {
+ uint8_t version;
+ uint8_t type == 18;
+ uint16_t length;
+ uint32_t xid;
+ uint16_t stats_type == 0xffff;
+ enum ofp_stats_request_flags flags;
+ pad(4);
+ uint32_t experimenter == 0x0080F958;
+ uint32_t subtype == 3;
+ of_port_no_t port_no;
+ pad(4);
+};
+
+
+struct of_calient_port_stats_entry {
+ uint16_t length;
+ pad(2);
+ of_port_no_t port_no;
+ enum ofp_calient_optical_port_admin_state in_admin_status; /* Input port admin status */
+ enum ofp_calient_optical_port_oper_state in_oper_status; /* Input port operational status */
+ enum ofp_calient_optical_port_oper_capability in_oper_capability; /* Input port operational capability */
+ enum ofp_calient_ocs_alarm in_alarm;/* Alarm on Input port */
+ of_str6_t inport_power; /* Input port power */
+ pad(2);
+ of_str6_t outport_power; /* Output port power */
+ pad(2);
+ enum ofp_calient_optical_port_admin_state out_admin_status; /* Output port Admin status */
+ enum ofp_calient_optical_port_oper_state out_oper_status; /* Output port operational status */
+ enum ofp_calient_optical_port_oper_capability out_oper_capability;/* Output port operational capability */
+ enum ofp_calient_ocs_alarm out_alarm;/* Alarm on Output port */
+ pad(4);
+ of_str32_t in_circuit_id; /* Circuit id associated with the input port */
+ of_str32_t out_circuit_id; /* Circuit id associated with the output port */
+};
+
+struct of_calient_port_stats_reply : of_calient_stats_reply {
+ uint8_t version;
+ uint8_t type == 19;
+ uint16_t length;
+ uint32_t xid;
+ uint16_t stats_type == 0xffff;
+ enum ofp_stats_reply_flags flags;
+ pad(4);
+ uint32_t experimenter == 0x0080F958;
+ uint32_t subtype == 3;
+ uint16_t data_length;
+ pad(6);
+ list(of_calient_port_stats_entry_t) entries;
+};
+
+
diff --git a/openflow_input/linc b/openflow_input/linc
new file mode 100644
index 000000000..45e0e1df7
--- /dev/null
+++ b/openflow_input/linc
@@ -0,0 +1,67 @@
+// Copyright 2013, Big Switch Networks, Inc.
+// Copyright 2015, Open Networking Laboratory
+//
+// 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 4
+
+// LINC-OE Optical Emulator Switch extensions
+struct of_action_linc : of_action_experimenter {
+ uint16_t type == 65535;
+ uint16_t len;
+ uint32_t experimenter == 0x748771;
+ uint16_t subtype == ?;
+ pad(2);
+ pad(4);
+};
+
+struct of_linc_ports_request : of_experimenter_stats_request {
+ uint8_t version;
+ uint8_t type == 18;
+ uint16_t length;
+ uint32_t xid;
+ uint16_t stats_type == 0xffff;
+ enum ofp_stats_request_flags flags;
+ pad(4);
+ uint32_t experimenter == 0x748771;
+ uint32_t subtype == ?;
+};
+
+struct of_linc_ports_reply : of_experimenter_stats_reply {
+ uint8_t version;
+ uint8_t type == 19;
+ uint16_t length;
+ uint32_t xid;
+ uint16_t stats_type == 0xffff;
+ enum ofp_stats_reply_flags flags;
+ pad(4);
+ uint32_t experimenter == 0x748771;
+ uint32_t subtype == ?;
+};
diff --git a/openflow_input/linc_circuit b/openflow_input/linc_circuit
new file mode 100644
index 000000000..61d030004
--- /dev/null
+++ b/openflow_input/linc_circuit
@@ -0,0 +1,201 @@
+// Copyright 2013, Big Switch Networks, Inc.
+// Copyright 2015, Open Networking Laboratory
+//
+// 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 4
+
+/* WDM grid types */
+enum ofp_grid_type {
+ OFPGRIDT_RES = 0,
+ OFPGRIDT_DWDM = 1,
+ OFPGRIDT_CWDM = 2,
+ OFPGRIDT_FLEX = 3,
+};
+
+/* WDM grid channel spacing */
+enum ofp_channel_spacing {
+ OFPCS_RES = 0,
+ OFPCS_GHZ_100 = 1,
+ OFPCS_GHZ_50 = 2,
+ OFPCS_GHZ_24 = 3,
+ OFPCS_GHZ_12P5 = 4, /* 12.5 GHZ */
+ OFPCS_GHZ_6P25 = 5, /* 6.25 GHZ */
+};
+
+/* Layer classes (families) supported for optical transport port. */
+enum ofp_port_optical_transport_layer_class {
+ OFPPOTL_PORT = 1, /* Class of base port layer signal types */
+ OFPPOTL_OCH = 2, /* Class of OCH layer signal types*/
+ OFPPOTL_ODU = 3, /* Class of ODU layer signal types*/
+ OFPPOTL_ODUCLT = 4, /* Class of ODU client layer signal types*/
+};
+
+/* Base port layer signal types */
+enum ofp_otport_signal_type {
+ OFPOTPT_OTSn = 1,
+ OFPOTPT_OMSn = 2,
+ OFPOTPT_OPSn = 3,
+ OFPOTPT_OPSM = 4,
+ OFPOTPT_OCH = 5,
+ OFPOTPT_OTU1 = 11,
+ OFPOTPT_OTU2 = 12,
+ OFPOTPT_OTU3 = 13,
+ OFPOTPT_OTU4 = 14,
+};
+
+/* OCH layer signal types */
+enum ofp_och_signal_type {
+ OFPOCHT_FIX_GRID = 1,
+ OFPOCHT_FLEX_GRID = 2,
+};
+
+// Not used .. just for info on structure.
+struct ofp_och_signal_id {
+ uint8_t grid; //Type of WDM grid - OFPGRIDT_*
+ uint8_t cs; //Channel Spacing - OFPCS_*
+ uint16_t n; // Used to calculate frequency as in [ITU G.694.1]
+ // Frequency(THz)= 193.1 THz + n * chan_spacing
+ uint16_t m; // Used to calculate spectral width [ITU G.694.1]
+ // Spectral Width (GHz) = m * 12.5
+ // For fix grid networks, m=1
+};
+
+struct of_oxm_och_sigtype : of_oxm {
+ uint32_t type_len == 0x00085801;
+ uint8_t value;
+};
+
+struct of_oxm_och_sigid : of_oxm {
+ uint32_t type_len == 0x00085A06;
+ of_sig_id_t value;
+};
+
+struct of_action_linc_circuit : of_action_linc {
+ uint16_t type == 65535;
+ uint16_t len;
+ uint32_t experimenter == 0x748771;
+ uint16_t subtype == 25;
+ uint16_t hlength == 16; // fix length of OXM field
+ of_oxm_t field;
+ pad(2);
+};
+
+
+struct of_linc_circuit_ports_request : of_linc_ports_request {
+ uint8_t version;
+ uint8_t type == 18;
+ uint16_t length;
+ uint32_t xid;
+ uint16_t stats_type == 0xffff;
+ enum ofp_stats_request_flags flags;
+ pad(4);
+ uint32_t experimenter == 0x748771;
+ uint32_t subtype == 13;
+};
+
+
+struct of_linc_circuit_ports_reply : of_linc_ports_reply {
+ uint8_t version;
+ uint8_t type == 19;
+ uint16_t length;
+ uint32_t xid;
+ uint16_t stats_type == 0xffff;
+ enum ofp_stats_reply_flags flags;
+ pad(4);
+ uint32_t experimenter == 0x748771;
+ uint32_t subtype == 13;
+ list(of_port_optical_t) entries;
+};
+
+struct of_port_optical {
+ of_port_no_t port_no;
+ uint16_t length;
+ pad(2);
+ of_mac_addr_t hw_addr;
+ pad(2);
+ of_port_name_t name;
+ enum ofp_port_config config;
+ enum ofp_port_state state;
+ list(of_port_desc_prop_optical_transport_t) desc;
+};
+
+struct of_port_desc_prop_optical_transport {
+ uint16_t type;
+ uint16_t length;
+ uint8_t port_signal_type;
+ uint8_t reserved;
+ pad(1);
+ uint8_t port_type;
+};
+
+struct of_circuit_port_status : of_experimenter {
+ uint8_t version;
+ uint8_t type == 4;
+ uint16_t length;
+ uint32_t xid;
+ uint32_t experimenter == 0x748771;
+ uint32_t exp_type == 12;
+ enum ofp_port_reason reason;
+ pad(7);
+ of_port_no_t port_no;
+ uint16_t lengths;
+ pad(2);
+ of_mac_addr_t hw_addr;
+ pad(2);
+ of_port_name_t name;
+ enum ofp_port_config config;
+ enum ofp_port_state state;
+ uint64_t ignore;
+};
+
+struct of_port_optical_transport_application_code {
+ uint16_t feature_type;
+ uint8_t oic_type;
+ of_app_code_t app_code;
+};
+
+
+struct of_port_optical_transport_layer_entry {
+ uint8_t layer_class;
+ uint8_t signal_type;
+ uint8_t adaptation;
+ pad(5);
+};
+
+
+/* ODU Layer Stack Feature Encoding */
+struct of_port_optical_transport_layer_stack {
+ uint16_t feature_type;
+ uint16_t length;
+ pad(4);
+ list(of_port_optical_transport_layer_entry_t) entries;
+};
+
diff --git a/py_gen/oftype.py b/py_gen/oftype.py
index 76eebd0f0..6c130158d 100644
--- a/py_gen/oftype.py
+++ b/py_gen/oftype.py
@@ -132,6 +132,8 @@
'of_serial_num_t': 32,
'of_desc_str_t': 256,
'of_str64_t': 64,
+ 'of_str32_t': 32,
+ 'of_str6_t': 6,
}
for (cls, length) in fixed_length_strings.items():
diff --git a/wireshark_gen/field_info.py b/wireshark_gen/field_info.py
index bc111703a..3158697e1 100644
--- a/wireshark_gen/field_info.py
+++ b/wireshark_gen/field_info.py
@@ -40,6 +40,8 @@
"of_desc_str_t": "stringz",
"of_serial_num_t": "stringz",
"of_str64_t": "stringz",
+ "of_str32_t": "stringz",
+ "of_str6_t": "stringz",
"of_octets_t": "bytes",
"of_port_no_t": "uint32",
"of_port_desc_t": "stringz",
@@ -69,6 +71,8 @@
"of_desc_str_t": "NONE",
"of_serial_num_t": "NONE",
"of_str64_t": "NONE",
+ "of_str32_t": "NONE",
+ "of_str6_t": "NONE",
"of_octets_t": "NONE",
"of_port_no_t": "DEC",
"of_port_desc_t": "NONE",
diff --git a/wireshark_gen/templates/_oftype_readers.lua b/wireshark_gen/templates/_oftype_readers.lua
index 9695c59d9..700b236e7 100644
--- a/wireshark_gen/templates/_oftype_readers.lua
+++ b/wireshark_gen/templates/_oftype_readers.lua
@@ -139,6 +139,14 @@ function read_of_str64_t(reader, version, subtree, field_name)
read_scalar(reader, subtree, field_name, 64)
end
+function read_of_str32_t(reader, version, subtree, field_name)
+ read_scalar(reader, subtree, field_name, 32)
+end
+
+function read_of_str6_t(reader, version, subtree, field_name)
+ read_scalar(reader, subtree, field_name, 6)
+end
+
function read_of_port_desc_t(reader, version, subtree, field_name)
if reader.is_empty() then
return