update pyloxi to floodlight/loxigen-artifacts@57f3c38ed3f04678bc250d086e150582269280d5
diff --git a/src/python/loxi/of13/const.py b/src/python/loxi/of13/const.py
index b513de8..cae3396 100644
--- a/src/python/loxi/of13/const.py
+++ b/src/python/loxi/of13/const.py
@@ -694,6 +694,7 @@
OFPR_BSN_ARP = 139
OFPR_BSN_DHCP = 140
OFPR_BSN_DEBUG = 141
+OFPR_BSN_PACKET_OF_DEATH = 142
ofp_packet_in_reason_map = {
0: 'OFPR_NO_MATCH',
@@ -712,6 +713,7 @@
139: 'OFPR_BSN_ARP',
140: 'OFPR_BSN_DHCP',
141: 'OFPR_BSN_DEBUG',
+ 142: 'OFPR_BSN_PACKET_OF_DEATH',
}
# Identifiers from group ofp_port
diff --git a/src/python/loxi/of13/instruction.py b/src/python/loxi/of13/instruction.py
index e9c03dd..bc06252 100644
--- a/src/python/loxi/of13/instruction.py
+++ b/src/python/loxi/of13/instruction.py
@@ -475,6 +475,54 @@
bsn.subtypes[0] = bsn_disable_src_mac_check
+class bsn_packet_of_death(bsn):
+ type = 65535
+ experimenter = 6035143
+ subtype = 6
+
+ def __init__(self):
+ return
+
+ def pack(self):
+ packed = []
+ packed.append(struct.pack("!H", self.type))
+ packed.append(struct.pack("!H", 0)) # placeholder for len at index 1
+ packed.append(struct.pack("!L", self.experimenter))
+ packed.append(struct.pack("!L", self.subtype))
+ packed.append('\x00' * 4)
+ length = sum([len(x) for x in packed])
+ packed[1] = struct.pack("!H", length)
+ return ''.join(packed)
+
+ @staticmethod
+ def unpack(reader):
+ obj = bsn_packet_of_death()
+ _type = reader.read("!H")[0]
+ assert(_type == 65535)
+ _len = reader.read("!H")[0]
+ orig_reader = reader
+ reader = orig_reader.slice(_len - (2 + 2))
+ _experimenter = reader.read("!L")[0]
+ assert(_experimenter == 6035143)
+ _subtype = reader.read("!L")[0]
+ assert(_subtype == 6)
+ reader.skip(4)
+ return obj
+
+ def __eq__(self, other):
+ if type(self) != type(other): return False
+ return True
+
+ def pretty_print(self, q):
+ q.text("bsn_packet_of_death {")
+ with q.group():
+ with q.indent(2):
+ q.breakable()
+ q.breakable()
+ q.text('}')
+
+bsn.subtypes[6] = bsn_packet_of_death
+
class bsn_permit(bsn):
type = 65535
experimenter = 6035143
diff --git a/src/python/loxi/of13/instruction_id.py b/src/python/loxi/of13/instruction_id.py
index 49157e6..7d64a9a 100644
--- a/src/python/loxi/of13/instruction_id.py
+++ b/src/python/loxi/of13/instruction_id.py
@@ -443,6 +443,52 @@
bsn.subtypes[0] = bsn_disable_src_mac_check
+class bsn_packet_of_death(bsn):
+ type = 65535
+ experimenter = 6035143
+ subtype = 6
+
+ def __init__(self):
+ return
+
+ def pack(self):
+ packed = []
+ packed.append(struct.pack("!H", self.type))
+ packed.append(struct.pack("!H", 0)) # placeholder for len at index 1
+ packed.append(struct.pack("!L", self.experimenter))
+ packed.append(struct.pack("!L", self.subtype))
+ length = sum([len(x) for x in packed])
+ packed[1] = struct.pack("!H", length)
+ return ''.join(packed)
+
+ @staticmethod
+ def unpack(reader):
+ obj = bsn_packet_of_death()
+ _type = reader.read("!H")[0]
+ assert(_type == 65535)
+ _len = reader.read("!H")[0]
+ orig_reader = reader
+ reader = orig_reader.slice(_len - (2 + 2))
+ _experimenter = reader.read("!L")[0]
+ assert(_experimenter == 6035143)
+ _subtype = reader.read("!L")[0]
+ assert(_subtype == 6)
+ return obj
+
+ def __eq__(self, other):
+ if type(self) != type(other): return False
+ return True
+
+ def pretty_print(self, q):
+ q.text("bsn_packet_of_death {")
+ with q.group():
+ with q.indent(2):
+ q.breakable()
+ q.breakable()
+ q.text('}')
+
+bsn.subtypes[6] = bsn_packet_of_death
+
class bsn_permit(bsn):
type = 65535
experimenter = 6035143