Updates to some reply/request pairs
Starting to follow the convention that all set operations come in
request/reply pairs with a status code in the reply.
diff --git a/loxi_front_end/type_maps.py b/loxi_front_end/type_maps.py
index be81172..0289833 100644
--- a/loxi_front_end/type_maps.py
+++ b/loxi_front_end/type_maps.py
@@ -817,16 +817,19 @@
"of_bsn_get_interfaces_request" : 9,
"of_bsn_get_interfaces_reply" : 10,
"of_bsn_set_pktin_suppression" : 11,
- "of_bsn_set_l2_table" : 12,
+ "of_bsn_set_l2_table_request" : 12,
"of_bsn_get_l2_table_request" : 13,
"of_bsn_get_l2_table_reply" : 14,
"of_bsn_virtual_port_create_request" : 15,
"of_bsn_virtual_port_create_reply" : 16,
"of_bsn_virtual_port_remove" : 17,
- "of_bsn_bw_enable_set" : 18,
+ "of_bsn_bw_enable_set_request" : 18,
"of_bsn_bw_enable_get_request" : 19,
"of_bsn_bw_enable_get_reply" : 20,
- "of_bsn_bw_clear_data" : 21,
+ "of_bsn_bw_clear_data_request" : 21,
+ "of_bsn_bw_clear_data_reply" : 22,
+ "of_bsn_bw_enable_set_reply" : 23,
+ "of_bsn_set_l2_table_reply" : 24,
},
nicira = { # Nicira extensions, value is subtype
"of_nicira_controller_role_request" : 10,
@@ -844,10 +847,12 @@
"of_bsn_virtual_port_create_request" : 15,
"of_bsn_virtual_port_create_reply" : 16,
"of_bsn_virtual_port_remove" : 17,
- "of_bsn_bw_enable_set" : 18,
+ "of_bsn_bw_enable_set_request" : 18,
"of_bsn_bw_enable_get_request" : 19,
"of_bsn_bw_enable_get_reply" : 20,
- "of_bsn_bw_clear_data" : 21,
+ "of_bsn_bw_clear_data_request" : 21,
+ "of_bsn_bw_clear_data_reply" : 22,
+ "of_bsn_bw_enable_set_reply" : 23,
},
),
of_g.VERSION_1_2:dict( # Version 1.0 extensions
@@ -861,10 +866,12 @@
"of_bsn_virtual_port_create_request" : 15,
"of_bsn_virtual_port_create_reply" : 16,
"of_bsn_virtual_port_remove" : 17,
- "of_bsn_bw_enable_set" : 18,
+ "of_bsn_bw_enable_set_request" : 18,
"of_bsn_bw_enable_get_request" : 19,
"of_bsn_bw_enable_get_reply" : 20,
- "of_bsn_bw_clear_data" : 21,
+ "of_bsn_bw_clear_data_request" : 21,
+ "of_bsn_bw_clear_data_reply" : 22,
+ "of_bsn_bw_enable_set_reply" : 23,
},
),
of_g.VERSION_1_3:dict( # Version 1.0 extensions
@@ -878,10 +885,12 @@
"of_bsn_virtual_port_create_request" : 15,
"of_bsn_virtual_port_create_reply" : 16,
"of_bsn_virtual_port_remove" : 17,
- "of_bsn_bw_enable_set" : 18,
+ "of_bsn_bw_enable_set_request" : 18,
"of_bsn_bw_enable_get_request" : 19,
"of_bsn_bw_enable_get_reply" : 20,
- "of_bsn_bw_clear_data" : 21,
+ "of_bsn_bw_clear_data_request" : 21,
+ "of_bsn_bw_clear_data_reply" : 22,
+ "of_bsn_bw_enable_set_reply" : 23,
},
),
}
diff --git a/openflow_input/bsn_bw b/openflow_input/bsn_bw
index 830908f..b6e0972 100644
--- a/openflow_input/bsn_bw
+++ b/openflow_input/bsn_bw
@@ -30,7 +30,7 @@
#version any
-struct ofp_bsn_bw_enable_set {
+struct ofp_bsn_bw_enable_set_request {
uint8_t version;
uint8_t type; // OFPT_VENDOR
uint16_t length;
@@ -40,6 +40,17 @@
uint32_t enable; // 0 to disable the extension, 1 to enable it
};
+struct ofp_bsn_bw_enable_set_reply {
+ uint8_t version;
+ uint8_t type; // OFPT_VENDOR
+ uint16_t length;
+ uint32_t xid;
+ uint32_t experimenter; // OF_EXPERIMENTER_ID_BSN
+ uint32_t subtype; // BSN_BW_ENABLE_SET
+ uint32_t enable; // Resulting state, 0 disabled, 1 enabled
+ uint32_t status; // Result code: 0 success
+};
+
struct ofp_bsn_bw_enable_get_request {
uint8_t version;
uint8_t type; // OFPT_VENDOR
@@ -59,7 +70,7 @@
uint32_t enabled; // 0 if feature is disabled; 1 if feature enabled
};
-struct ofp_bsn_bw_clear_data {
+struct ofp_bsn_bw_clear_data_request {
uint8_t version;
uint8_t type; // OFPT_VENDOR
uint16_t length;
@@ -67,3 +78,13 @@
uint32_t experimenter; // OF_EXPERIMENTER_ID_BSN
uint32_t subtype; // BSN_BW_CLEAR_DATA
};
+
+struct ofp_bsn_bw_clear_data_reply {
+ uint8_t version;
+ uint8_t type; // OFPT_VENDOR
+ uint16_t length;
+ uint32_t xid;
+ uint32_t experimenter; // OF_EXPERIMENTER_ID_BSN
+ uint32_t subtype; // BSN_BW_CLEAR_DATA
+ uint32_t status; // Result code, 0 success
+};
diff --git a/openflow_input/bsn_l2_table b/openflow_input/bsn_l2_table
index 2a54b71..3795ea2 100644
--- a/openflow_input/bsn_l2_table
+++ b/openflow_input/bsn_l2_table
@@ -28,12 +28,12 @@
#version 1
// BSN L2 table configuration messages
-struct ofp_bsn_set_l2_table {
+struct ofp_bsn_set_l2_table_request {
uint8_t version;
uint8_t type;
uint16_t length;
uint32_t xid;
- uint32_t experimenter; // OF_EXPERIMENTER_ID_BSN
+ uint32_t experimenter; // OF_EXPERIMENTER_ID_BSN_REQUEST
uint32_t subtype; // BSN_L2_TABLE_SET
uint8_t l2_table_enable; // 1 == enabled, 0 == disabled
uint8_t pad;
@@ -41,6 +41,19 @@
uint8_t[4] pad;
};
+struct ofp_bsn_set_l2_table_reply {
+ uint8_t version;
+ uint8_t type;
+ uint16_t length;
+ uint32_t xid;
+ uint32_t experimenter; // OF_EXPERIMENTER_ID_BSN
+ uint32_t subtype; // BSN_L2_TABLE_SET_REPLY
+ uint8_t l2_table_enable; // Resulting state: 1 == enabled, 0 == disabled
+ uint8_t pad;
+ uint16_t l2_table_priority; // priority used, must match request if ok
+ uint32_t status; // 0 means success
+};
+
struct ofp_bsn_get_l2_table_request {
uint8_t version;
uint8_t type;