blob: 1c4b1e829e041b9a9ae5214624c651b9f9799e46 [file] [log] [blame]
Yafit Hadarf8caac02015-08-25 10:21:44 +03001/* This file input supports the Optical Transport Protocol Extentions - version 1.0 */
2
3#version 4
4/*Supported signal types for layer class OFPOTPL_ODU */
5enum ofp_odu_signal_type (wire_type=uint8_t) {
6 OFPODUT_ODU1 = 1,
7 OFPODUT_ODU2 = 2,
8 OFPODUT_ODU3 = 3,
9 OFPODUT_ODU4 = 4,
10 OFPODUT_ODU0 = 10,
11 OFPODUT_ODU2E = 11,
12 OFPODUT_ODUfCBR = 20,
13 OFPODUT_ODUfGFPfHAO = 21,
14 OFPODUT_ODUfGFPf = 22,
15};
16
17
18//enum ofp_experimenter_multipart_type_exp (wire_type=uint32_t){
Jimmy Jin646d1222016-05-13 10:47:24 -070019 //OFPEMPTE = 1, /*extended port discription */
20 //OFPEMPAD = 2, /*extended port adjacency discovery */
Yafit Hadarf8caac02015-08-25 10:21:44 +030021//};
22
23//enum ofp_port_desc_prop_type_exp (wire_type=uint32_t){
24 //OFPPDPT_OPTICAL_TRAMSPORT = 2,
Jimmy Jin646d1222016-05-13 10:47:24 -070025 //OFPPDPT_ADJACENCY_DISCOVERY = 3,
Yafit Hadarf8caac02015-08-25 10:21:44 +030026//};
27
28/* Supported signal types for layer class OFPPOTL_PORT */
29enum ofp_port_optical_transport_signal_type (wire_type=uint8_t) {
30 OFPPOTST_OTSn = 1,
31 OFPPOTST_OMSn = 2,
32 OFPPOTST_OPSn = 3,
33 OFPPOTST_OPSM = 4,
34 OFPPOTST_OCH = 5,
35 OFPPOTST_OTU1 = 11,
36 OFPPOTST_OTU2 = 12,
37 OFPPOTST_OTU3 = 13,
38 OFPPOTST_OTU4 = 14,
39};
40
41
42/* Features of optical transport ports available in switch. */
43enum ofp_port_optical_transport_feature_type (wire_type=uint16_t) {
44 OFPPOTFT_OPT_INTERFACE_CLASS = 1, /* Application code/ID encoding */
45 OFPPOTFT_LAYER_STACK = 2, /* Supported signal types and adaptations */
46};
47
48
49/*Supported signal types for layer class OFPOTPL_ODUCLT */
50enum ofp_oduclt_signal_type(wire_type=uint8_t) {
51 OFPODUCLT_STM16 = 1,
52 OFPODUCLT_STM64 = 2,
53 OFPODUCLT_STM256 = 3,
54 OFPODUCLT_STM1 = 4,
55 OFPODUCLT_STM4 = 5,
56 OFPODUCLT_GBE1 = 6,
57 OFPODUCLT_GBE10 = 7,
58 OFPODUCLT_GBE40 = 8,
59 OFPODUCLT_GBE100 = 9,
60 OFPODUCLT_FC100 = 10,
61 OFPODUCLT_FC200 = 11,
62 OFPODUCLT_FC400 = 12,
63 OFPODUCLT_FC800 = 13,
64 OFPODUCLT_FC1200 = 14,
65 OFPODUCLT_GPON = 15,
66 OFPODUCLT_XGPON = 16,
67 OFPODUCLT_IB_SDR = 17,
68 OFPODUCLT_IB_DDR = 18,
69 OFPODUCLT_IB_QDR = 19,
70 OFPODUCLT_SBCON_ESCON = 20,
71 OFPODUCLT_DVBASI = 21,
72 OFPODUCLT_SDI = 22,
73 OFPODUCLT_SDI1G5 = 23,
74 OFPODUCLT_SDI3G = 24,
75 OFPODUCLT_ATM = 25,
76 OFPODUCLT_ETH = 26,
77 OFPODUCLT_MPLS = 27,
78 OFPODUCLT_IP = 28,
79};
80
81/* Supported adaptations for optical transport port layer stack*/
82enum ofp_adaptations_type (wire_type=uint8_t){
83 OFPADAPT_OTS_OMS = 1,
84 OFPADAPT_OMS_OCH = 2,
85 OFPADAPT_OPS_OCHr = 3,
86 OFPADAPT_OPSM_OTUk = 4,
87 OFPADAPT_OCH_OTUk = 5,
88 OFPADAPT_ODUk_ODUij = 6,
89 OFPADAPT_ODUk_ODUj21 = 7,
90 OFPADAPT_ODUkh_ODUj21 = 8,
91 OFPADAPT_ODU0_CBRx = 9,
92 OFPADAPT_ODUk_CBRx = 10,
93 OFPADAPT_ODUk_CBRxg = 11,
94 OFPADAPT_ODUk_RSn = 12,
95 OFPADAPT_ODUk_ATM = 13,
96 OFPADAPT_ODUk_ETH = 14,
97 OFPADAPT_ODUkh_ETH = 15,
98 OFPADAPT_ODUk_ETHPPOS = 16,
99};
100
101struct of_oxm_exp_odu_sigtype : of_oxm {
102 uint32_t type_len == 0xFFFF0401;
103 uint32_t experimenter == 0xFF000007;
104 uint8_t value;
105};
106
107struct of_oxm_exp_odu_sig_id : of_oxm {
108 uint32_t type_len == 0xFFFF0610;
109 uint32_t experimenter == 0xFF000007;
110 of_odu_sig_id_t value;// size of this struct is 16 bytes 2+2+10+2(pad)
111};
112
113//This struct defenition is unnecessury for the openflow java ("make java" command )
114//It is reqiured for wireshark dissector ("make wireshark" command)
115struct of_odu_sig_id_t {
116 uint16_t tpn; //Tributary Port Number
117 uint16_t length; // Number of Tributary Slots included in tsmap,
118 // based on the Server ODU type and TS Granularity
119 of_octets_t tsmap; //tsmap;
120};
121
122struct of_oxm_exp_och_sigtype : of_oxm {
123 uint32_t type_len == 0xFFFF0801;
124 uint32_t experimenter == 0xFF000007;
125 uint8_t value;
126};
127
128struct of_oxm_exp_och_sig_id : of_oxm {
129 uint32_t type_len == 0xFFFF0A06;
130 uint32_t experimenter == 0xFF000007;
131 of_och_sig_id_t value;
132};
133
Jimmy Jin646d1222016-05-13 10:47:24 -0700134// Optical transport protocol extensions request & reply head
135struct of_exp_optical_ext_request : of_experimenter_stats_request {
136 uint8_t version;
137 uint8_t type == 18;
138 uint16_t length;
139 uint32_t xid;
140 uint16_t stats_type == 0xffff;
141 enum ofp_stats_request_flags flags;
142 pad(4);
143 uint32_t experimenter == 0xFF000007;
144 uint32_t subtype == ?;
145};
146
147struct of_exp_optical_ext_reply : of_experimenter_stats_reply {
148 uint8_t version;
149 uint8_t type == 19;
150 uint16_t length;
151 uint32_t xid;
152 uint16_t stats_type == 0xffff;
153 enum ofp_stats_reply_flags flags;
154 pad(4);
155 uint32_t experimenter == 0xFF000007;
156 uint32_t subtype == ?;
157};
Yafit Hadarf8caac02015-08-25 10:21:44 +0300158
159// open flow extention - support port description Extentions for OTN Ports
Jimmy Jin646d1222016-05-13 10:47:24 -0700160struct of_exp_port_desc_request : of_exp_optical_ext_request {
Yafit Hadarf8caac02015-08-25 10:21:44 +0300161 uint8_t version;
162 uint8_t type == 18;
163 uint16_t length;
164 uint32_t xid;
165 uint16_t stats_type == 0xffff;
166 enum ofp_stats_request_flags flags;
167 pad(4);
168 uint32_t experimenter == 0xFF000007;
169 uint32_t subtype == 1;//enum ofp_experimenter_multipart_type exp_type == 1;
170};
171
Jimmy Jin646d1222016-05-13 10:47:24 -0700172struct of_exp_port_desc_reply : of_exp_optical_ext_reply {
Yafit Hadarf8caac02015-08-25 10:21:44 +0300173 uint8_t version;
174 uint8_t type == 19;
175 uint16_t length;
176 uint32_t xid;
177 uint16_t stats_type == 0xffff;
178 enum ofp_stats_reply_flags flags;
179 pad(4);
180 uint32_t experimenter == 0xFF000007;
181 uint32_t subtype == 1;//enum ofp_experimenter_multipart_type subtype == 1;
182 list(of_exp_port_t) entries;
183};
184
185struct of_exp_port {
186 of_port_no_t port_no;
187 uint16_t length;
188 pad(2);
189 of_mac_addr_t hw_addr;
190 pad(2);
191 of_port_name_t name;
192 enum ofp_port_config config;
193 enum ofp_port_state state;
194 list(of_exp_port_desc_prop_optical_transport_t) properties;
195};
196
197struct of_exp_port_des_prop_header {
198 uint16_t type == 2; //enum ofp_port_desc_prop_type_exp type == 2;
199 uint16_t length;
200};
201
202struct of_exp_port_desc_prop_optical_transport // : of_exp_port_des_prop_header
203{
204 uint16_t type == 2;
205 uint16_t length; // length in bytes of this property
206 enum ofp_port_optical_transport_signal_type port_signal_type;
207 //base port layer signal type (enum ofp_port_optical_transport_signal_type)
208 uint8_t reserved;
209 pad(2);
210 list(of_exp_port_optical_transport_layer_stack_t) features; // list of of_port_optical_transport_feature_header
211};
212
213struct of_exp_port_optical_transport_feature_header {
214 uint16_t feature_type == ?; // from enum ofp_port_optical_transport_feature_type
215 uint16_t length;
216};
217
218/* OTN Layer Stack Feature Encoding */ //of_port_optical_transport_layer_stack (in circuit )
219struct of_exp_port_optical_transport_layer_stack// : of_exp_port_optical_transport_feature_header
220{
221 uint16_t feature_type == 2; /* Set to OFPOTPF_LAYER_STACK */
222 uint16_t length; /* length of feature excluding padding*/
223 pad(4); /* Zero bytes-see above for sizing */
224 list(of_exp_port_optical_transport_layer_entry_t) value; /* 0 or more fields */
225};
226
227/*OTN Layer Stack Entry Encoding */ // can be found in circut of_port_optical_transport_layer_entry
228struct of_exp_port_optical_transport_layer_entry {
229 enum ofp_port_optical_transport_layer_class layer_class; /* OFPPOTL_* */
230 uint8_t signal_type; /*OFP(OTP/OCH/ODU/ODUCL)T_*/
231 enum ofp_adaptations_type adaptation;/* OFPADAPT_*/
232 pad(5); /* Align to 64-bit boundary */
233};
234
235
Jimmy Jin646d1222016-05-13 10:47:24 -0700236// open flow extention - support port adjacency extentions
237/* SubTLVs used for send, expected and received identity strings */
238//enum ofp_exp_ext_port_tlv_types (wire_type=uint8_t) {
239// OFP_EXP_EXT_PORT_TLV_AD_ID_SENT = 2, //TTI to be send by the port
240// OFP_EXP_EXT_PORT_TLV_AD_ID_RECEIVED = 4, //TTI rcvd on port
241//};
Yafit Hadarf8caac02015-08-25 10:21:44 +0300242
Jimmy Jin646d1222016-05-13 10:47:24 -0700243/* used in state field in ofp_port */
244//enum ofp_port_state (wire_type=uint8_t) {
245// OPPPS_AD_ID_MISMATCH = 1 << 16
246//};
Yafit Hadarf8caac02015-08-25 10:21:44 +0300247
Jimmy Jin646d1222016-05-13 10:47:24 -0700248/* used in config field in ofp_port */
249//enum ofp_port_config {
250// OFPPF_AD_ENABL = 1<< 16,
251// OFPPF_AIS_AD_ID_MISMATCH = 1 << 17
252//};
Yafit Hadarf8caac02015-08-25 10:21:44 +0300253
Jimmy Jin646d1222016-05-13 10:47:24 -0700254struct of_exp_port_adjacency_request : of_exp_optical_ext_request {
255 uint8_t version;
256 uint8_t type == 18;
257 uint16_t length;
258 uint32_t xid;
259 uint16_t stats_type == 0xffff;
260 enum ofp_stats_request_flags flags;
261 pad(4);
262 uint32_t experimenter == 0xFF000007;
263 uint32_t subtype == 2;//enum ofp_experimenter_multipart_type exp_type == 2;
264};
265
266struct of_exp_port_adjacency_reply : of_exp_optical_ext_reply {
267 uint8_t version;
268 uint8_t type == 19;
269 uint16_t length;
270 uint32_t xid;
271 uint16_t stats_type == 0xffff;
272 enum ofp_stats_reply_flags flags;
273 pad(4);
274 uint32_t experimenter == 0xFF000007;
275 uint32_t subtype == 2;//enum ofp_experimenter_multipart_type subtype == 2;
276 list(of_exp_port_adjacency_t) entries;
277};
278
279//Port adjacency discovery property,
280//the body of ofp_experimenter_port in the spec.
281struct of_exp_port_adjacency {
282 of_port_no_t port_no;
283 uint16_t length;
284 pad(2);
285 of_mac_addr_t hw_addr;
286 pad(2);
287 of_port_name_t name;
288 enum ofp_port_config config;
289 enum ofp_port_state state;
290 list(of_exp_port_adjacency_id_t) properties;
291};
292
293//coresponding to ofp_port_desc_prop_adjacency_discovery in the spec
294//with adjecency id definition for otn network
295struct of_exp_port_adjacency_id
296{
297 uint16_t type == 3; //enum ofp_port_desc_prop_type_exp type == 3
298 uint16_t length; // length in bytes of this property
299 list(of_exp_ext_ad_id_t) ad_id;
300};
301
302struct of_exp_ext_ad_id
303{
304 uint16_t type;//enum ofp_exp_ext_port_tlv_types type;
305 uint16_t length; // The TLV value field length.
306 //defined as 8 + the length of id[] field
307 uint16_t namespace == 0; // One of OFPHTN*. OFPHTN_ONF = 0
308 uint16_t ns_type == ?; // type witin namespace
309};
310
311struct of_exp_port_adid_otn : of_exp_ext_ad_id
312{
313 uint16_t type; // ofp_exp_ext_port_tlv_types type;
314 uint16_t length; // The TLV value field length.
315 //defined as 8 + the length of id[] field
316 uint16_t namespace == 0; // One of OFPHTN*. OFPHTN_ONF = 0
317 uint16_t ns_type == 0; // type witin namespace
318 of_bitmap_128_t sapi; //source asccess point identifier, ex.ITUT G.831
319 of_bitmap_128_t dapi; //destination asccess point identifier,ex. ITUT G.831
320 of_bitmap_256_t opspec;//Operator specific value, ex. ITUT G.7714
321};
322
323struct of_exp_ext_adid_sonet : of_exp_ext_ad_id
324{
325 uint16_t type; //enum ofp_exp_ext_port_tlv_types type;
326 uint16_t length; // The TLV value field length.
327 //defined as 8 + the length of id[] field
328 uint16_t namespace == 0; // One of OFPHTN*. OFPHTN_ONF = 0
329 uint16_t ns_type == 1; // type witin namespace
330 of_bitmap_128_t id;
331};