blob: 40126f953c99e15a51ef7e472ce9518a386f37cf [file] [log] [blame]
Elia Battiston4750d3c2022-07-14 13:24:56 +00001module bbf-xpon-types {
2 yang-version 1.1;
3 namespace "urn:bbf:yang:bbf-xpon-types";
4 prefix bbf-xpon-types;
5
6 import ietf-inet-types {
7 prefix inet;
8 }
9
10 organization
11 "Broadband Forum <https://www.broadband-forum.org>
12 Fiber Access Networks Work Area";
13 contact
14 "Comments or questions about this Broadband Forum YANG module
15 should be directed to <mailto:help@broadband-forum.org>.
16
17 Editor: Joey Boyd, ADTRAN
18
19 Editor: Samuel Chen, Broadcom
20
21 Editor: Robert Peschi, Nokia
22
23 WA Director: Marta Seda, Calix
24
25 WA Director: Lin Wei, Huawei";
26 description
27 "This module contains a collection of YANG definitions which
28 defines common types used in the xPON YANG models.
29
30 Copyright (c) 2018, Broadband Forum
31
32 Redistribution and use in source and binary forms, with or
33 without modification, are permitted provided that the following
34 conditions are met:
35
36 1. Redistributions of source code must retain the above copyright
37 notice, this list of conditions and the following disclaimer.
38
39 2. Redistributions in binary form must reproduce the above
40 copyright notice, this list of conditions and the following
41 disclaimer in the documentation and/or other materials
42 provided with the distribution.
43
44 3. Neither the name of the copyright holder nor the names of its
45 contributors may be used to endorse or promote products
46 derived from this software without specific prior written
47 permission.
48
49 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND
50 CONTRIBUTORS \"AS IS\" AND ANY EXPRESS OR IMPLIED WARRANTIES,
51 INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
52 MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
53 DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
54 CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
55 SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
56 NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
57 LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
58 CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
59 STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
60 ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
61 ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
62
63 The above license is used as a license under copyright only.
64 Please reference the Forum IPR Policy for patent licensing terms
65 <https://www.broadband-forum.org/ipr-policy>.
66
67 Any moral rights which are necessary to exercise under the above
68 license grant are also deemed granted under this license.
69
70 This version of this YANG module is part of TR-385; see
71 the TR itself for full legal notices.";
72
73 revision 2019-02-25 {
74 description
75 "Initial revision.
76 * Approval Date: 2019-02-25.
77 * Publication Date: 2019-02-25.";
78 reference
79 "TR-385: ITU-T PON YANG Modules
80 <https://www.broadband-forum.org/technical/download/
81 TR-385.pdf>";
82 }
83
84 identity type-b-state-base {
85 description
86 "This identity is used as the base for possible
87 channel-terminations states for type B protection.";
88 }
89
90 identity active {
91 base type-b-state-base;
92 description
93 "This identity is used to denote active state in type B
94 protection.";
95 }
96
97 identity standby {
98 base type-b-state-base;
99 description
100 "This identity is used to denote standby state in type B
101 protection.";
102 }
103
104 identity not-part-of-type-b {
105 base type-b-state-base;
106 description
107 "This identity is used to denote that the object is not part
108 of a type B protection scheme. This is for instance the
109 case when a channel-termination does not (yet) refer
110 to a channel-pair.";
111 }
112
113 identity location-base {
114 description
115 "This identity is used as the possible locations of an
116 object.";
117 }
118
119 identity inside-olt {
120 base location-base;
121 description
122 "This identity is used to denote a location physically inside
123 the OLT chassis.";
124 }
125
126 identity outside-olt {
127 base location-base;
128 description
129 "This identity is used to denote a location physically outside
130 the OLT chassis.";
131 }
132
133 identity channel-pair-type-base {
134 description
135 "This identity is used to qualify the possible types of a
136 channel-pair.";
137 }
138
139 identity ngpon2-twdm {
140 base channel-pair-type-base;
141 description
142 "This identity is used to denote a TWDM NG-PON2 channel-pair,
143 per ITU-T G.989.3.";
144 }
145
146 identity ngpon2-ptp {
147 base channel-pair-type-base;
148 description
149 "This identity is used to denote a PtP NG-PON2 channel-pair, per
150 ITU-T G.989.3.";
151 }
152
153 identity xgs {
154 base channel-pair-type-base;
155 description
156 "This identity is used to denote an XGS-PON channel-pair,
157 per ITU-T G.9807.1.";
158 }
159
160 identity xgpon {
161 base channel-pair-type-base;
162 description
163 "This identity is used to denote an XG-PON channel-pair,
164 per ITU-T G.987.3.";
165 }
166
167 identity gpon {
168 base channel-pair-type-base;
169 description
170 "This identity is used to denote an G-PON channel-pair,
171 per ITU-T G.984.3.";
172 }
173
174 identity channel-pair-line-rate-profile-base {
175 description
176 "This identity is used to define the possible combinations
177 of downstream and upstream line-rates for an NG-PON2
178 channel-pair.";
179 }
180
181 identity unplanned-cp-line-rate {
182 base channel-pair-line-rate-profile-base;
183 description
184 "This identity is used to denote an NG-PON2 channel-pair with
185 yet undefined downstream and upstream line rates.";
186 }
187
188 identity down-10-up-10 {
189 base channel-pair-line-rate-profile-base;
190 description
191 "This identity is used to denote an NG-PON2 channel-pair with
192 downstream 10Gbps and upstream 10Gbps line rates.";
193 }
194
195 identity down-10-up-2.5 {
196 base channel-pair-line-rate-profile-base;
197 description
198 "This identity is used to denote an NG-PON2 channel-pair with
199 downstream 10Gbps and upstream 2.5Gbps line rates.";
200 }
201
202 identity down-2.5-up-2.5 {
203 base channel-pair-line-rate-profile-base;
204 description
205 "This identity is used to denote an NG-PON2 channel-pair with
206 downstream 2.5Gbps and upstream 2.5Gbps line rates.";
207 }
208
209 identity tcp-connection-state-base {
210 description
211 "This identity is used to denote the possible states of
212 a TCP connection.";
213 }
214
215 identity established {
216 base tcp-connection-state-base;
217 description
218 "This identity is used to reflect that the TCP connection is
219 established.";
220 }
221
222 identity not-established {
223 base tcp-connection-state-base;
224 description
225 "This identity is used to reflect that the TCP connection is
226 not established.";
227 }
228
229 identity unknown {
230 base tcp-connection-state-base;
231 description
232 "This identity is used to reflect that the TCP connection state
233 is not known.";
234 }
235
236 identity action-request-status {
237 description
238 "This identity is used to denote the status following the
239 reception of a YANG action.";
240 }
241
242 identity request-being-processed {
243 base action-request-status;
244 description
245 "This identity is used to denote that the OLT has received
246 the action request and is handling it.";
247 }
248
249 identity request-rejected {
250 base action-request-status;
251 description
252 "This identity is used to denote that the OLT has rejected
253 the action request and will not perform anything further
254 about it.";
255 }
256
257 typedef string-hex14 {
258 type string {
259 pattern '[a-fA-F0-9]{14}';
260 }
261 description
262 "A string representing 7 hexadecimal octets expressed in
263 ASCII.";
264 }
265
266 typedef pon-id-display-type {
267 type union {
268 type uint32;
269 type string-hex14;
270 }
271 description
272 "A type meant for the different formats of the PON-ID for the
273 various channel-pair types. The 'unint' is meant for NG-PON2,
274 XGS-PON and XG-PON and the 'string7only' is meant for G-PON.";
275 }
276
277 typedef composite-channel-id-type {
278 type union {
279 type uint8 {
280 range "0..7";
281 }
282 type enumeration {
283 enum "xgs" {
284 description
285 "To be used in case of XGS-PON, rather than 0.";
286 }
287 }
288 }
289 description
290 "A composite type strictly meant for leaves reflecting the
291 already allocated downstream or upstream channel-id on a
292 channel-group.
293 Such leaves are used to prevent conflicts when allocating
294 a channel-pair to a channel-group. For NG-PON2, the applicable
295 values are in [0..7], for XGS-PON a dedicated value 'xgs'
296 is used rather than '0' to prevent ambiguity between this and
297 the valid value '0' for NG-PON2.";
298 }
299
300 typedef composite-downstream-wavelength-type {
301 type union {
302 type uint32 {
303 range "0 | 156000..161000";
304 }
305 type enumeration {
306 enum "xgs" {
307 description
308 "To be used in case of XGS-PON.";
309 }
310 enum "xgpon" {
311 description
312 "To be used in case of XG-PON.";
313 }
314 enum "gpon" {
315 description
316 "To be used in case of G-PON.";
317 }
318 }
319 }
320 description
321 "A composite type strictly meant for leaves reflecting the
322 already allocated downstream or upstream channel-id on a
323 channel-group.
324 Such leaves are used to prevent conflicts when allocating a
325 channel-pair to a channel-group. For NG-PON2, the applicable
326 values are in [0..8], for XGS-PON a dedicated value 'xgs'
327 is applicable rather than value '0': this is not to a priori
328 forbid in yang model the coexistence of XGS-PON with NG-PON2
329 using channel-id=0.";
330 }
331
332 typedef auth-method-type {
333 type enumeration {
334 enum "serial-number" {
335 description
336 "Authentication based on ONU serial number.";
337 reference
338 "ITU-T G.984.3 clause VI.1";
339 }
340 enum "loid" {
341 description
342 "Authentication based on the Logical ONU ID (LOID).";
343 reference
344 "ITU-T G.988 clause 9.1.1";
345 }
346 enum "registration-id" {
347 description
348 "Authentication based on ONU registration ID.";
349 reference
350 "ITU-T G.984.3 clause VI.2";
351 }
352 enum "omci" {
353 description
354 "Authentication by use of the enhanced security control
355 managed entity (ME) over OMCI.";
356 reference
357 "ITU-T G.987.3 Annex C";
358 }
359 enum "dot1x" {
360 description
361 "Authentication according to IEEE 802.1x.";
362 reference
363 "ITU-T G.987.3 Annex D";
364 }
365 }
366 description
367 "Method for authenticating an ONU.";
368 }
369
370 typedef raman-mitigation-type {
371 type enumeration {
372 enum "raman-none" {
373 description
374 "No Raman mitigation is performed.";
375 }
376 enum "raman-8b10b" {
377 description
378 "For Raman mitigation, the 8B10B sublayer is introduced
379 between the downstream NG-PON2 physical interface (PHY)
380 adaptation interface and the optical interface.";
381 reference
382 "ITU-T G.989.2 clause IX.1";
383 }
384 enum "raman-miller" {
385 description
386 "For Raman mitigation, Miller code is used.";
387 reference
388 "ITU-T G.989.2 clause IX.2";
389 }
390 }
391 description
392 "NG-PON2 Raman mitigation coding schemes when using RF video
393 overlay.";
394 reference
395 "ITU-T G.989.2 Appendix IX";
396 }
397
398 typedef ip-address-or-unresolved {
399 type union {
400 type inet:ip-address;
401 type enumeration {
402 enum "unresolved" {
403 description
404 "To be used when the URL cannot be resolved into an
405 IP address.";
406 }
407 }
408 }
409 description
410 "A type meant for a leaf which is either an IP address or
411 reflects that no IP address is available.";
412 }
413
414 typedef onu-id {
415 type uint32 {
416 range "0..1020";
417 }
418 description
419 "A type meant for ONU-IDs.";
420 }
421
422 typedef onu-serial-number {
423 type string {
424 pattern '[a-zA-Z]{4}[0-9a-fA-F]{8}';
425 }
426 description
427 "A type meant for the serial number of an ONU.";
428 }
429
430}