blob: 67a09f9385bfadd45a426e1489c88c1489aff12b [file] [log] [blame]
Joey Armstrong25589d82024-01-02 22:31:35 -05001// Copyright 2018-2024 Open Networking Foundation (ONF) and the ONF Contributors
Zack Williams52209662019-02-07 10:15:31 -07002//
3// Licensed under the Apache License, Version 2.0 (the "License");
4// you may not use this file except in compliance with the License.
5// You may obtain a copy of the License at:
6//
7// http://www.apache.org/licenses/LICENSE-2.0
8//
9// Unless required by applicable law or agreed to in writing, software
10// distributed under the License is distributed on an "AS IS" BASIS,
11// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12// See the License for the specific language governing permissions and
13// limitations under the License.
14
15syntax = "proto3";
William Kurkian7c151592019-03-27 09:36:15 -040016
khenaidoo5fc5cea2021-08-11 17:39:16 -040017option go_package = "github.com/opencord/voltha-protos/v5/go/openolt";
Serkant Uluderyacbcfaa42019-10-18 13:25:08 +030018option java_package = "org.opencord.voltha.openolt";
19option java_outer_classname = "VolthaOpenOLT";
William Kurkian7c151592019-03-27 09:36:15 -040020
Zack Williams52209662019-02-07 10:15:31 -070021package openolt;
22import "google/api/annotations.proto";
khenaidoo4c6543e2021-10-19 17:25:58 -040023import "voltha_protos/tech_profile.proto";
dpaul2b52e712020-06-23 13:02:28 +053024import "voltha_protos/ext_config.proto";
khenaidoo4c6543e2021-10-19 17:25:58 -040025import "voltha_protos/extensions.proto";
Akash Kankanala761955c2024-02-21 19:32:20 +053026import "voltha_protos/common.proto";
Zack Williams52209662019-02-07 10:15:31 -070027
28service Openolt {
29
30 rpc DisableOlt(Empty) returns (Empty) {
31 option (google.api.http) = {
32 post: "/v1/Disable"
33 body: "*"
34 };
35 }
36
37 rpc ReenableOlt(Empty) returns (Empty) {
38 option (google.api.http) = {
39 post: "/v1/Reenable"
40 body: "*"
41 };
42 }
43
44 rpc ActivateOnu(Onu) returns (Empty) {
45 option (google.api.http) = {
46 post: "/v1/EnableOnu"
47 body: "*"
48 };
49 }
50
51 rpc DeactivateOnu(Onu) returns (Empty) {
52 option (google.api.http) = {
53 post: "/v1/DisableOnu"
54 body: "*"
55 };
56 }
57
58 rpc DeleteOnu(Onu) returns (Empty) {
59 option (google.api.http) = {
60 post: "/v1/DeleteOnu"
61 body: "*"
62 };
63 }
64
65 rpc OmciMsgOut(OmciMsg) returns (Empty) {
66 option (google.api.http) = {
67 post: "/v1/OmciMsgOut"
68 body: "*"
69 };
70 }
71
72 rpc OnuPacketOut(OnuPacket) returns (Empty) {
73 option (google.api.http) = {
74 post: "/v1/OnuPacketOut"
75 body: "*"
76 };
77 }
78
79 rpc UplinkPacketOut(UplinkPacket) returns (Empty) {
80 option (google.api.http) = {
81 post: "/v1/UplinkPacketOut"
82 body: "*"
83 };
84 }
85
86 rpc FlowAdd(Flow) returns (Empty) {
87 option (google.api.http) = {
88 post: "/v1/FlowAdd"
89 body: "*"
90 };
91 }
92
93 rpc FlowRemove(Flow) returns (Empty) {
94 option (google.api.http) = {
95 post: "/v1/FlowRemove"
96 body: "*"
97 };
98 }
99
100 rpc HeartbeatCheck(Empty) returns (Heartbeat) {
101 option (google.api.http) = {
102 post: "/v1/HeartbeatCheck"
103 body: "*"
104 };
105 }
106
107 rpc EnablePonIf(Interface) returns (Empty) {
108 option (google.api.http) = {
109 post: "/v1/EnablePonIf"
110 body: "*"
111 };
112 }
113
114 rpc DisablePonIf(Interface) returns (Empty) {
115 option (google.api.http) = {
116 post: "/v1/DisablePonIf"
117 body: "*"
118 };
119 }
120
121 rpc GetDeviceInfo(Empty) returns (DeviceInfo) {
122 option (google.api.http) = {
123 post: "/v1/GetDeviceInfo"
124 body: "*"
125 };
126 }
127
128 rpc Reboot(Empty) returns (Empty) {
129 option (google.api.http) = {
130 post: "/v1/Reboot"
131 body: "*"
132 };
133 }
134
135 rpc CollectStatistics(Empty) returns (Empty) {
136 option (google.api.http) = {
137 post: "/v1/CollectStatistics"
138 body: "*"
139 };
140 }
141
Gamze Abaka66fe96f2020-12-17 13:27:27 +0000142 rpc GetOnuStatistics(Onu) returns (OnuStatistics) {
143 option (google.api.http) = {
144 post: "/v1/GetOnuStatistics"
145 body: "*"
146 };
147 }
148
149 rpc GetGemPortStatistics(OnuPacket) returns (GemPortStatistics) {
150 option (google.api.http) = {
151 post: "/v1/GetGemPortStatistics"
152 body: "*"
153 };
154 }
155
Abhilash Laxmeshwardfbb74d2019-07-23 08:03:08 -0400156 rpc CreateTrafficSchedulers(tech_profile.TrafficSchedulers) returns (Empty) {
Zack Williams52209662019-02-07 10:15:31 -0700157 option (google.api.http) = {
Abhilash Laxmeshwardfbb74d2019-07-23 08:03:08 -0400158 post: "/v1/CreateTrafficSchedulers"
Zack Williams52209662019-02-07 10:15:31 -0700159 body: "*"
160 };
161 }
162
Abhilash Laxmeshwardfbb74d2019-07-23 08:03:08 -0400163 rpc RemoveTrafficSchedulers(tech_profile.TrafficSchedulers) returns (Empty) {
Zack Williams52209662019-02-07 10:15:31 -0700164 option (google.api.http) = {
Abhilash Laxmeshwardfbb74d2019-07-23 08:03:08 -0400165 post: "/v1/RemoveTrafficSchedulers"
166 body: "*"
167 };
168 }
169
170 rpc CreateTrafficQueues(tech_profile.TrafficQueues) returns (Empty) {
171 option (google.api.http) = {
172 post: "/v1/CreateTrafficQueues"
173 body: "*"
174 };
175 }
176
177 rpc RemoveTrafficQueues(tech_profile.TrafficQueues) returns (Empty) {
178 option (google.api.http) = {
179 post: "/v1/RemoveTrafficQueues"
Zack Williams52209662019-02-07 10:15:31 -0700180 body: "*"
181 };
182 }
183
184 rpc EnableIndication(Empty) returns (stream Indication) {}
Burak Gurdag402dd952019-12-10 20:31:11 +0000185
186 rpc PerformGroupOperation(Group) returns (Empty) {
187 option (google.api.http) = {
188 post: "/v1/PerformGroupOperation"
189 body: "*"
190 };
191 }
Dinesh Belwalkared6da5e2020-02-25 11:23:57 -0800192
Burak Gurdagaadbcc02020-05-18 14:22:38 +0000193 rpc DeleteGroup(Group) returns (Empty) {
194 option (google.api.http) = {
195 post: "/v1/DeleteGroup"
196 body: "*"
197 };
198 }
199
khenaidoo4c6543e2021-10-19 17:25:58 -0400200 rpc GetExtValue(ValueParam) returns (extension.ReturnValues) {
Dinesh Belwalkared6da5e2020-02-25 11:23:57 -0800201 option (google.api.http) = {
202 post: "/v1/GetExtValue"
203 body: "*"
204 };
205 }
206
dpaul2b52e712020-06-23 13:02:28 +0530207 rpc OnuItuPonAlarmSet(config.OnuItuPonAlarm) returns (Empty) {
Jason Huang55ee29d2020-03-11 23:43:29 +0800208 option (google.api.http) = {
209 post: "/v1/OnuItuPonAlarmSet"
210 body: "*"
211 };
212 }
Jason Huang4f8a9372020-06-03 18:09:35 +0800213
214 rpc GetLogicalOnuDistanceZero(Onu) returns (OnuLogicalDistance) {
215 option (google.api.http) = {
216 post: "/v1/GetLogicalOnuDistanceZero"
217 body: "*"
218 };
219 }
220
221 rpc GetLogicalOnuDistance(Onu) returns (OnuLogicalDistance) {
222 option (google.api.http) = {
223 post: "/v1/GetLogicalOnuDistance"
224 body: "*"
225 };
226 }
Orhan Kupusogluda19b452021-05-12 12:19:16 +0000227
228 rpc GetPonRxPower(Onu) returns (PonRxPowerData) {
229 option (google.api.http) = {
230 post: "/v1/GetPonRxPower"
231 body: "*"
232 };
233 }
Abhilash Laxmeshward95e1992023-03-13 18:52:05 +0530234
235 /*
Abhilash Laxmeshwarba79e802023-03-30 15:28:20 +0530236 * GetOnuInfo takes Onu id, serialnumber, and pon interface as argument from the onu structure.
237 * Returns the Onu info from the device.
Abhilash Laxmeshward95e1992023-03-13 18:52:05 +0530238 */
Abhilash Laxmeshwarba79e802023-03-30 15:28:20 +0530239 rpc GetOnuInfo(Onu) returns (OnuInfo) {
Abhilash Laxmeshward95e1992023-03-13 18:52:05 +0530240 option (google.api.http) = {
Abhilash Laxmeshwarba79e802023-03-30 15:28:20 +0530241 post: "/v1/GetOnuInfo"
242 body: "*"
243 };
244 }
245
246 /*
247 * GetPonInterfaceInfo takes the pon intf id as argument.
248 * Returns the pon interface information from the device.
249 */
250 rpc GetPonInterfaceInfo(Interface) returns (PonIntfInfo) {
251 option (google.api.http) = {
252 post: "/v1/GetInterfaceInfo"
Abhilash Laxmeshward95e1992023-03-13 18:52:05 +0530253 body: "*"
254 };
255 }
Akash Kankanala761955c2024-02-21 19:32:20 +0530256
257 /*
258 * GetAllocIdStatistics takes onuId and allocId as argument.
259 * This method includes a default wait period of 10 secs before collecting the stats.
260 * The caller has to be aware of this wait and handle it accordingly.
261 * Returns AllocId statistics in the form of OnuAllocStatistics structure
262 */
263 rpc GetAllocIdStatistics(OnuPacket) returns (OnuAllocIdStatistics) {
264 option (google.api.http) = {
265 post: "/v1/GetAllocIdStatistics"
266 body: "*"
267 };
268 }
269
270 /*
271 * GetPonPortStatistics takes interface id and type as argument from Interface structure.
272 * Returns Pon port statistics in the form of PonStatsData structure.
273 */
274 rpc GetPonPortStatistics(Interface) returns (common.PortStatistics) {
275 option (google.api.http) = {
276 post: "/v1/GetPonPortStatistics"
277 body: "*"
278 };
279 }
280
281 /*
282 * GetNniPortStatistics takes takes interface id and type as argument from Interface structure.
283 * Returns Nni port statistics in the form of NniStatsData structure
284 */
285 rpc GetNniPortStatistics(Interface) returns (common.PortStatistics) {
286 option (google.api.http) = {
287 post: "/v1/GetNniPortStatistics"
288 body: "*"
289 };
290 }
Zack Williams52209662019-02-07 10:15:31 -0700291}
292
293message Indication {
294 oneof data {
295 OltIndication olt_ind = 1;
296 IntfIndication intf_ind = 2;
297 IntfOperIndication intf_oper_ind = 3;
298 OnuDiscIndication onu_disc_ind = 4;
299 OnuIndication onu_ind = 5;
300 OmciIndication omci_ind = 6;
301 PacketIndication pkt_ind = 7;
Akash Kankanala761955c2024-02-21 19:32:20 +0530302 common.PortStatistics port_stats = 8;
Zack Williams52209662019-02-07 10:15:31 -0700303 FlowStatistics flow_stats = 9;
304 AlarmIndication alarm_ind= 10;
305 }
306}
307
308message AlarmIndication {
309 oneof data {
310 LosIndication los_ind = 1;
311 DyingGaspIndication dying_gasp_ind = 2;
312 OnuAlarmIndication onu_alarm_ind = 3;
313 OnuStartupFailureIndication onu_startup_fail_ind = 4;
314 OnuSignalDegradeIndication onu_signal_degrade_ind = 5;
315 OnuDriftOfWindowIndication onu_drift_of_window_ind = 6;
316 OnuLossOfOmciChannelIndication onu_loss_omci_ind = 7;
317 OnuSignalsFailureIndication onu_signals_fail_ind = 8;
318 OnuTransmissionInterferenceWarning onu_tiwi_ind = 9;
319 OnuActivationFailureIndication onu_activation_fail_ind = 10;
320 OnuProcessingErrorIndication onu_processing_error_ind = 11;
Naga Manjunath0a734252019-11-21 19:00:23 +0530321 OnuLossOfKeySyncFailureIndication onu_loss_of_sync_fail_ind = 12;
322 OnuItuPonStatsIndication onu_itu_pon_stats_ind = 13;
Devmalya Paulea6eb472020-02-04 20:41:01 -0500323 OnuDeactivationFailureIndication onu_deactivation_failure_ind = 14;
Devmalya Paulb0c12472020-02-18 20:08:53 -0500324 OnuRemoteDefectIndication onu_remote_defect_ind = 15;
Devmalya Paul82957962020-03-01 18:49:37 -0500325 OnuLossOfGEMChannelDelineationIndication onu_loss_gem_delineation_ind = 16;
326 OnuPhysicalEquipmentErrorIndication onu_physical_equipment_error_ind = 17;
327 OnuLossOfAcknowledgementIndication onu_loss_of_ack_ind = 18;
Devmalya Paul342bf9d2020-03-19 02:42:56 -0400328 OnuDifferentialReachExceededIndication onu_diff_reach_exceeded_ind = 19;
Zack Williams52209662019-02-07 10:15:31 -0700329 }
330}
331
332message OltIndication {
333 string oper_state = 1; // up, down
334}
335
336message IntfIndication {
337 fixed32 intf_id = 1;
338 string oper_state = 2; // up, down
339}
340
341message OnuDiscIndication {
342 fixed32 intf_id = 1;
343 SerialNumber serial_number = 2;
344}
345
346message OnuIndication {
347 fixed32 intf_id = 1;
348 fixed32 onu_id = 2;
349 string oper_state = 3; // up, down
350 string admin_state = 5; // up, down
351 SerialNumber serial_number = 4;
kesavandd1a8bca2020-08-27 19:24:07 +0530352 /** activation fail reason. */
353 enum ActivationFailReason
354 {
355 ONU_ACTIVATION_FAIL_REASON_NONE = 0;
356 ONU_ACTIVATION_FAIL_REASON_RANGING = 1; //Ranging Failure
357 ONU_ACTIVATION_FAIL_REASON_PASSWORD_AUTHENTICATION = 2; //Password authentication
358 ONU_ACTIVATION_FAIL_REASON_LOS = 3; //LOS
359 ONU_ACTIVATION_FAIL_ONU_ALARM = 4; // ONU Alarm
360 ONU_ACTIVATION_FAIL_SWITCH_OVER = 5; //protection switch over
361 }
362 ActivationFailReason fail_reason = 6;
363
Zack Williams52209662019-02-07 10:15:31 -0700364}
365
366message IntfOperIndication {
367 string type = 1; // nni, pon
368 fixed32 intf_id = 2;
369 string oper_state = 3; // up, down
Elia Battiston345a5b72022-02-01 10:17:56 +0100370 fixed32 speed = 4; // measured in Mbps
Girish Gowdra34ff0c42022-03-10 16:04:23 -0800371 string technology = 5;
372
373 message PONResourceRanges {
374
375 message Pool {
376
377 enum PoolType {
378 ONU_ID = 0;
379 ALLOC_ID = 1;
380 GEMPORT_ID = 2;
381 FLOW_ID = 3;
382 }
383
384
385 PoolType type = 1;
386 fixed32 start = 3; // lower bound on IDs allocated from this pool
387 fixed32 end = 4; // upper bound on IDs allocated from this pool
388 }
389
390 repeated Pool pools = 3;
391 }
392
393 PONResourceRanges ranges = 6;
Zack Williams52209662019-02-07 10:15:31 -0700394}
395
396message OmciIndication {
397 fixed32 intf_id = 1;
398 fixed32 onu_id = 2;
399 bytes pkt = 3;
400}
401
402message PacketIndication {
403 string intf_type = 5; // nni, pon, unknown
404 fixed32 intf_id = 1;
Girish Gowdra31a356c2021-05-14 15:56:04 -0700405 fixed32 onu_id = 8;
406 fixed32 uni_id = 9;
Zack Williams52209662019-02-07 10:15:31 -0700407 fixed32 gemport_id = 2;
408 fixed32 flow_id = 3;
409 fixed32 port_no = 6;
410 fixed64 cookie = 7;
411 bytes pkt = 4;
412}
413
414message Interface {
415 fixed32 intf_id = 1;
Akash Kankanala761955c2024-02-21 19:32:20 +0530416 fixed32 intf_type = 2;
Zack Williams52209662019-02-07 10:15:31 -0700417}
418
419message Heartbeat {
420 fixed32 heartbeat_signature = 1;
421}
422
423message Onu {
424 fixed32 intf_id = 1;
425 fixed32 onu_id = 2;
426 SerialNumber serial_number = 3;
427 fixed32 pir = 4; // peak information rate assigned to onu
kesavand66bade72020-08-05 06:16:34 +0200428 bool omcc_encryption = 5;
Zack Williams52209662019-02-07 10:15:31 -0700429}
430
Jason Huang4f8a9372020-06-03 18:09:35 +0800431message OnuLogicalDistance {
432 fixed32 intf_id = 1;
433 fixed32 onu_id = 2;
434 fixed32 logical_onu_distance_zero = 3; //0km logical distance
435 fixed32 logical_onu_distance = 4;
436}
437
Zack Williams52209662019-02-07 10:15:31 -0700438message OmciMsg {
439 fixed32 intf_id = 1;
440 fixed32 onu_id = 2;
441 bytes pkt = 3;
442}
443
444message OnuPacket {
445 fixed32 intf_id = 1;
446 fixed32 onu_id = 2;
447 fixed32 port_no = 4;
Abhilash Laxmeshwardfbb74d2019-07-23 08:03:08 -0400448 fixed32 gemport_id = 5;
Akash Kankanala761955c2024-02-21 19:32:20 +0530449 fixed32 alloc_id = 6;
Zack Williams52209662019-02-07 10:15:31 -0700450 bytes pkt = 3;
451}
452
453message UplinkPacket {
454 fixed32 intf_id = 1;
455 bytes pkt = 2;
456}
457
458message DeviceInfo {
459 string vendor = 1;
460 string model = 2;
461 string hardware_version = 3;
462 string firmware_version = 4;
463 string device_id = 16;
464 string device_serial_number = 17;
Gamze Abaka7a0d3942021-03-11 11:41:36 +0000465 bool previously_connected = 19; // used to indicate agent reconcile status
Zack Williams52209662019-02-07 10:15:31 -0700466
467 // Total number of pon intf ports on the device
468 fixed32 pon_ports = 12;
Sridhar Ravindra8859b3e2025-05-28 13:02:27 +0530469 // Total number of nni intf ports on the device
470 fixed32 nni_ports = 20;
Zack Williams52209662019-02-07 10:15:31 -0700471
Elia Battiston3e451982022-02-23 09:43:26 +0100472 reserved 5 to 11, 13, 14;
473 // Not used anymore, this information is defined per-range only
474 // and is fully provided by DeviceResourceRanges
475 //
476 // string technology = 5;
477 // fixed32 onu_id_start = 6;
478 // fixed32 onu_id_end = 7;
479 // fixed32 alloc_id_start = 8;
480 // fixed32 alloc_id_end = 9;
481 // fixed32 gemport_id_start = 10;
482 // fixed32 gemport_id_end = 11;
483 // fixed32 flow_id_start = 13;
484 // fixed32 flow_id_end = 14;
Zack Williams52209662019-02-07 10:15:31 -0700485
486 message DeviceResourceRanges {
487
488 // List of 0 or more intf_ids that use the same technology and pools.
489 // If 0 intf_ids supplied, it implies ALL interfaces
490 repeated fixed32 intf_ids = 1;
491
492 // Technology profile for this pool
493 string technology = 2;
494
495 message Pool {
496 enum PoolType {
497 ONU_ID = 0;
498 ALLOC_ID = 1;
499 GEMPORT_ID = 2;
500 FLOW_ID = 3;
501 }
502
503 enum SharingType {
504 DEDICATED_PER_INTF = 0;
505 SHARED_BY_ALL_INTF_ALL_TECH = 1; // Shared across all interfaces in all technologies in all ranges
506 SHARED_BY_ALL_INTF_SAME_TECH = 2; // Shared across all interfaces of the same technology used in this range
507 }
508
509 PoolType type = 1;
510 SharingType sharing = 2;
511 fixed32 start = 3; // lower bound on IDs allocated from this pool
512 fixed32 end = 4; // upper bound on IDs allocated from this pool
513 }
514 repeated Pool pools = 3;
515 }
516 repeated DeviceResourceRanges ranges = 15;
517}
518
519message Classifier {
520 fixed32 o_tpid = 1;
521 fixed32 o_vid = 2;
522 fixed32 i_tpid = 3;
523 fixed32 i_vid = 4;
524 fixed32 o_pbits = 5;
525 fixed32 i_pbits = 6;
526 fixed32 eth_type = 7;
527 bytes dst_mac = 8;
528 bytes src_mac = 9;
529 fixed32 ip_proto = 10;
530 fixed32 dst_ip = 11;
531 fixed32 src_ip = 12;
532 fixed32 src_port = 13;
533 fixed32 dst_port = 14;
534 string pkt_tag_type = 15; // untagged, single_tag, double_tag
535}
536
537message ActionCmd {
538 bool add_outer_tag = 1;
539 bool remove_outer_tag = 2;
540 bool trap_to_host = 3;
Burak Gurdag402dd952019-12-10 20:31:11 +0000541 bool remark_outer_pbits = 4;
542 bool remark_inner_pbits = 5;
543 bool add_inner_tag = 6;
544 bool remove_inner_tag = 7;
545 bool translate_inner_tag = 8;
546 bool translate_outer_tag = 9;
Zack Williams52209662019-02-07 10:15:31 -0700547}
548
549message Action {
550 ActionCmd cmd = 1;
551 fixed32 o_vid = 2;
552 fixed32 o_pbits = 3;
553 fixed32 o_tpid = 4;
554 fixed32 i_vid = 5;
555 fixed32 i_pbits = 6;
556 fixed32 i_tpid = 7;
557}
558
559message Flow {
560 sfixed32 access_intf_id = 1;
561 sfixed32 onu_id = 2;
562 sfixed32 uni_id = 11;
Girish Gowdrab152d9f2020-08-17 11:37:50 -0700563
564 fixed64 flow_id = 3; // voltha flow-id. 0 is not a valid flow_id
565 fixed64 symmetric_flow_id = 18; // symmetric voltha flow-id, if applicable. All data path flows generally have a symmetric flow,
566 // but trap-to-controller flows do not have a symmetric flow
567 // Broadcom BAL requires that symmetric flows use the same BAL flow-id
568
569 string flow_type = 4; // upstream, downstream, broadcast, multicast
Zack Williams52209662019-02-07 10:15:31 -0700570 sfixed32 alloc_id = 10;
571 sfixed32 network_intf_id = 5;
Girish Gowdrab152d9f2020-08-17 11:37:50 -0700572 sfixed32 gemport_id = 6; // When 'replicate_flow' field is true, this field is obsolete.
Zack Williams52209662019-02-07 10:15:31 -0700573 Classifier classifier = 7;
574 Action action = 8;
575 sfixed32 priority = 9;
576 fixed64 cookie = 12; // must be provided for any flow with trap_to_host action. Returned in PacketIndication
577 fixed32 port_no = 13; // must be provided for any flow with trap_to_host action. Returned in PacketIndication
Burak Gurdag402dd952019-12-10 20:31:11 +0000578 fixed32 group_id = 14;
Burak Gurdagce064352020-04-20 20:11:18 +0000579 fixed32 tech_profile_id = 15;
Girish Gowdrab152d9f2020-08-17 11:37:50 -0700580
581 bool replicate_flow = 16; // When this field is true, use pbitToGemPortID to know which p-bit needs to be classfied to which gem port.
582 map<fixed32, fixed32> pbit_to_gemport = 17; // Map of p-bit to gem port ID
Gamze Abakad8caefa2021-02-26 10:31:15 +0000583 map<fixed32, bool> gemport_to_aes = 19; // Map of gem port ID to aes encryption
Zack Williams52209662019-02-07 10:15:31 -0700584}
585
586message SerialNumber {
587 bytes vendor_id = 1;
588 bytes vendor_specific = 2;
589}
590
Gamze Abaka66fe96f2020-12-17 13:27:27 +0000591message OnuStatistics {
592 fixed32 intf_id = 1;
593 fixed32 onu_id = 2;
594 fixed64 positive_drift = 3;
595 fixed64 negative_drift = 4;
596 fixed64 delimiter_miss_detection = 5;
597 fixed64 bip_errors = 6;
598 fixed64 bip_units = 7;
599 fixed64 fec_corrected_symbols = 8;
600 fixed64 fec_codewords_corrected = 9;
601 fixed64 fec_codewords_uncorrectable = 10;
602 fixed64 fec_codewords = 11;
603 fixed64 fec_corrected_units = 12;
604 fixed64 xgem_key_errors = 13;
605 fixed64 xgem_loss = 14;
606 fixed64 rx_ploams_error = 15;
607 fixed64 rx_ploams_non_idle = 16;
608 fixed64 rx_omci = 17;
609 fixed64 rx_omci_packets_crc_error = 18;
610 fixed64 rx_bytes = 19;
611 fixed64 rx_packets = 20;
612 fixed64 tx_bytes = 21;
613 fixed64 tx_packets = 22;
614 fixed64 ber_reported = 23;
615 fixed64 lcdg_errors = 24;
616 fixed64 rdi_errors = 25;
617 fixed32 timestamp = 26;
618}
619
620message GemPortStatistics {
621 fixed32 intf_id = 1;
622 fixed32 gemport_id = 2;
623 fixed64 rx_packets = 3;
624 fixed64 rx_bytes = 4;
625 fixed64 tx_packets = 5;
626 fixed64 tx_bytes = 6;
627 fixed32 timestamp = 26;
628}
629
Zack Williams52209662019-02-07 10:15:31 -0700630message FlowStatistics {
631 fixed32 flow_id = 1;
632 fixed64 rx_bytes = 2;
633 fixed64 rx_packets = 3;
634 fixed64 tx_bytes = 8;
635 fixed64 tx_packets = 9;
636 fixed32 timestamp = 16;
637}
638
639message LosIndication {
640 fixed32 intf_id = 1;
641 string status = 2;
642}
643
644message DyingGaspIndication {
645 fixed32 intf_id = 1;
646 fixed32 onu_id = 2;
647 string status = 3;
648}
649
650message OnuAlarmIndication {
651 fixed32 intf_id = 1;
652 fixed32 onu_id = 2;
653 string los_status = 3;
654 string lob_status = 4;
655 string lopc_miss_status = 5;
656 string lopc_mic_error_status = 6;
Naga Manjunath0a734252019-11-21 19:00:23 +0530657 string lofi_status = 7;
658 string loami_status = 8;
Zack Williams52209662019-02-07 10:15:31 -0700659}
660
661message OnuStartupFailureIndication {
662 fixed32 intf_id = 1;
663 fixed32 onu_id = 2;
664 string status = 3;
665}
666
667message OnuSignalDegradeIndication {
668 fixed32 intf_id = 1;
669 fixed32 onu_id = 2;
670 string status = 3;
671 fixed32 inverse_bit_error_rate = 4;
672}
673
674message OnuDriftOfWindowIndication {
675 fixed32 intf_id = 1;
676 fixed32 onu_id = 2;
677 string status = 3;
678 fixed32 drift = 4;
679 fixed32 new_eqd = 5;
680}
681
682message OnuLossOfOmciChannelIndication {
683 fixed32 intf_id = 1;
684 fixed32 onu_id = 2;
685 string status = 3;
686}
687
688message OnuSignalsFailureIndication {
689 fixed32 intf_id = 1;
690 fixed32 onu_id = 2;
691 string status = 3;
692 fixed32 inverse_bit_error_rate = 4;
693}
694
695message OnuTransmissionInterferenceWarning {
696 fixed32 intf_id = 1;
697 fixed32 onu_id = 2;
698 string status = 3;
699 fixed32 drift = 4;
700}
701
702message OnuActivationFailureIndication {
703 fixed32 intf_id = 1;
704 fixed32 onu_id = 2;
Naga Manjunath0a734252019-11-21 19:00:23 +0530705 fixed32 fail_reason = 3;
706}
707
708message OnuLossOfKeySyncFailureIndication {
709 fixed32 intf_id = 1;
710 fixed32 onu_id = 2;
711 string status = 3;
712}
713
Girish Gowdra5192ea82020-05-06 20:49:11 -0700714message RdiErrorIndication {
715 fixed64 rdi_error_count = 1; // RDI Error count
716 string status = 2; // on/off based on configured reporting condition
717}
718
Naga Manjunath0a734252019-11-21 19:00:23 +0530719message OnuItuPonStatsIndication{
720 fixed32 intf_id = 1;
721 fixed32 onu_id = 2;
Girish Gowdra5192ea82020-05-06 20:49:11 -0700722 oneof stats {
723 RdiErrorIndication rdi_error_ind = 3;
724 // add more here
725 }
Zack Williams52209662019-02-07 10:15:31 -0700726}
727
728message OnuProcessingErrorIndication {
729 fixed32 intf_id = 1;
730 fixed32 onu_id = 2;
731}
732
Devmalya Paulea6eb472020-02-04 20:41:01 -0500733message OnuDeactivationFailureIndication {
734 fixed32 intf_id = 1;
735 fixed32 onu_id = 2;
Girish Gowdra5192ea82020-05-06 20:49:11 -0700736 string status = 3;
Devmalya Paulea6eb472020-02-04 20:41:01 -0500737}
738
Jason Huang55ee29d2020-03-11 23:43:29 +0800739message OnuRemoteDefectIndication {
Devmalya Paulb0c12472020-02-18 20:08:53 -0500740 fixed32 intf_id = 1;
741 fixed32 onu_id = 2;
Jason Huang55ee29d2020-03-11 23:43:29 +0800742 fixed64 rdi_errors = 3;
Devmalya Paulb0c12472020-02-18 20:08:53 -0500743}
744
Devmalya Paul82957962020-03-01 18:49:37 -0500745message OnuLossOfGEMChannelDelineationIndication {
746 fixed32 intf_id = 1;
747 fixed32 onu_id = 2;
748 string status = 3;
749 fixed32 delineation_errors = 4;
750}
751
752message OnuPhysicalEquipmentErrorIndication {
753 fixed32 intf_id = 1;
754 fixed32 onu_id = 2;
755 string status = 3;
756}
757
758message OnuLossOfAcknowledgementIndication {
759 fixed32 intf_id = 1;
760 fixed32 onu_id = 2;
761 string status = 3;
762}
763
Devmalya Paul342bf9d2020-03-19 02:42:56 -0400764message OnuDifferentialReachExceededIndication {
765 fixed32 intf_id = 1;
766 fixed32 onu_id = 2;
767 string status = 3;
768 fixed32 distance = 4;
769}
770
Burak Gurdag402dd952019-12-10 20:31:11 +0000771message GroupMember {
772 enum InterfaceType {
773 PON = 0;
774 EPON_1G_PATH = 1;
775 EPON_10G_PATH = 2;
776 }
777 uint32 interface_id = 1;
778 InterfaceType interface_type = 2;
779 uint32 gem_port_id = 3;
780 uint32 priority = 4; // Priority (and also the ID) of the default fixed queue for the multicast traffic.
781 // This queue is attached to the default PON port scheduler.
782}
783
784message Group {
785 enum GroupMembersCommand {
786 ADD_MEMBERS = 0;
787 REMOVE_MEMBERS = 1;
788 SET_MEMBERS = 2;
789 }
790
791 uint32 group_id = 1;
792 GroupMembersCommand command = 2;
793 repeated GroupMember members = 3;
794 Action action = 4;
795}
796
Dinesh Belwalkared6da5e2020-02-25 11:23:57 -0800797message ValueParam {
798 Onu onu = 1;
khenaidoo4c6543e2021-10-19 17:25:58 -0400799 extension.ValueType.Type value = 2;
Dinesh Belwalkared6da5e2020-02-25 11:23:57 -0800800}
Burak Gurdag402dd952019-12-10 20:31:11 +0000801
Orhan Kupusogluda19b452021-05-12 12:19:16 +0000802message PonRxPowerData {
803 enum RssiMeasurementFailReason {
804 FAIL_REASON_NONE = 0;
805 FAIL_REASON_NO_DELIMITER = 1;
806 FAIL_REASON_NO_ACCESS = 2;
807 }
Burak Gurdag402dd952019-12-10 20:31:11 +0000808
Orhan Kupusogluda19b452021-05-12 12:19:16 +0000809 fixed32 intf_id = 1;
810 fixed32 onu_id = 2;
811 string status = 3;
812 RssiMeasurementFailReason fail_reason = 4;
813 double rx_power_mean_dbm = 5;
814}
815
Akash Kankanala761955c2024-02-21 19:32:20 +0530816message OnuAllocIdStatistics {
817 fixed32 intfId = 1;
818 fixed32 allocId = 2;
819 fixed64 rxBytes = 3;
820}
821
Abhilash Laxmeshward95e1992023-03-13 18:52:05 +0530822enum AlarmState {
823 OFF = 0;
824 ON = 1;
825}
826
827/*
828 * contains the onu id, state of the onu and the information about the alarms on the onu.
829 * As of now only few alarms are added, any further information needed can be added to the structure.
830 */
Abhilash Laxmeshwarba79e802023-03-30 15:28:20 +0530831message OnuInfo {
Abhilash Laxmeshward95e1992023-03-13 18:52:05 +0530832 fixed32 onu_id = 1;
Abhilash Laxmeshwarba79e802023-03-30 15:28:20 +0530833 enum OnuState {
834 /*
835 * There are other states in BAL for ONU, which voltha is not interested as of now.
836 * UNKNOWN is to be filled for the rest of the states other than NOT_CONFIGURED/ACTIVE/INACTIVE/DISABLED
837 */
838 UNKNOWN = 0;
839 NOT_CONFIGURED = 1;
840 ACTIVE = 2;
841 INACTIVE = 3;
842 DISABLED = 4;
Abhilash Laxmeshward95e1992023-03-13 18:52:05 +0530843 }
Abhilash Laxmeshwarba79e802023-03-30 15:28:20 +0530844 OnuState state = 2;
Abhilash Laxmeshward95e1992023-03-13 18:52:05 +0530845 AlarmState losi = 3;
846 AlarmState lofi = 4;
Abhilash Laxmeshwarba79e802023-03-30 15:28:20 +0530847 AlarmState loami = 5;
Abhilash Laxmeshward95e1992023-03-13 18:52:05 +0530848}
849
850/*
Abhilash Laxmeshwarba79e802023-03-30 15:28:20 +0530851 * IntfInfo has the interface Id and if there are any alarms active on that interface.
Abhilash Laxmeshward95e1992023-03-13 18:52:05 +0530852 * Any further information needed from the interface object can be added to the structure.
853 */
Abhilash Laxmeshwarba79e802023-03-30 15:28:20 +0530854message PonIntfInfo {
Abhilash Laxmeshward95e1992023-03-13 18:52:05 +0530855 fixed32 intf_id = 1;
Abhilash Laxmeshwarba79e802023-03-30 15:28:20 +0530856 enum PonIntfState {
857 UNKNOWN = 0;
858 ACTIVE_WORKING = 1;
859 ACTIVE_STANDBY = 2;
860 INACTIVE = 3;
861 DISABLED = 4;
862 }
863 PonIntfState state = 3;
864 AlarmState los = 4;
Abhilash Laxmeshward95e1992023-03-13 18:52:05 +0530865}
866
Orhan Kupusogluda19b452021-05-12 12:19:16 +0000867message Empty {}