Signed-off-by: FUJITA Tomonori <[email protected]>
---
ryu/ofproto/ofproto_v1_0.py | 6 ++++++
ryu/ofproto/ofproto_v1_0_parser.py | 18 ++++++++++++++++++
2 files changed, 24 insertions(+), 0 deletions(-)
diff --git a/ryu/ofproto/ofproto_v1_0.py b/ryu/ofproto/ofproto_v1_0.py
index 2a39067..9892c2c 100644
--- a/ryu/ofproto/ofproto_v1_0.py
+++ b/ryu/ofproto/ofproto_v1_0.py
@@ -576,6 +576,7 @@ NXT_FLOW_MOD_TABLE_ID = 15
NXT_SET_PACKET_IN_FORMAT = 16
NXT_PACKET_IN = 17
NXT_FLOW_AGE = 18
+NXT_SET_ASYNC_CONFIG = 19
NXT_SET_CONTROLLER_ID = 20
# enum nx_role
@@ -631,6 +632,11 @@ NX_PACKET_IN_SIZE = 40
assert (calcsize(NX_PACKET_IN_PACK_STR) +
NICIRA_HEADER_SIZE == NX_PACKET_IN_SIZE)
+NX_ASYNC_CONFIG_PACK_STR = '!IIIIII'
+NX_ASYNC_CONFIG_SIZE = 40
+assert (calcsize(NX_ASYNC_CONFIG_PACK_STR) +
+ NICIRA_HEADER_SIZE == NX_ASYNC_CONFIG_SIZE)
+
NX_CONTROLLER_ID_PACK_STR = '!6xH'
NX_CONTROLLER_ID_SIZE = 24
assert (calcsize(NX_CONTROLLER_ID_PACK_STR) +
diff --git a/ryu/ofproto/ofproto_v1_0_parser.py
b/ryu/ofproto/ofproto_v1_0_parser.py
index 3218a5d..b80d645 100644
--- a/ryu/ofproto/ofproto_v1_0_parser.py
+++ b/ryu/ofproto/ofproto_v1_0_parser.py
@@ -1409,6 +1409,24 @@ class NXTFlowAge(NiciraHeader):
self.serialize_header()
+class NXTSetAsyncConfig(NiciraHeader):
+ def __init__(self, datapath, packet_in_mask, port_status_mask,
+ flow_removed_mask):
+ super(NXTSetAsyncConfig, self).__init__(
+ datapath, ofproto_v1_0.NXT_SET_ASYNC_CONFIG)
+ self.packet_in_mask = packet_in_mask
+ self.port_status_mask = port_status_mask
+ self.flow_removed_mask = flow_removed_mask
+
+ def _serialize_body(self):
+ self.serialize_header()
+ msg_pack_into(ofproto_v1_0.NX_ASYNC_CONFIG_PACK_STR,
+ self.buf, ofproto_v1_0.NICIRA_HEADER_SIZE,
+ self.packet_in_mask[0], self.packet_in_mask[1],
+ self.port_status_mask[0], self.port_status_mask[1],
+ self.flow_removed_mask[0], self.flow_removed_mask[1])
+
+
class NXTSetControllerId(NiciraHeader):
def __init__(self, datapath, controller_id):
super(NXTSetControllerId, self).__init__(
--
1.7.4.4
------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and
threat landscape has changed and how IT managers can respond. Discussions
will include endpoint security, mobile security and the latest in malware
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
Ryu-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ryu-devel