blob: 3fcd2af136751925f9398374cad7ad71e4638c64 [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";
Zack Williams52209662019-02-07 10:15:31 -070026
27service Openolt {
28
29 rpc DisableOlt(Empty) returns (Empty) {
30 option (google.api.http) = {
31 post: "/v1/Disable"
32 body: "*"
33 };
34 }
35
36 rpc ReenableOlt(Empty) returns (Empty) {
37 option (google.api.http) = {
38 post: "/v1/Reenable"
39 body: "*"
40 };
41 }
42
43 rpc ActivateOnu(Onu) returns (Empty) {
44 option (google.api.http) = {
45 post: "/v1/EnableOnu"
46 body: "*"
47 };
48 }
49
50 rpc DeactivateOnu(Onu) returns (Empty) {
51 option (google.api.http) = {
52 post: "/v1/DisableOnu"
53 body: "*"
54 };
55 }
56
57 rpc DeleteOnu(Onu) returns (Empty) {
58 option (google.api.http) = {
59 post: "/v1/DeleteOnu"
60 body: "*"
61 };
62 }
63
64 rpc OmciMsgOut(OmciMsg) returns (Empty) {
65 option (google.api.http) = {
66 post: "/v1/OmciMsgOut"
67 body: "*"
68 };
69 }
70
71 rpc OnuPacketOut(OnuPacket) returns (Empty) {
72 option (google.api.http) = {
73 post: "/v1/OnuPacketOut"
74 body: "*"
75 };
76 }
77
78 rpc UplinkPacketOut(UplinkPacket) returns (Empty) {
79 option (google.api.http) = {
80 post: "/v1/UplinkPacketOut"
81 body: "*"
82 };
83 }
84
85 rpc FlowAdd(Flow) returns (Empty) {
86 option (google.api.http) = {
87 post: "/v1/FlowAdd"
88 body: "*"
89 };
90 }
91
92 rpc FlowRemove(Flow) returns (Empty) {
93 option (google.api.http) = {
94 post: "/v1/FlowRemove"
95 body: "*"
96 };
97 }
98
99 rpc HeartbeatCheck(Empty) returns (Heartbeat) {
100 option (google.api.http) = {
101 post: "/v1/HeartbeatCheck"
102 body: "*"
103 };
104 }
105
106 rpc EnablePonIf(Interface) returns (Empty) {
107 option (google.api.http) = {
108 post: "/v1/EnablePonIf"
109 body: "*"
110 };
111 }
112
113 rpc DisablePonIf(Interface) returns (Empty) {
114 option (google.api.http) = {
115 post: "/v1/DisablePonIf"
116 body: "*"
117 };
118 }
119
120 rpc GetDeviceInfo(Empty) returns (DeviceInfo) {
121 option (google.api.http) = {
122 post: "/v1/GetDeviceInfo"
123 body: "*"
124 };
125 }
126
127 rpc Reboot(Empty) returns (Empty) {
128 option (google.api.http) = {
129 post: "/v1/Reboot"
130 body: "*"
131 };
132 }
133
134 rpc CollectStatistics(Empty) returns (Empty) {
135 option (google.api.http) = {
136 post: "/v1/CollectStatistics"
137 body: "*"
138 };
139 }
140
Gamze Abaka66fe96f2020-12-17 13:27:27 +0000141 rpc GetOnuStatistics(Onu) returns (OnuStatistics) {
142 option (google.api.http) = {
143 post: "/v1/GetOnuStatistics"
144 body: "*"
145 };
146 }
147
148 rpc GetGemPortStatistics(OnuPacket) returns (GemPortStatistics) {
149 option (google.api.http) = {
150 post: "/v1/GetGemPortStatistics"
151 body: "*"
152 };
153 }
154
Abhilash Laxmeshwardfbb74d2019-07-23 08:03:08 -0400155 rpc CreateTrafficSchedulers(tech_profile.TrafficSchedulers) returns (Empty) {
Zack Williams52209662019-02-07 10:15:31 -0700156 option (google.api.http) = {
Abhilash Laxmeshwardfbb74d2019-07-23 08:03:08 -0400157 post: "/v1/CreateTrafficSchedulers"
Zack Williams52209662019-02-07 10:15:31 -0700158 body: "*"
159 };
160 }
161
Abhilash Laxmeshwardfbb74d2019-07-23 08:03:08 -0400162 rpc RemoveTrafficSchedulers(tech_profile.TrafficSchedulers) returns (Empty) {
Zack Williams52209662019-02-07 10:15:31 -0700163 option (google.api.http) = {
Abhilash Laxmeshwardfbb74d2019-07-23 08:03:08 -0400164 post: "/v1/RemoveTrafficSchedulers"
165 body: "*"
166 };
167 }
168
169 rpc CreateTrafficQueues(tech_profile.TrafficQueues) returns (Empty) {
170 option (google.api.http) = {
171 post: "/v1/CreateTrafficQueues"
172 body: "*"
173 };
174 }
175
176 rpc RemoveTrafficQueues(tech_profile.TrafficQueues) returns (Empty) {
177 option (google.api.http) = {
178 post: "/v1/RemoveTrafficQueues"
Zack Williams52209662019-02-07 10:15:31 -0700179 body: "*"
180 };
181 }
182
183 rpc EnableIndication(Empty) returns (stream Indication) {}
Burak Gurdag402dd952019-12-10 20:31:11 +0000184
185 rpc PerformGroupOperation(Group) returns (Empty) {
186 option (google.api.http) = {
187 post: "/v1/PerformGroupOperation"
188 body: "*"
189 };
190 }
Dinesh Belwalkared6da5e2020-02-25 11:23:57 -0800191
Burak Gurdagaadbcc02020-05-18 14:22:38 +0000192 rpc DeleteGroup(Group) returns (Empty) {
193 option (google.api.http) = {
194 post: "/v1/DeleteGroup"
195 body: "*"
196 };
197 }
198
khenaidoo4c6543e2021-10-19 17:25:58 -0400199 rpc GetExtValue(ValueParam) returns (extension.ReturnValues) {
Dinesh Belwalkared6da5e2020-02-25 11:23:57 -0800200 option (google.api.http) = {
201 post: "/v1/GetExtValue"
202 body: "*"
203 };
204 }
205
dpaul2b52e712020-06-23 13:02:28 +0530206 rpc OnuItuPonAlarmSet(config.OnuItuPonAlarm) returns (Empty) {
Jason Huang55ee29d2020-03-11 23:43:29 +0800207 option (google.api.http) = {
208 post: "/v1/OnuItuPonAlarmSet"
209 body: "*"
210 };
211 }
Jason Huang4f8a9372020-06-03 18:09:35 +0800212
213 rpc GetLogicalOnuDistanceZero(Onu) returns (OnuLogicalDistance) {
214 option (google.api.http) = {
215 post: "/v1/GetLogicalOnuDistanceZero"
216 body: "*"
217 };
218 }
219
220 rpc GetLogicalOnuDistance(Onu) returns (OnuLogicalDistance) {
221 option (google.api.http) = {
222 post: "/v1/GetLogicalOnuDistance"
223 body: "*"
224 };
225 }
Orhan Kupusogluda19b452021-05-12 12:19:16 +0000226
227 rpc GetPonRxPower(Onu) returns (PonRxPowerData) {
228 option (google.api.http) = {
229 post: "/v1/GetPonRxPower"
230 body: "*"
231 };
232 }
Abhilash Laxmeshward95e1992023-03-13 18:52:05 +0530233
234 /*
Abhilash Laxmeshwarba79e802023-03-30 15:28:20 +0530235 * GetOnuInfo takes Onu id, serialnumber, and pon interface as argument from the onu structure.
236 * Returns the Onu info from the device.
Abhilash Laxmeshward95e1992023-03-13 18:52:05 +0530237 */
Abhilash Laxmeshwarba79e802023-03-30 15:28:20 +0530238 rpc GetOnuInfo(Onu) returns (OnuInfo) {
Abhilash Laxmeshward95e1992023-03-13 18:52:05 +0530239 option (google.api.http) = {
Abhilash Laxmeshwarba79e802023-03-30 15:28:20 +0530240 post: "/v1/GetOnuInfo"
241 body: "*"
242 };
243 }
244
245 /*
246 * GetPonInterfaceInfo takes the pon intf id as argument.
247 * Returns the pon interface information from the device.
248 */
249 rpc GetPonInterfaceInfo(Interface) returns (PonIntfInfo) {
250 option (google.api.http) = {
251 post: "/v1/GetInterfaceInfo"
Abhilash Laxmeshward95e1992023-03-13 18:52:05 +0530252 body: "*"
253 };
254 }
Zack Williams52209662019-02-07 10:15:31 -0700255}
256
257message Indication {
258 oneof data {
259 OltIndication olt_ind = 1;
260 IntfIndication intf_ind = 2;
261 IntfOperIndication intf_oper_ind = 3;
262 OnuDiscIndication onu_disc_ind = 4;
263 OnuIndication onu_ind = 5;
264 OmciIndication omci_ind = 6;
265 PacketIndication pkt_ind = 7;
266 PortStatistics port_stats = 8;
267 FlowStatistics flow_stats = 9;
268 AlarmIndication alarm_ind= 10;
269 }
270}
271
272message AlarmIndication {
273 oneof data {
274 LosIndication los_ind = 1;
275 DyingGaspIndication dying_gasp_ind = 2;
276 OnuAlarmIndication onu_alarm_ind = 3;
277 OnuStartupFailureIndication onu_startup_fail_ind = 4;
278 OnuSignalDegradeIndication onu_signal_degrade_ind = 5;
279 OnuDriftOfWindowIndication onu_drift_of_window_ind = 6;
280 OnuLossOfOmciChannelIndication onu_loss_omci_ind = 7;
281 OnuSignalsFailureIndication onu_signals_fail_ind = 8;
282 OnuTransmissionInterferenceWarning onu_tiwi_ind = 9;
283 OnuActivationFailureIndication onu_activation_fail_ind = 10;
284 OnuProcessingErrorIndication onu_processing_error_ind = 11;
Naga Manjunath0a734252019-11-21 19:00:23 +0530285 OnuLossOfKeySyncFailureIndication onu_loss_of_sync_fail_ind = 12;
286 OnuItuPonStatsIndication onu_itu_pon_stats_ind = 13;
Devmalya Paulea6eb472020-02-04 20:41:01 -0500287 OnuDeactivationFailureIndication onu_deactivation_failure_ind = 14;
Devmalya Paulb0c12472020-02-18 20:08:53 -0500288 OnuRemoteDefectIndication onu_remote_defect_ind = 15;
Devmalya Paul82957962020-03-01 18:49:37 -0500289 OnuLossOfGEMChannelDelineationIndication onu_loss_gem_delineation_ind = 16;
290 OnuPhysicalEquipmentErrorIndication onu_physical_equipment_error_ind = 17;
291 OnuLossOfAcknowledgementIndication onu_loss_of_ack_ind = 18;
Devmalya Paul342bf9d2020-03-19 02:42:56 -0400292 OnuDifferentialReachExceededIndication onu_diff_reach_exceeded_ind = 19;
Zack Williams52209662019-02-07 10:15:31 -0700293 }
294}
295
296message OltIndication {
297 string oper_state = 1; // up, down
298}
299
300message IntfIndication {
301 fixed32 intf_id = 1;
302 string oper_state = 2; // up, down
303}
304
305message OnuDiscIndication {
306 fixed32 intf_id = 1;
307 SerialNumber serial_number = 2;
308}
309
310message OnuIndication {
311 fixed32 intf_id = 1;
312 fixed32 onu_id = 2;
313 string oper_state = 3; // up, down
314 string admin_state = 5; // up, down
315 SerialNumber serial_number = 4;
kesavandd1a8bca2020-08-27 19:24:07 +0530316 /** activation fail reason. */
317 enum ActivationFailReason
318 {
319 ONU_ACTIVATION_FAIL_REASON_NONE = 0;
320 ONU_ACTIVATION_FAIL_REASON_RANGING = 1; //Ranging Failure
321 ONU_ACTIVATION_FAIL_REASON_PASSWORD_AUTHENTICATION = 2; //Password authentication
322 ONU_ACTIVATION_FAIL_REASON_LOS = 3; //LOS
323 ONU_ACTIVATION_FAIL_ONU_ALARM = 4; // ONU Alarm
324 ONU_ACTIVATION_FAIL_SWITCH_OVER = 5; //protection switch over
325 }
326 ActivationFailReason fail_reason = 6;
327
Zack Williams52209662019-02-07 10:15:31 -0700328}
329
330message IntfOperIndication {
331 string type = 1; // nni, pon
332 fixed32 intf_id = 2;
333 string oper_state = 3; // up, down
Elia Battiston345a5b72022-02-01 10:17:56 +0100334 fixed32 speed = 4; // measured in Mbps
Girish Gowdra34ff0c42022-03-10 16:04:23 -0800335 string technology = 5;
336
337 message PONResourceRanges {
338
339 message Pool {
340
341 enum PoolType {
342 ONU_ID = 0;
343 ALLOC_ID = 1;
344 GEMPORT_ID = 2;
345 FLOW_ID = 3;
346 }
347
348
349 PoolType type = 1;
350 fixed32 start = 3; // lower bound on IDs allocated from this pool
351 fixed32 end = 4; // upper bound on IDs allocated from this pool
352 }
353
354 repeated Pool pools = 3;
355 }
356
357 PONResourceRanges ranges = 6;
Zack Williams52209662019-02-07 10:15:31 -0700358}
359
360message OmciIndication {
361 fixed32 intf_id = 1;
362 fixed32 onu_id = 2;
363 bytes pkt = 3;
364}
365
366message PacketIndication {
367 string intf_type = 5; // nni, pon, unknown
368 fixed32 intf_id = 1;
Girish Gowdra31a356c2021-05-14 15:56:04 -0700369 fixed32 onu_id = 8;
370 fixed32 uni_id = 9;
Zack Williams52209662019-02-07 10:15:31 -0700371 fixed32 gemport_id = 2;
372 fixed32 flow_id = 3;
373 fixed32 port_no = 6;
374 fixed64 cookie = 7;
375 bytes pkt = 4;
376}
377
378message Interface {
379 fixed32 intf_id = 1;
380}
381
382message Heartbeat {
383 fixed32 heartbeat_signature = 1;
384}
385
386message Onu {
387 fixed32 intf_id = 1;
388 fixed32 onu_id = 2;
389 SerialNumber serial_number = 3;
390 fixed32 pir = 4; // peak information rate assigned to onu
kesavand66bade72020-08-05 06:16:34 +0200391 bool omcc_encryption = 5;
Zack Williams52209662019-02-07 10:15:31 -0700392}
393
Jason Huang4f8a9372020-06-03 18:09:35 +0800394message OnuLogicalDistance {
395 fixed32 intf_id = 1;
396 fixed32 onu_id = 2;
397 fixed32 logical_onu_distance_zero = 3; //0km logical distance
398 fixed32 logical_onu_distance = 4;
399}
400
Zack Williams52209662019-02-07 10:15:31 -0700401message OmciMsg {
402 fixed32 intf_id = 1;
403 fixed32 onu_id = 2;
404 bytes pkt = 3;
405}
406
407message OnuPacket {
408 fixed32 intf_id = 1;
409 fixed32 onu_id = 2;
410 fixed32 port_no = 4;
Abhilash Laxmeshwardfbb74d2019-07-23 08:03:08 -0400411 fixed32 gemport_id = 5;
Zack Williams52209662019-02-07 10:15:31 -0700412 bytes pkt = 3;
413}
414
415message UplinkPacket {
416 fixed32 intf_id = 1;
417 bytes pkt = 2;
418}
419
420message DeviceInfo {
421 string vendor = 1;
422 string model = 2;
423 string hardware_version = 3;
424 string firmware_version = 4;
425 string device_id = 16;
426 string device_serial_number = 17;
Gamze Abaka7a0d3942021-03-11 11:41:36 +0000427 bool previously_connected = 19; // used to indicate agent reconcile status
Zack Williams52209662019-02-07 10:15:31 -0700428
429 // Total number of pon intf ports on the device
430 fixed32 pon_ports = 12;
431
Elia Battiston3e451982022-02-23 09:43:26 +0100432 reserved 5 to 11, 13, 14;
433 // Not used anymore, this information is defined per-range only
434 // and is fully provided by DeviceResourceRanges
435 //
436 // string technology = 5;
437 // fixed32 onu_id_start = 6;
438 // fixed32 onu_id_end = 7;
439 // fixed32 alloc_id_start = 8;
440 // fixed32 alloc_id_end = 9;
441 // fixed32 gemport_id_start = 10;
442 // fixed32 gemport_id_end = 11;
443 // fixed32 flow_id_start = 13;
444 // fixed32 flow_id_end = 14;
Zack Williams52209662019-02-07 10:15:31 -0700445
446 message DeviceResourceRanges {
447
448 // List of 0 or more intf_ids that use the same technology and pools.
449 // If 0 intf_ids supplied, it implies ALL interfaces
450 repeated fixed32 intf_ids = 1;
451
452 // Technology profile for this pool
453 string technology = 2;
454
455 message Pool {
456 enum PoolType {
457 ONU_ID = 0;
458 ALLOC_ID = 1;
459 GEMPORT_ID = 2;
460 FLOW_ID = 3;
461 }
462
463 enum SharingType {
464 DEDICATED_PER_INTF = 0;
465 SHARED_BY_ALL_INTF_ALL_TECH = 1; // Shared across all interfaces in all technologies in all ranges
466 SHARED_BY_ALL_INTF_SAME_TECH = 2; // Shared across all interfaces of the same technology used in this range
467 }
468
469 PoolType type = 1;
470 SharingType sharing = 2;
471 fixed32 start = 3; // lower bound on IDs allocated from this pool
472 fixed32 end = 4; // upper bound on IDs allocated from this pool
473 }
474 repeated Pool pools = 3;
475 }
476 repeated DeviceResourceRanges ranges = 15;
477}
478
479message Classifier {
480 fixed32 o_tpid = 1;
481 fixed32 o_vid = 2;
482 fixed32 i_tpid = 3;
483 fixed32 i_vid = 4;
484 fixed32 o_pbits = 5;
485 fixed32 i_pbits = 6;
486 fixed32 eth_type = 7;
487 bytes dst_mac = 8;
488 bytes src_mac = 9;
489 fixed32 ip_proto = 10;
490 fixed32 dst_ip = 11;
491 fixed32 src_ip = 12;
492 fixed32 src_port = 13;
493 fixed32 dst_port = 14;
494 string pkt_tag_type = 15; // untagged, single_tag, double_tag
495}
496
497message ActionCmd {
498 bool add_outer_tag = 1;
499 bool remove_outer_tag = 2;
500 bool trap_to_host = 3;
Burak Gurdag402dd952019-12-10 20:31:11 +0000501 bool remark_outer_pbits = 4;
502 bool remark_inner_pbits = 5;
503 bool add_inner_tag = 6;
504 bool remove_inner_tag = 7;
505 bool translate_inner_tag = 8;
506 bool translate_outer_tag = 9;
Zack Williams52209662019-02-07 10:15:31 -0700507}
508
509message Action {
510 ActionCmd cmd = 1;
511 fixed32 o_vid = 2;
512 fixed32 o_pbits = 3;
513 fixed32 o_tpid = 4;
514 fixed32 i_vid = 5;
515 fixed32 i_pbits = 6;
516 fixed32 i_tpid = 7;
517}
518
519message Flow {
520 sfixed32 access_intf_id = 1;
521 sfixed32 onu_id = 2;
522 sfixed32 uni_id = 11;
Girish Gowdrab152d9f2020-08-17 11:37:50 -0700523
524 fixed64 flow_id = 3; // voltha flow-id. 0 is not a valid flow_id
525 fixed64 symmetric_flow_id = 18; // symmetric voltha flow-id, if applicable. All data path flows generally have a symmetric flow,
526 // but trap-to-controller flows do not have a symmetric flow
527 // Broadcom BAL requires that symmetric flows use the same BAL flow-id
528
529 string flow_type = 4; // upstream, downstream, broadcast, multicast
Zack Williams52209662019-02-07 10:15:31 -0700530 sfixed32 alloc_id = 10;
531 sfixed32 network_intf_id = 5;
Girish Gowdrab152d9f2020-08-17 11:37:50 -0700532 sfixed32 gemport_id = 6; // When 'replicate_flow' field is true, this field is obsolete.
Zack Williams52209662019-02-07 10:15:31 -0700533 Classifier classifier = 7;
534 Action action = 8;
535 sfixed32 priority = 9;
536 fixed64 cookie = 12; // must be provided for any flow with trap_to_host action. Returned in PacketIndication
537 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 +0000538 fixed32 group_id = 14;
Burak Gurdagce064352020-04-20 20:11:18 +0000539 fixed32 tech_profile_id = 15;
Girish Gowdrab152d9f2020-08-17 11:37:50 -0700540
541 bool replicate_flow = 16; // When this field is true, use pbitToGemPortID to know which p-bit needs to be classfied to which gem port.
542 map<fixed32, fixed32> pbit_to_gemport = 17; // Map of p-bit to gem port ID
Gamze Abakad8caefa2021-02-26 10:31:15 +0000543 map<fixed32, bool> gemport_to_aes = 19; // Map of gem port ID to aes encryption
Zack Williams52209662019-02-07 10:15:31 -0700544}
545
546message SerialNumber {
547 bytes vendor_id = 1;
548 bytes vendor_specific = 2;
549}
550
551message PortStatistics {
552 fixed32 intf_id = 1;
553 fixed64 rx_bytes = 2;
554 fixed64 rx_packets = 3;
555 fixed64 rx_ucast_packets = 4;
556 fixed64 rx_mcast_packets = 5;
557 fixed64 rx_bcast_packets = 6;
558 fixed64 rx_error_packets = 7;
Jason Huangc9243f12020-10-21 17:56:05 +0800559 fixed64 rx_frames = 17;
560 fixed64 rx_frames_64 = 18;
561 fixed64 rx_frames_65_127 = 19;
562 fixed64 rx_frames_128_255 = 20;
563 fixed64 rx_frames_256_511 = 21;
564 fixed64 rx_frames_512_1023 = 22;
565 fixed64 rx_frames_1024_1518 = 23;
566 fixed64 rx_frames_1519_2047 = 24;
567 fixed64 rx_frames_2048_4095 = 25;
568 fixed64 rx_frames_4096_9216 = 26;
569 fixed64 rx_frames_9217_16383 = 27;
570 fixed64 rx_crc_errors = 14;
571
Zack Williams52209662019-02-07 10:15:31 -0700572 fixed64 tx_bytes = 8;
573 fixed64 tx_packets = 9;
574 fixed64 tx_ucast_packets = 10;
575 fixed64 tx_mcast_packets = 11;
576 fixed64 tx_bcast_packets = 12;
577 fixed64 tx_error_packets = 13;
Jason Huangc9243f12020-10-21 17:56:05 +0800578 fixed64 tx_frames = 28;
579 fixed64 tx_frames_64 = 29;
580 fixed64 tx_frames_65_127 = 30;
581 fixed64 tx_frames_128_255 = 31;
582 fixed64 tx_frames_256_511 = 32;
583 fixed64 tx_frames_512_1023 = 33;
584 fixed64 tx_frames_1024_1518 = 34;
585 fixed64 tx_frames_1519_2047 = 35;
586 fixed64 tx_frames_2048_4095 = 36;
587 fixed64 tx_frames_4096_9216 = 37;
588 fixed64 tx_frames_9217_16383 = 38;
589
Zack Williams52209662019-02-07 10:15:31 -0700590 fixed64 bip_errors = 15;
591 fixed32 timestamp = 16;
592}
593
Gamze Abaka66fe96f2020-12-17 13:27:27 +0000594message OnuStatistics {
595 fixed32 intf_id = 1;
596 fixed32 onu_id = 2;
597 fixed64 positive_drift = 3;
598 fixed64 negative_drift = 4;
599 fixed64 delimiter_miss_detection = 5;
600 fixed64 bip_errors = 6;
601 fixed64 bip_units = 7;
602 fixed64 fec_corrected_symbols = 8;
603 fixed64 fec_codewords_corrected = 9;
604 fixed64 fec_codewords_uncorrectable = 10;
605 fixed64 fec_codewords = 11;
606 fixed64 fec_corrected_units = 12;
607 fixed64 xgem_key_errors = 13;
608 fixed64 xgem_loss = 14;
609 fixed64 rx_ploams_error = 15;
610 fixed64 rx_ploams_non_idle = 16;
611 fixed64 rx_omci = 17;
612 fixed64 rx_omci_packets_crc_error = 18;
613 fixed64 rx_bytes = 19;
614 fixed64 rx_packets = 20;
615 fixed64 tx_bytes = 21;
616 fixed64 tx_packets = 22;
617 fixed64 ber_reported = 23;
618 fixed64 lcdg_errors = 24;
619 fixed64 rdi_errors = 25;
620 fixed32 timestamp = 26;
621}
622
623message GemPortStatistics {
624 fixed32 intf_id = 1;
625 fixed32 gemport_id = 2;
626 fixed64 rx_packets = 3;
627 fixed64 rx_bytes = 4;
628 fixed64 tx_packets = 5;
629 fixed64 tx_bytes = 6;
630 fixed32 timestamp = 26;
631}
632
Zack Williams52209662019-02-07 10:15:31 -0700633message FlowStatistics {
634 fixed32 flow_id = 1;
635 fixed64 rx_bytes = 2;
636 fixed64 rx_packets = 3;
637 fixed64 tx_bytes = 8;
638 fixed64 tx_packets = 9;
639 fixed32 timestamp = 16;
640}
641
642message LosIndication {
643 fixed32 intf_id = 1;
644 string status = 2;
645}
646
647message DyingGaspIndication {
648 fixed32 intf_id = 1;
649 fixed32 onu_id = 2;
650 string status = 3;
651}
652
653message OnuAlarmIndication {
654 fixed32 intf_id = 1;
655 fixed32 onu_id = 2;
656 string los_status = 3;
657 string lob_status = 4;
658 string lopc_miss_status = 5;
659 string lopc_mic_error_status = 6;
Naga Manjunath0a734252019-11-21 19:00:23 +0530660 string lofi_status = 7;
661 string loami_status = 8;
Zack Williams52209662019-02-07 10:15:31 -0700662}
663
664message OnuStartupFailureIndication {
665 fixed32 intf_id = 1;
666 fixed32 onu_id = 2;
667 string status = 3;
668}
669
670message OnuSignalDegradeIndication {
671 fixed32 intf_id = 1;
672 fixed32 onu_id = 2;
673 string status = 3;
674 fixed32 inverse_bit_error_rate = 4;
675}
676
677message OnuDriftOfWindowIndication {
678 fixed32 intf_id = 1;
679 fixed32 onu_id = 2;
680 string status = 3;
681 fixed32 drift = 4;
682 fixed32 new_eqd = 5;
683}
684
685message OnuLossOfOmciChannelIndication {
686 fixed32 intf_id = 1;
687 fixed32 onu_id = 2;
688 string status = 3;
689}
690
691message OnuSignalsFailureIndication {
692 fixed32 intf_id = 1;
693 fixed32 onu_id = 2;
694 string status = 3;
695 fixed32 inverse_bit_error_rate = 4;
696}
697
698message OnuTransmissionInterferenceWarning {
699 fixed32 intf_id = 1;
700 fixed32 onu_id = 2;
701 string status = 3;
702 fixed32 drift = 4;
703}
704
705message OnuActivationFailureIndication {
706 fixed32 intf_id = 1;
707 fixed32 onu_id = 2;
Naga Manjunath0a734252019-11-21 19:00:23 +0530708 fixed32 fail_reason = 3;
709}
710
711message OnuLossOfKeySyncFailureIndication {
712 fixed32 intf_id = 1;
713 fixed32 onu_id = 2;
714 string status = 3;
715}
716
Girish Gowdra5192ea82020-05-06 20:49:11 -0700717message RdiErrorIndication {
718 fixed64 rdi_error_count = 1; // RDI Error count
719 string status = 2; // on/off based on configured reporting condition
720}
721
Naga Manjunath0a734252019-11-21 19:00:23 +0530722message OnuItuPonStatsIndication{
723 fixed32 intf_id = 1;
724 fixed32 onu_id = 2;
Girish Gowdra5192ea82020-05-06 20:49:11 -0700725 oneof stats {
726 RdiErrorIndication rdi_error_ind = 3;
727 // add more here
728 }
Zack Williams52209662019-02-07 10:15:31 -0700729}
730
731message OnuProcessingErrorIndication {
732 fixed32 intf_id = 1;
733 fixed32 onu_id = 2;
734}
735
Devmalya Paulea6eb472020-02-04 20:41:01 -0500736message OnuDeactivationFailureIndication {
737 fixed32 intf_id = 1;
738 fixed32 onu_id = 2;
Girish Gowdra5192ea82020-05-06 20:49:11 -0700739 string status = 3;
Devmalya Paulea6eb472020-02-04 20:41:01 -0500740}
741
Jason Huang55ee29d2020-03-11 23:43:29 +0800742message OnuRemoteDefectIndication {
Devmalya Paulb0c12472020-02-18 20:08:53 -0500743 fixed32 intf_id = 1;
744 fixed32 onu_id = 2;
Jason Huang55ee29d2020-03-11 23:43:29 +0800745 fixed64 rdi_errors = 3;
Devmalya Paulb0c12472020-02-18 20:08:53 -0500746}
747
Devmalya Paul82957962020-03-01 18:49:37 -0500748message OnuLossOfGEMChannelDelineationIndication {
749 fixed32 intf_id = 1;
750 fixed32 onu_id = 2;
751 string status = 3;
752 fixed32 delineation_errors = 4;
753}
754
755message OnuPhysicalEquipmentErrorIndication {
756 fixed32 intf_id = 1;
757 fixed32 onu_id = 2;
758 string status = 3;
759}
760
761message OnuLossOfAcknowledgementIndication {
762 fixed32 intf_id = 1;
763 fixed32 onu_id = 2;
764 string status = 3;
765}
766
Devmalya Paul342bf9d2020-03-19 02:42:56 -0400767message OnuDifferentialReachExceededIndication {
768 fixed32 intf_id = 1;
769 fixed32 onu_id = 2;
770 string status = 3;
771 fixed32 distance = 4;
772}
773
Burak Gurdag402dd952019-12-10 20:31:11 +0000774message GroupMember {
775 enum InterfaceType {
776 PON = 0;
777 EPON_1G_PATH = 1;
778 EPON_10G_PATH = 2;
779 }
780 uint32 interface_id = 1;
781 InterfaceType interface_type = 2;
782 uint32 gem_port_id = 3;
783 uint32 priority = 4; // Priority (and also the ID) of the default fixed queue for the multicast traffic.
784 // This queue is attached to the default PON port scheduler.
785}
786
787message Group {
788 enum GroupMembersCommand {
789 ADD_MEMBERS = 0;
790 REMOVE_MEMBERS = 1;
791 SET_MEMBERS = 2;
792 }
793
794 uint32 group_id = 1;
795 GroupMembersCommand command = 2;
796 repeated GroupMember members = 3;
797 Action action = 4;
798}
799
Dinesh Belwalkared6da5e2020-02-25 11:23:57 -0800800message ValueParam {
801 Onu onu = 1;
khenaidoo4c6543e2021-10-19 17:25:58 -0400802 extension.ValueType.Type value = 2;
Dinesh Belwalkared6da5e2020-02-25 11:23:57 -0800803}
Burak Gurdag402dd952019-12-10 20:31:11 +0000804
Orhan Kupusogluda19b452021-05-12 12:19:16 +0000805message PonRxPowerData {
806 enum RssiMeasurementFailReason {
807 FAIL_REASON_NONE = 0;
808 FAIL_REASON_NO_DELIMITER = 1;
809 FAIL_REASON_NO_ACCESS = 2;
810 }
Burak Gurdag402dd952019-12-10 20:31:11 +0000811
Orhan Kupusogluda19b452021-05-12 12:19:16 +0000812 fixed32 intf_id = 1;
813 fixed32 onu_id = 2;
814 string status = 3;
815 RssiMeasurementFailReason fail_reason = 4;
816 double rx_power_mean_dbm = 5;
817}
818
Abhilash Laxmeshward95e1992023-03-13 18:52:05 +0530819enum AlarmState {
820 OFF = 0;
821 ON = 1;
822}
823
824/*
825 * contains the onu id, state of the onu and the information about the alarms on the onu.
826 * As of now only few alarms are added, any further information needed can be added to the structure.
827 */
Abhilash Laxmeshwarba79e802023-03-30 15:28:20 +0530828message OnuInfo {
Abhilash Laxmeshward95e1992023-03-13 18:52:05 +0530829 fixed32 onu_id = 1;
Abhilash Laxmeshwarba79e802023-03-30 15:28:20 +0530830 enum OnuState {
831 /*
832 * There are other states in BAL for ONU, which voltha is not interested as of now.
833 * UNKNOWN is to be filled for the rest of the states other than NOT_CONFIGURED/ACTIVE/INACTIVE/DISABLED
834 */
835 UNKNOWN = 0;
836 NOT_CONFIGURED = 1;
837 ACTIVE = 2;
838 INACTIVE = 3;
839 DISABLED = 4;
Abhilash Laxmeshward95e1992023-03-13 18:52:05 +0530840 }
Abhilash Laxmeshwarba79e802023-03-30 15:28:20 +0530841 OnuState state = 2;
Abhilash Laxmeshward95e1992023-03-13 18:52:05 +0530842 AlarmState losi = 3;
843 AlarmState lofi = 4;
Abhilash Laxmeshwarba79e802023-03-30 15:28:20 +0530844 AlarmState loami = 5;
Abhilash Laxmeshward95e1992023-03-13 18:52:05 +0530845}
846
847/*
Abhilash Laxmeshwarba79e802023-03-30 15:28:20 +0530848 * IntfInfo has the interface Id and if there are any alarms active on that interface.
Abhilash Laxmeshward95e1992023-03-13 18:52:05 +0530849 * Any further information needed from the interface object can be added to the structure.
850 */
Abhilash Laxmeshwarba79e802023-03-30 15:28:20 +0530851message PonIntfInfo {
Abhilash Laxmeshward95e1992023-03-13 18:52:05 +0530852 fixed32 intf_id = 1;
Abhilash Laxmeshwarba79e802023-03-30 15:28:20 +0530853 enum PonIntfState {
854 UNKNOWN = 0;
855 ACTIVE_WORKING = 1;
856 ACTIVE_STANDBY = 2;
857 INACTIVE = 3;
858 DISABLED = 4;
859 }
860 PonIntfState state = 3;
861 AlarmState los = 4;
Abhilash Laxmeshward95e1992023-03-13 18:52:05 +0530862}
863
Orhan Kupusogluda19b452021-05-12 12:19:16 +0000864message Empty {}