Update YANG models for OpenFronthaul M-Plane.
[sim/o1-interface.git] / ntsimulator / deploy / o-ran-ru-fh / yang / ieee802-types.yang
1 module ieee802-types {
2   namespace urn:ieee:std:802.1Q:yang:ieee802-types;
3   prefix ieee;
4   organization
5     "IEEE 802.1 Working Group";
6   contact
7     "WG-URL: http://ieee802.org/1/
8     WG-EMail: stds-802-1-l@ieee.org
9
10     Contact: IEEE 802.1 Working Group Chair
11     Postal: C/O IEEE 802.1 Working Group
12             IEEE Standards Association
13             445 Hoes Lane
14             Piscataway, NJ 08854
15             USA
16
17     E-mail: stds-802-1-chairs@ieee.org";
18   description
19     "This module contains a collection of generally useful derived
20     data types for IEEE YANG models.";
21   revision 2020-06-04 {
22     description
23       "Published as part of IEEE Std 802.1Qcx-2020.
24       Second version.";
25     reference
26       "IEEE Std 802.1Qcx-2020, Bridges and Bridged Networks -
27       YANG Data Model for Connectivity Fault Management.";
28   }
29   revision 2018-03-07 {
30     description
31       "Published as part of IEEE Std 802.1Q-2018.
32       Initial version.";
33     reference
34       "IEEE Std 802.1Q-2018, Bridges and Bridged Networks.";
35   }
36
37   typedef mac-address {
38     type string {
39       pattern "[0-9a-fA-F]{2}(-[0-9a-fA-F]{2}){5}";
40     }
41     description
42       "The mac-address type represents a MAC address in the canonical
43       format and hexadecimal format specified by IEEE Std 802. The
44       hexidecimal representation uses uppercase characters.";
45     reference
46       "3.1 of IEEE Std 802-2014
47       8.1 of IEEE Std 802-2014";
48   }
49
50   typedef chassis-id-subtype-type {
51     type enumeration {
52       enum chassis-component {
53         value 1;
54         description
55           "Represents a chassis identifier based on the value of
56           entPhysicalAlias object (defined in IETF RFC 2737) for a
57           chassis component (i.e., an entPhysicalClass value of
58           chassis(3))";
59       }
60       enum interface-alias {
61         value 2;
62         description
63           "Represents a chassis identifier based on the value of
64           ifAlias object (defined in IETF RFC 2863) for an interface
65           on the containing chassis.";
66       }
67       enum port-component {
68         value 3;
69         description
70           "Represents a chassis identifier based on the value of
71           entPhysicalAlias object (defined in IETF RFC 2737) for a
72           port or backplane component (i.e., entPhysicalClass value of
73           port(10) or backplane(4)), within the containing chassis.";
74       }
75       enum mac-address {
76         value 4;
77         description
78           "Represents a chassis identifier based on the value of a
79           unicast source address (encoded in network byte order and
80           IEEE 802.3 canonical bit order), of a port on the containing
81           chassis as defined in IEEE Std 802-2001.";
82       }
83       enum network-address {
84         value 5;
85         description
86           "Represents a chassis identifier based on a network address,
87           associated with a particular chassis.  The encoded address is
88           actually composed of two fields.  The first field is a
89           single octet, representing the IANA AddressFamilyNumbers
90           value for the specific address type, and the second field is
91           the network address value.";
92       }
93       enum interface-name {
94         value 6;
95         description
96           "Represents a chassis identifier based on the value of
97           ifName object (defined in IETF RFC 2863) for an interface
98           on the containing chassis.";
99       }
100       enum local {
101         value 7;
102         description
103           "Represents a chassis identifier based on a locally defined
104           value.";
105       }
106     }
107     description
108       "The source of a chassis identifier.";
109     reference
110       "LLDP MIB 20050506";
111   }
112
113   typedef chassis-id-type {
114     type string {
115       length "1..255";
116     }
117     description
118       "The format of a chassis identifier string. Objects of this type
119       are always used with an associated lldp-chassis-is-subtype
120       object, which identifies the format of the particular
121       lldp-chassis-id object instance.
122
123       If the associated lldp-chassis-id-subtype object has a value of
124       chassis-component, then the octet string identifies
125       a particular instance of the entPhysicalAlias object
126       (defined in IETF RFC 2737) for a chassis component (i.e.,
127       an entPhysicalClass value of chassis(3)).
128
129       If the associated lldp-chassis-id-subtype object has a value
130       of interface-alias, then the octet string identifies
131       a particular instance of the ifAlias object (defined in
132       IETF RFC 2863) for an interface on the containing chassis.
133       If the particular ifAlias object does not contain any values,
134       another chassis identifier type should be used.
135
136       If the associated lldp-chassis-id-subtype object has a value
137       of port-component, then the octet string identifies a
138       particular instance of the entPhysicalAlias object (defined
139       in IETF RFC 2737) for a port or backplane component within
140       the containing chassis.
141
142       If the associated lldp-chassis-id-subtype object has a value of
143       mac-address, then this string identifies a particular
144       unicast source address (encoded in network byte order and
145       IEEE 802.3 canonical bit order), of a port on the containing
146       chassis as defined in IEEE Std 802-2001.
147
148       If the associated lldp-chassis-id-subtype object has a value of
149       network-address, then this string identifies a particular
150       network address, encoded in network byte order, associated
151       with one or more ports on the containing chassis.  The first
152       octet contains the IANA Address Family Numbers enumeration
153       value for the specific address type, and octets 2 through
154       N contain the network address value in network byte order.
155
156       If the associated lldp-chassis-id-subtype object has a value
157       of interface-name, then the octet string identifies
158       a particular instance of the ifName object (defined in
159       IETF RFC 2863) for an interface on the containing chassis.
160       If the particular ifName object does not contain any values,
161       another chassis identifier type should be used.
162
163       If the associated lldp-chassis-id-subtype object has a value of
164       local, then this string identifies a locally assigned
165       Chassis ID.";
166     reference
167       "LLDP MIB 20050506";
168   }
169
170   typedef port-id-subtype-type {
171     type enumeration {
172       enum interface-alias {
173         value 1;
174         description
175           "Represents a port identifier based on the ifAlias
176           MIB object, defined in IETF RFC 2863.";
177       }
178       enum port-component {
179         value 2;
180         description
181           "Represents a port identifier based on the value of
182           entPhysicalAlias (defined in IETF RFC 2737) for a port
183           component (i.e., entPhysicalClass value of port(10)),
184           within the containing chassis.";
185       }
186       enum mac-address {
187         value 3;
188         description
189           "Represents a port identifier based on a unicast source
190           address (encoded in network byte order and IEEE 802.3
191           canonical bit order), which has been detected by the agent
192           and associated with a particular port (IEEE Std 802-2001).";
193       }
194       enum network-address {
195         value 4;
196         description
197           "Represents a port identifier based on a network address,
198           detected by the agent and associated with a particular
199           port.";
200       }
201       enum interface-name {
202         value 5;
203         description
204           "Represents a port identifier based on the ifName MIB object,
205           defined in IETF RFC 2863.";
206       }
207       enum agent-circuit-id {
208         value 6;
209         description
210           "Represents a port identifier based on the agent-local
211           identifier of the circuit (defined in RFC 3046), detected by
212           the agent and associated with a particular port.";
213       }
214       enum local {
215         value 7;
216         description
217           "Represents a port identifier based on a value locally
218           assigned.";
219       }
220     }
221     description
222       "The source of a particular type of port identifier used
223       in the LLDP YANG module.";
224   }
225
226   typedef port-id-type {
227     type string {
228       length "8";
229     }
230     description
231       "The format of a port identifier string. Objects of this type
232       are always used with an associated lldp-port-id-subtype object,
233       which identifies the format of the particular lldp-port-id
234       object instance.
235
236       If the associated lldp-port-id-subtype object has a value of
237       interface-alias, then the octet string identifies a
238       particular instance of the ifAlias object (defined in IETF
239       RFC 2863).  If the particular ifAlias object does not contain
240       any values, another port identifier type should be used.
241
242       If the associated lldp-port-id-subtype object has a value of
243       port-component, then the octet string identifies a
244       particular instance of the entPhysicalAlias object (defined
245       in IETF RFC 2737) for a port or backplane component.
246
247       If the associated lldp-port-id-subtype object has a value of
248       mac-address, then this string identifies a particular
249       unicast source address (encoded in network byte order
250       and IEEE 802.3 canonical bit order) associated with the port
251       (IEEE Std 802-2001).
252
253       If the associated lldp-port-id-subtype object has a value of
254       network-address, then this string identifies a network
255       address associated with the port.  The first octet contains
256       the IANA AddressFamilyNumbers enumeration value for the
257       specific address type, and octets 2 through N contain the
258       networkAddress address value in network byte order.
259
260       If the associated lldp-port-id-subtype object has a value of
261       interface-name, then the octet string identifies a
262       particular instance of the ifName object (defined in IETF
263       RFC 2863).  If the particular ifName object does not contain
264       any values, another port identifier type should be used.
265
266       If the associated lldp-port-id-subtype object has a value of
267       agent-circuit-id, then this string identifies a agent-local
268       identifier of the circuit (defined in RFC 3046).
269
270       If the associated lldp-port-id-subtype object has a value of
271       local, then this string identifies a locally assigned port ID.";
272   }
273 }