Merge branch 'master' of github.com:floodlight/loxigen
diff --git a/java_gen/pre-written/src/main/java/org/projectfloodlight/openflow/types/OFVlanVidMatch.java b/java_gen/pre-written/src/main/java/org/projectfloodlight/openflow/types/OFVlanVidMatch.java
index 29d6e02..fddaa5d 100644
--- a/java_gen/pre-written/src/main/java/org/projectfloodlight/openflow/types/OFVlanVidMatch.java
+++ b/java_gen/pre-written/src/main/java/org/projectfloodlight/openflow/types/OFVlanVidMatch.java
@@ -4,6 +4,8 @@
import org.jboss.netty.buffer.ChannelBuffer;
import org.projectfloodlight.openflow.exceptions.OFParseError;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
import com.google.common.hash.PrimitiveSink;
import com.google.common.primitives.Shorts;
@@ -21,6 +23,7 @@
*
*/
public class OFVlanVidMatch implements OFValueType<OFVlanVidMatch> {
+ private static final Logger logger = LoggerFactory.getLogger(OFVlanVidMatch.class);
private static final short VALIDATION_MASK = 0x1FFF;
private static final short PRESENT_VAL = 0x1000;
@@ -59,7 +62,11 @@
return UNTAGGED;
else if(vid == PRESENT_VAL)
return PRESENT;
- else if ((vid & VALIDATION_MASK) != vid)
+ else if(vid == UNTAGGED_VAL_OF10) {
+ // workaround for IVS sometimes sending 0F1.0 untagged (0xFFFF) values
+ logger.warn("Warning: received OF1.0 untagged vlan value (0xFFFF) in OF1.3 VlanVid. Treating as UNTAGGED");
+ return UNTAGGED;
+ } else if ((vid & VALIDATION_MASK) != vid)
throw new IllegalArgumentException(String.format("Illegal VLAN value: %x", vid));
return new OFVlanVidMatch(vid);
}
diff --git a/openflow_input/standard-1.1 b/openflow_input/standard-1.1
index 906519c..7dedae7 100644
--- a/openflow_input/standard-1.1
+++ b/openflow_input/standard-1.1
@@ -1241,7 +1241,7 @@
struct of_group_desc_stats_entry {
uint16_t length;
- uint8_t group_type;
+ enum ofp_group_type group_type;
pad(1);
uint32_t group_id;
list(of_bucket_t) buckets;
diff --git a/openflow_input/standard-1.2 b/openflow_input/standard-1.2
index 90447f5..8f21594 100644
--- a/openflow_input/standard-1.2
+++ b/openflow_input/standard-1.2
@@ -1208,7 +1208,7 @@
struct of_group_desc_stats_entry {
uint16_t length;
- uint8_t group_type;
+ enum ofp_group_type group_type;
pad(1);
uint32_t group_id;
list(of_bucket_t) buckets;
diff --git a/openflow_input/standard-1.3 b/openflow_input/standard-1.3
index 4d0ca7e..1518931 100644
--- a/openflow_input/standard-1.3
+++ b/openflow_input/standard-1.3
@@ -1427,7 +1427,7 @@
struct of_group_desc_stats_entry {
uint16_t length;
- uint8_t group_type;
+ enum ofp_group_type group_type;
pad(1);
uint32_t group_id;
list(of_bucket_t) buckets;