Coverage Report

Created: 2025-07-14 06:48

/src/frr/yang/frr-routing.yang.c
Line
Count
Source
1
/* autogenerated by embedmodel.py.  DO NOT EDIT */
2
3
#include <zebra.h>
4
#include "yang.h"
5
6
static const char model[] =
7
  "// SPDX-License-Identifier: BSD-2-Clause\n"
8
  "module frr-routing {\n"
9
  "  yang-version \"1.1\";\n"
10
  "  namespace \"http://frrouting.org/yang/routing\";\n"
11
  "  prefix \"frr-routing\";\n"
12
  "\n"
13
  "  import ietf-yang-types {\n"
14
  "    prefix \"yang\";\n"
15
  "  }\n"
16
  "\n"
17
  "  import frr-vrf {\n"
18
  "    prefix frr-vrf;\n"
19
  "  }\n"
20
  "\n"
21
  "  organization\n"
22
  "    \"FRRouting\";\n"
23
  "\n"
24
  "  contact\n"
25
  "    \"FRR Users List:       <mailto:frog@lists.frrouting.org>\n"
26
  "     FRR Development List: <mailto:dev@lists.frrouting.org>\";\n"
27
  "\n"
28
  "  description\n"
29
  "    \"This YANG module defines essential components for the management\n"
30
  "     of a routing subsystem.\n"
31
  "\n"
32
  "     Copyright 2020 FRRouting\n"
33
  "\n"
34
  "     Redistribution and use in source and binary forms, with or without\n"
35
  "     modification, are permitted provided that the following conditions\n"
36
  "     are met:\n"
37
  "\n"
38
  "     1. Redistributions of source code must retain the above copyright notice,\n"
39
  "     this list of conditions and the following disclaimer.\n"
40
  "\n"
41
  "     2. Redistributions in binary form must reproduce the above copyright\n"
42
  "     notice, this list of conditions and the following disclaimer in the\n"
43
  "     documentation and/or other materials provided with the distribution.\n"
44
  "\n"
45
  "     THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS\n"
46
  "     \\\"AS IS\\\" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT\n"
47
  "     LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR\n"
48
  "     A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT\n"
49
  "     HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,\n"
50
  "     SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT\n"
51
  "     LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,\n"
52
  "     DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY\n"
53
  "     THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT\n"
54
  "     (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE\n"
55
  "     OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\";\n"
56
  "\n"
57
  "  revision 2019-08-15 {\n"
58
  "    description\n"
59
  "      \"Initial revision.\";\n"
60
  "  }\n"
61
  "\n"
62
  "  /* Identities */\n"
63
  "\n"
64
  "  identity address-family {\n"
65
  "    description\n"
66
  "      \"Base identity from which identities describing address\n"
67
  "       families are derived.\";\n"
68
  "  }\n"
69
  "\n"
70
  "  identity ipv4 {\n"
71
  "    base address-family;\n"
72
  "    description\n"
73
  "      \"This identity represents an IPv4 address family.\";\n"
74
  "  }\n"
75
  "\n"
76
  "  identity ipv6 {\n"
77
  "    base address-family;\n"
78
  "    description\n"
79
  "      \"This identity represents an IPv6 address family.\";\n"
80
  "  }\n"
81
  "\n"
82
  "  identity afi-safi-type {\n"
83
  "    description\n"
84
  "      \"Base identity type (AFI,SAFI) tuples for RIB\";\n"
85
  "  }\n"
86
  "\n"
87
  "  identity ipv4-unicast {\n"
88
  "    base afi-safi-type;\n"
89
  "    description\n"
90
  "      \"This identity represents the IPv4 unicast address family.\";\n"
91
  "  }\n"
92
  "\n"
93
  "  identity ipv6-unicast {\n"
94
  "    base afi-safi-type;\n"
95
  "    description\n"
96
  "      \"This identity represents the IPv6 unicast address family.\";\n"
97
  "  }\n"
98
  "\n"
99
  "  identity ipv4-multicast {\n"
100
  "    base afi-safi-type;\n"
101
  "    description\n"
102
  "      \"This identity represents the IPv4 multicast address family.\";\n"
103
  "  }\n"
104
  "\n"
105
  "  identity ipv6-multicast {\n"
106
  "    base afi-safi-type;\n"
107
  "    description\n"
108
  "      \"This identity represents the IPv6 multicast address family.\";\n"
109
  "  }\n"
110
  "\n"
111
  "  identity ipv4-labeled-unicast {\n"
112
  "    base afi-safi-type;\n"
113
  "    description\n"
114
  "      \"This identity represents the IPv4 labeled unicast address family.\";\n"
115
  "  }\n"
116
  "\n"
117
  "\n"
118
  "  identity ipv6-labeled-unicast {\n"
119
  "    base afi-safi-type;\n"
120
  "    description\n"
121
  "      \"This identity represents the IPv6 labeled unicast address family.\";\n"
122
  "  }\n"
123
  "\n"
124
  "\n"
125
  "  identity l3vpn-ipv4-unicast {\n"
126
  "    base afi-safi-type;\n"
127
  "    description\n"
128
  "      \"This identity represents the L3vpn IPv4 unicast address family.\";\n"
129
  "  }\n"
130
  "\n"
131
  "\n"
132
  "  identity l3vpn-ipv6-unicast {\n"
133
  "    base afi-safi-type;\n"
134
  "    description\n"
135
  "      \"This identity represents the L3vpn IPv6 unicast address family.\";\n"
136
  "  }\n"
137
  "\n"
138
  "\n"
139
  "  identity l3vpn-ipv4-multicast {\n"
140
  "    base afi-safi-type;\n"
141
  "    description\n"
142
  "      \"This identity represents the L3vpn IPv4 multicast address family.\";\n"
143
  "  }\n"
144
  "\n"
145
  "\n"
146
  "  identity l3vpn-ipv6-multicast {\n"
147
  "    base afi-safi-type;\n"
148
  "    description\n"
149
  "      \"This identity represents the L3vpn IPv6 multicast address family.\";\n"
150
  "  }\n"
151
  "\n"
152
  "\n"
153
  "  identity l2vpn-vpls {\n"
154
  "    base afi-safi-type;\n"
155
  "    description\n"
156
  "      \"This identity represents the L2vpn VPLS  address family.\";\n"
157
  "  }\n"
158
  "\n"
159
  "\n"
160
  "  identity l2vpn-evpn {\n"
161
  "    base afi-safi-type;\n"
162
  "    description\n"
163
  "      \"This identity represents the L2vpn EVPN address family.\";\n"
164
  "  }\n"
165
  "\n"
166
  "\n"
167
  "  identity ipv4-flowspec {\n"
168
  "    base afi-safi-type;\n"
169
  "    description\n"
170
  "      \"This identity represents the IPv4 flowspec address family.\";\n"
171
  "  }\n"
172
  "\n"
173
  "\n"
174
  "  identity ipv6-flowspec {\n"
175
  "    base afi-safi-type;\n"
176
  "    description\n"
177
  "      \"This identity represents the IPv6 flowspec address family.\";\n"
178
  "  }\n"
179
  "\n"
180
  "\n"
181
  "  identity control-plane-protocol {\n"
182
  "    description\n"
183
  "      \"Base identity from which control-plane protocol identities are\n"
184
  "       derived.\";\n"
185
  "  }\n"
186
  "\n"
187
  "  identity routing-protocol {\n"
188
  "    base control-plane-protocol;\n"
189
  "    description\n"
190
  "      \"Identity from which Layer 3 routing protocol identities are\n"
191
  "       derived.\";\n"
192
  "  }\n"
193
  "\n"
194
  "  /* Type Definitions */\n"
195
  "\n"
196
  "  typedef administrative-distance {\n"
197
  "    type uint8 {\n"
198
  "      range \"1..255\";\n"
199
  "    }\n"
200
  "    description\n"
201
  "      \"Admin distance associated with the route.\";\n"
202
  "  }\n"
203
  "\n"
204
  "  /* Groupings */\n"
205
  "\n"
206
  "  grouping address-family {\n"
207
  "    description\n"
208
  "      \"This grouping provides a leaf identifying an address\n"
209
  "       family.\";\n"
210
  "    leaf address-family {\n"
211
  "      type identityref {\n"
212
  "        base address-family;\n"
213
  "      }\n"
214
  "      mandatory true;\n"
215
  "      description\n"
216
  "        \"Address family.\";\n"
217
  "    }\n"
218
  "  }\n"
219
  "\n"
220
  "  grouping router-id {\n"
221
  "    description\n"
222
  "      \"This grouping provides a router ID.\";\n"
223
  "    leaf router-id {\n"
224
  "      type yang:dotted-quad;\n"
225
  "      description\n"
226
  "        \"A 32-bit number in the form of a dotted quad that is used by\n"
227
  "         some routing protocols identifying a router.\";\n"
228
  "      reference\n"
229
  "        \"RFC 2328: OSPF Version 2\";\n"
230
  "    }\n"
231
  "  }\n"
232
  "\n"
233
  "  /* Data nodes */\n"
234
  "\n"
235
  "  container routing {\n"
236
  "    description\n"
237
  "      \"Configuration parameters for the routing subsystem.\";\n"
238
  "    container control-plane-protocols {\n"
239
  "      description\n"
240
  "        \"Support for control-plane protocol instances.\";\n"
241
  "      list control-plane-protocol {\n"
242
  "        key \"type name vrf\";\n"
243
  "        description\n"
244
  "          \"Each entry contains a control-plane protocol instance.\";\n"
245
  "        leaf type {\n"
246
  "          type identityref {\n"
247
  "            base control-plane-protocol;\n"
248
  "          }\n"
249
  "          description\n"
250
  "            \"Type of the control-plane protocol\";\n"
251
  "        }\n"
252
  "        leaf name {\n"
253
  "          type string;\n"
254
  "          description\n"
255
  "            \"An arbitrary name of the control-plane protocol\n"
256
  "             instance.\";\n"
257
  "        }\n"
258
  "        leaf vrf {\n"
259
  "          type frr-vrf:vrf-ref;\n"
260
  "          description\n"
261
  "            \"vrf for control-plane protocol\";\n"
262
  "        }\n"
263
  "      }\n"
264
  "    }\n"
265
  "  }\n"
266
  "}\n"
267
  "";
268
269
static struct yang_module_embed embed = {
270
  .mod_name = "frr-routing",
271
  .mod_rev = "2019-08-15",
272
  .sub_mod_name = "",
273
  .sub_mod_rev = "",
274
  .data = model,
275
  .format = LYS_IN_YANG,
276
};
277
278
static void embed_register(void) __attribute__((_CONSTRUCTOR(2000)));
279
static void embed_register(void)
280
7
{
281
7
  yang_module_embed(&embed);
282
7
}