1 module o-ran-interfaces {
3 namespace "urn:o-ran:interfaces:1.0";
7 import ietf-inet-types {
15 import ietf-interfaces {
23 import ietf-hardware {
27 import ietf-yang-types {
31 import iana-hardware {
35 organization "O-RAN Alliance";
41 "This module defines the YANG definitions for managng the O-RAN
44 Copyright 2020 the O-RAN Alliance.
46 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 'AS IS'
47 AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
48 IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
49 ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
50 LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
51 CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
52 SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
53 INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
54 CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
55 ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
56 POSSIBILITY OF SUCH DAMAGE.
58 Redistribution and use in source and binary forms, with or without
59 modification, are permitted provided that the following conditions are met:
61 * Redistributions of source code must retain the above copyright notice,
62 this list of conditions and the above disclaimer.
63 * Redistributions in binary form must reproduce the above copyright notice,
64 this list of conditions and the above disclaimer in the documentation
65 and/or other materials provided with the distribution.
66 * Neither the Members of the O-RAN Alliance nor the names of its
67 contributors may be used to endorse or promote products derived from
68 this software without specific prior written permission.";
70 revision "2020-12-10" {
74 1) new functionality to describe over subscribed resources";
76 reference "ORAN-WG4.M.0-v05.00";
79 revision "2020-04-17" {
83 1) updated descriptions to clarify operation when vlan-tagging is false";
85 reference "ORAN-WG4.M.0-v03.00";
87 revision "2019-07-03" {
91 1) increasing max elements for user plane DSCP markings to 64
92 2) re-organizing layout to facilitate cross-WG adoption, whilst ensuring
93 nodes are syntactically and semantically equivalent";
95 reference "ORAN-WG4.M.0-v01.00";
98 revision "2019-02-04" {
102 1) imported model from xRAN
103 2) changed namespace and reference from xran to o-ran";
105 reference "ORAN-WG4.M.0-v01.00";
108 feature UDPIP-BASED-CU-PLANE {
110 "This feature indicates that the RU supports the UDP/IP based transport
114 feature ALIASMAC-BASED-CU-PLANE {
116 "This feature indicates that the RU supports the alias MAC address
117 based transport for the CU plane.";
125 "Priority Code Point. PCP is a 3-bit field that refers to the
126 class of service applied to a VLAN tagged frame. The
127 field specifies a priority value between 0 and 7, these values
128 can be used by quality of service (QoS) to prioritize
129 different classes of traffic.";
131 "IEEE 802.1Q-2014: Virtual Bridged Local Area Networks";
134 grouping cos-marking {
136 "Configuration data for CU Plane ethernet CoS marking.
137 This grouping is only applicable to an interface when vlan-tagging is
138 set to TRUE for that interface. In other cases, it may be ignored.";
139 container class-of-service {
142 leaf u-plane-marking {
146 "Marking used for default u-plane flows.
147 7 represents highest priority for u-plane marking";
149 leaf c-plane-marking {
152 description "7 represents highest priority for c-plane marking";
154 leaf m-plane-marking {
157 description "2 represents highest excellent effort for m-plane marking";
159 leaf s-plane-marking {
162 description "7 represents highest priority for s-plane marking";
167 description "1 represents best effort for other marking";
169 list enhanced-uplane-markings{
170 key "up-marking-name";
173 "list of mappings for enhanced (non-default) u-plane markings";
174 leaf up-marking-name {
176 description "The name of the marking";
178 leaf enhanced-marking {
180 description "the enhanced u-plane marking";
186 grouping dscp-marking {
188 "Configuration data for CU Plane DSCP marking";
189 container diffserv-markings {
191 "DSCP Configuration";
192 leaf u-plane-marking {
196 "Marking used for default u-plane flows.
197 46 represents expedited forwarding";
199 leaf c-plane-marking {
202 description "46 represents expedited forwarding";
204 leaf s-plane-marking {
207 description "46 represents expedited forwarding";
212 description "0 represents best effort forwarding";
214 list enhanced-uplane-markings{
218 "list of mappings for enhanced (non-default) u-plane markings";
219 leaf up-marking-name {
221 description "The name of the marking";
223 leaf enhanced-marking {
225 description "the enhanced u-plane marking";
231 // Cross Working Group Augmentations Follow
233 // Cross Working Group augmentations for basic Ethernet leafs
235 augment "/if:interfaces/if:interface" {
236 when "if:type = 'ianaift:ethernetCsmacd'" {
237 description "Applies to Ethernet interfaces";
240 "Augment the interface model with parameters for
241 base Ethernet interface";
250 "The maximum size of layer 2 frames that may be transmitted
251 or received on the interface (excluding any FCS overhead).
252 For Ethernet interfaces it also excludes the
253 4-8 byte overhead of any known (i.e. explicitly matched by
254 a child sub-interface) 801.1Q VLAN tags.";
260 "Indicates if VLAN tagging is used.
261 Default true is used to enable equipment to autonomously discover that
262 it is connected to a trunk port.
264 This may be set to false, for example, when the O-RU is directly
265 connected to the O-DU. In such cases, native Ethernet frames may be
266 used across the O-RAN interface, i.e., any PCP markings defined
267 in the cos-markings grouping are NOT used by the O-RU and any default
268 value or configured value using those leafs may be ignored by the O-RAN
273 // interface-grouping insert - begin;
275 leaf-list interface-groups-id {
277 path "/if:interfaces/o-ran-int:interface-grouping/o-ran-int:interfaces-groups/o-ran-int:interface-group-id";
281 "an optional leaf used when the sustained rate able to be supported by an interface
282 is less than nominal bit rate indicated by o-ran-transceiver.yang
284 Identifies interface grouping particular physical hardware MAC address belongs to.";
287 // interface-grouping insert - end;
291 // Cross Working Group augmentation for l2vlan interfaces for VLAN definition
293 augment "/if:interfaces/if:interface" {
294 when "if:type = 'ianaift:l2vlan'";
295 description "augments for VLAN definition";
296 leaf base-interface {
297 type if:interface-ref;
298 must "/if:interfaces/if:interface[if:name = current()]"
299 + "/o-ran-int:vlan-tagging = 'true'" {
301 "The base interface must have VLAN tagging enabled.";
304 "The base interface for the VLAN sub-interafce.";
315 // Cross Working Group augmention for both ethernetCsmacd and l2vlan interfaces
317 augment "/if:interfaces/if:interface" {
318 when "(if:type = 'ianaift:ethernetCsmacd') or
319 (if:type = 'ianaift:l2vlan')" {
320 description "Applies to ethernetCsmacd and l2vlan interfaces";
323 "Augment the interface model with parameters for all
324 both ethernetCsmacd and l2vlan interfaces.";
326 type yang:date-and-time;
329 "Timestamp of the last time the interface counters were
334 // Cross Working Group augmention to ietf-ip covering DSCP for M-Plane
336 augment "/if:interfaces/if:interface/ip:ipv4" {
337 description "augments for IPv4 based M-Plane transport";
338 leaf m-plane-marking {
341 description "18 represents AF21 or 'immediate traffic'";
344 augment "/if:interfaces/if:interface/ip:ipv6" {
345 description "augments for IPv6 based M-Plane transport";
346 leaf m-plane-marking {
349 description "18 represents AF21 or 'immediate traffic'";
353 // WG4 Specific Augmentations Follow
355 // WG4 Augmentation for basic Ethernet leafs
357 augment "/if:interfaces/if:interface" {
358 if-feature ALIASMAC-BASED-CU-PLANE;
359 when "if:type = 'ianaift:ethernetCsmacd'" {
361 "Applies to WG4 Ethernet interfaces for alias MAC based CU-Plane";
364 "Augment the interface model with parameters for
365 base Ethernet interface";
367 leaf-list alias-macs {
368 type yang:mac-address;
371 "Augments interfaces with range of alias MAC addresses.";
376 // WG4 Augmention for both ethernetCsmacd and l2vlan interfaces
378 augment "/if:interfaces/if:interface" {
379 when "(if:type = 'ianaift:ethernetCsmacd') or
380 (if:type = 'ianaift:l2vlan')" {
381 description "Applies to ethernetCsmacd and l2vlan interfaces";
384 "Augment the interface model with parameters for all
385 both ethernetCsmacd and l2vlan interfaces.";
387 type yang:mac-address;
390 "The MAC address of the interface.";
393 container port-reference {
395 "a port reference used by other O-RAN modules";
398 path '/hw:hardware/hw:component/hw:name';
400 must "derived-from-or-self(deref(current())/../hw:class, 'ianahw:port')";
401 // TAKE NOTE - depending on version of pyang, this may generate various
402 // warnings, e.g., warning: XPath for "port-name" does not exist
404 "O-RAN interfaces use a reference to a physical port component.
406 In this case, the component name referenced must be of class type
407 port, i.e., when /hw:hardware/hw:component/hw:class is derived from
413 "A number allocated by the server which identifies a port.
414 Port number value is 0 to N-1 where N is number of ports
417 This value is fixed for the lifetime of the equipment, i.e., cannot be
418 changed during equipment reboots.";
423 // WG4 specific augmention to ietf-ip covering DSCP for CUS Plane
425 augment "/if:interfaces/if:interface/ip:ipv4" {
426 if-feature UDPIP-BASED-CU-PLANE;
427 description "augments for IPv4 based CUS transport";
430 augment "/if:interfaces/if:interface/ip:ipv6" {
431 if-feature UDPIP-BASED-CU-PLANE;
432 description "augments for IPv6 based CUS transport";
436 // Other Working Group Specific Augmentations Follow Here
438 // interface-grouping insert - begin;
440 augment "/if:interfaces" {
441 description "augments interfaces for groupings of physical hardware addresses that can be used to group Ethernet ports";
443 container interface-grouping {
446 "indicates maximum sustained throughput of an O-RU is less than the combined bandwidth of all physical ports";
451 "A container used by an O-RU where the maximum sustained throughput
452 of an O-RU is less than the combined bandwidth of all physical ports";
454 list interfaces-groups {
455 key interface-group-id;
456 description "List of interface groups.";
458 leaf interface-group-id {
460 description "interface group identifier.";
463 leaf max-sustainable-ingress-bandwidth {
467 "Maximum sustainable ingress bandwidth the interface group can handle. The sustainable bandwidth is calculated
468 over one radio frame.
470 The peak ingress bandwidth may exceed the sustainable bandwidth for periods shorter than a radio frame period.";
473 leaf max-sustainable-egress-bandwidth {
477 "Maximum sustainable egress bandwidth the interface group can handle. The sustainable bandwidth is calculated
478 over one radio frame.";
483 // interface-grouping insert - end;
486 rpc reset-interface-counters {
488 "Management plane triggered restart of the interface counters.";