]> git.proxmox.com Git - mirror_frr.git/blame - staticd/static_nb.c
Merge pull request #12798 from donaldsharp/rib_match_multicast
[mirror_frr.git] / staticd / static_nb.c
CommitLineData
acddc0ed 1// SPDX-License-Identifier: GPL-2.0-or-later
88fa5104 2/*
3 * Copyright (C) 2018 Vmware
4 * Vishal Dhingra
88fa5104 5 */
1f8031f7
DL
6#include <zebra.h>
7
88fa5104 8#include "northbound.h"
9#include "libfrr.h"
10#include "static_nb.h"
6cc73dad 11#include "static_vty.h"
88fa5104 12
13/* clang-format off */
14
15const struct frr_yang_module_info frr_staticd_info = {
16 .name = "frr-staticd",
17 .nodes = {
6cc73dad
IR
18 {
19 .xpath = "/frr-routing:routing/control-plane-protocols/control-plane-protocol/frr-staticd:staticd",
20 .cbs = {
21 .cli_show = static_cli_show,
22 .cli_show_end = static_cli_show_end,
23 }
24 },
88fa5104 25 {
26 .xpath = "/frr-routing:routing/control-plane-protocols/control-plane-protocol/frr-staticd:staticd/route-list",
27 .cbs = {
28 .create = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_create,
29 .destroy = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_destroy,
6cc73dad 30 .cli_cmp = static_route_list_cli_cmp,
88fa5104 31 }
32 },
33 {
34 .xpath = "/frr-routing:routing/control-plane-protocols/control-plane-protocol/frr-staticd:staticd/route-list/path-list",
35 .cbs = {
36 .create = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_path_list_create,
37 .destroy = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_path_list_destroy,
6cc73dad 38 .cli_cmp = static_path_list_cli_cmp,
88fa5104 39 }
40 },
41 {
42 .xpath = "/frr-routing:routing/control-plane-protocols/control-plane-protocol/frr-staticd:staticd/route-list/path-list/tag",
43 .cbs = {
44 .modify = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_path_list_tag_modify,
45 }
46 },
88fa5104 47 {
48 .xpath = "/frr-routing:routing/control-plane-protocols/control-plane-protocol/frr-staticd:staticd/route-list/path-list/frr-nexthops/nexthop",
49 .cbs = {
50 .apply_finish = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_path_list_frr_nexthops_nexthop_apply_finish,
51 .create = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_path_list_frr_nexthops_nexthop_create,
52 .destroy = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_path_list_frr_nexthops_nexthop_destroy,
53 .pre_validate = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_path_list_frr_nexthops_nexthop_pre_validate,
6cc73dad
IR
54 .cli_show = static_nexthop_cli_show,
55 .cli_cmp = static_nexthop_cli_cmp,
88fa5104 56 }
57 },
58 {
59 .xpath = "/frr-routing:routing/control-plane-protocols/control-plane-protocol/frr-staticd:staticd/route-list/path-list/frr-nexthops/nexthop/bh-type",
60 .cbs = {
61 .modify = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_path_list_frr_nexthops_nexthop_bh_type_modify,
88fa5104 62 }
63 },
64 {
65 .xpath = "/frr-routing:routing/control-plane-protocols/control-plane-protocol/frr-staticd:staticd/route-list/path-list/frr-nexthops/nexthop/onlink",
66 .cbs = {
67 .modify = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_path_list_frr_nexthops_nexthop_onlink_modify,
88fa5104 68 }
69 },
065276ae
SM
70 {
71 .xpath = "/frr-routing:routing/control-plane-protocols/control-plane-protocol/frr-staticd:staticd/route-list/path-list/frr-nexthops/nexthop/srte-color",
72 .cbs = {
73 .modify = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_path_list_frr_nexthops_nexthop_color_modify,
74 .destroy = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_path_list_frr_nexthops_nexthop_color_destroy,
75 }
76 },
88fa5104 77 {
78 .xpath = "/frr-routing:routing/control-plane-protocols/control-plane-protocol/frr-staticd:staticd/route-list/path-list/frr-nexthops/nexthop/mpls-label-stack/entry",
79 .cbs = {
80 .create = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_path_list_frr_nexthops_nexthop_mpls_label_stack_entry_create,
81 .destroy = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_path_list_frr_nexthops_nexthop_mpls_label_stack_entry_destroy,
82
83 }
84 },
85 {
86 .xpath = "/frr-routing:routing/control-plane-protocols/control-plane-protocol/frr-staticd:staticd/route-list/path-list/frr-nexthops/nexthop/mpls-label-stack/entry/label",
87 .cbs = {
88 .modify = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_path_list_frr_nexthops_nexthop_mpls_label_stack_entry_label_modify,
89 .destroy = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_path_list_frr_nexthops_nexthop_mpls_label_stack_entry_label_destroy,
90 }
91 },
92 {
93 .xpath = "/frr-routing:routing/control-plane-protocols/control-plane-protocol/frr-staticd:staticd/route-list/path-list/frr-nexthops/nexthop/mpls-label-stack/entry/ttl",
94 .cbs = {
95 .modify = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_path_list_frr_nexthops_nexthop_mpls_label_stack_entry_ttl_modify,
96 .destroy = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_path_list_frr_nexthops_nexthop_mpls_label_stack_entry_ttl_destroy,
97 }
98 },
99 {
100 .xpath = "/frr-routing:routing/control-plane-protocols/control-plane-protocol/frr-staticd:staticd/route-list/path-list/frr-nexthops/nexthop/mpls-label-stack/entry/traffic-class",
101 .cbs = {
102 .modify = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_path_list_frr_nexthops_nexthop_mpls_label_stack_entry_traffic_class_modify,
103 .destroy = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_path_list_frr_nexthops_nexthop_mpls_label_stack_entry_traffic_class_destroy,
104 }
105 },
351ad684
RZ
106 {
107 .xpath = "/frr-routing:routing/control-plane-protocols/control-plane-protocol/frr-staticd:staticd/route-list/path-list/frr-nexthops/nexthop/bfd-monitoring",
108 .cbs = {
109 .create = route_next_hop_bfd_create,
110 .destroy = route_next_hop_bfd_destroy,
111 }
112 },
113 {
114 .xpath = "/frr-routing:routing/control-plane-protocols/control-plane-protocol/frr-staticd:staticd/route-list/path-list/frr-nexthops/nexthop/bfd-monitoring/source",
115 .cbs = {
116 .modify = route_next_hop_bfd_source_modify,
117 .destroy = route_next_hop_bfd_source_destroy,
118 }
119 },
120 {
121 .xpath = "/frr-routing:routing/control-plane-protocols/control-plane-protocol/frr-staticd:staticd/route-list/path-list/frr-nexthops/nexthop/bfd-monitoring/multi-hop",
122 .cbs = {
123 .modify = route_next_hop_bfd_multi_hop_modify,
124 }
125 },
126 {
127 .xpath = "/frr-routing:routing/control-plane-protocols/control-plane-protocol/frr-staticd:staticd/route-list/path-list/frr-nexthops/nexthop/bfd-monitoring/profile",
128 .cbs = {
129 .modify = route_next_hop_bfd_profile_modify,
130 .destroy = route_next_hop_bfd_profile_destroy,
131 }
132 },
88fa5104 133 {
134 .xpath = "/frr-routing:routing/control-plane-protocols/control-plane-protocol/frr-staticd:staticd/route-list/src-list",
135 .cbs = {
136 .create = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_src_list_create,
137 .destroy = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_src_list_destroy,
6cc73dad 138 .cli_cmp = static_src_list_cli_cmp,
88fa5104 139 }
140 },
141 {
142 .xpath = "/frr-routing:routing/control-plane-protocols/control-plane-protocol/frr-staticd:staticd/route-list/src-list/path-list",
143 .cbs = {
144 .create = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_src_list_path_list_create,
145 .destroy = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_src_list_path_list_destroy,
6cc73dad 146 .cli_cmp = static_path_list_cli_cmp,
88fa5104 147 }
148 },
149 {
150 .xpath = "/frr-routing:routing/control-plane-protocols/control-plane-protocol/frr-staticd:staticd/route-list/src-list/path-list/tag",
151 .cbs = {
152 .modify = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_src_list_path_list_tag_modify,
153 }
154 },
88fa5104 155 {
156 .xpath = "/frr-routing:routing/control-plane-protocols/control-plane-protocol/frr-staticd:staticd/route-list/src-list/path-list/frr-nexthops/nexthop",
157 .cbs = {
158 .apply_finish = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_src_list_path_list_frr_nexthops_nexthop_apply_finish,
159 .create = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_src_list_path_list_frr_nexthops_nexthop_create,
160 .destroy = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_src_list_path_list_frr_nexthops_nexthop_destroy,
161 .pre_validate = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_path_list_frr_nexthops_nexthop_pre_validate,
6cc73dad
IR
162 .cli_show = static_src_nexthop_cli_show,
163 .cli_cmp = static_nexthop_cli_cmp,
88fa5104 164 }
165 },
166 {
167 .xpath = "/frr-routing:routing/control-plane-protocols/control-plane-protocol/frr-staticd:staticd/route-list/src-list/path-list/frr-nexthops/nexthop/bh-type",
168 .cbs = {
169 .modify = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_src_list_path_list_frr_nexthops_nexthop_bh_type_modify,
88fa5104 170 }
171 },
172 {
173 .xpath = "/frr-routing:routing/control-plane-protocols/control-plane-protocol/frr-staticd:staticd/route-list/src-list/path-list/frr-nexthops/nexthop/onlink",
174 .cbs = {
175 .modify = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_src_list_path_list_frr_nexthops_nexthop_onlink_modify,
88fa5104 176 }
177 },
065276ae
SM
178 {
179 .xpath = "/frr-routing:routing/control-plane-protocols/control-plane-protocol/frr-staticd:staticd/route-list/src-list/path-list/frr-nexthops/nexthop/srte-color",
180 .cbs = {
181 .modify = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_src_list_path_list_frr_nexthops_nexthop_color_modify,
182 .destroy = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_src_list_path_list_frr_nexthops_nexthop_color_destroy,
183 }
184 },
88fa5104 185 {
186 .xpath = "/frr-routing:routing/control-plane-protocols/control-plane-protocol/frr-staticd:staticd/route-list/src-list/path-list/frr-nexthops/nexthop/mpls-label-stack/entry",
187 .cbs = {
188 .create = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_src_list_path_list_frr_nexthops_nexthop_mpls_label_stack_entry_create,
189 .destroy = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_src_list_path_list_frr_nexthops_nexthop_mpls_label_stack_entry_destroy,
190 }
191 },
192 {
193 .xpath = "/frr-routing:routing/control-plane-protocols/control-plane-protocol/frr-staticd:staticd/route-list/src-list/path-list/frr-nexthops/nexthop/mpls-label-stack/entry/label",
194 .cbs = {
195 .modify = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_src_list_path_list_frr_nexthops_nexthop_mpls_label_stack_entry_label_modify,
196 .destroy = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_src_list_path_list_frr_nexthops_nexthop_mpls_label_stack_entry_label_destroy,
197 }
198 },
199 {
200 .xpath = "/frr-routing:routing/control-plane-protocols/control-plane-protocol/frr-staticd:staticd/route-list/src-list/path-list/frr-nexthops/nexthop/mpls-label-stack/entry/ttl",
201 .cbs = {
202 .modify = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_src_list_path_list_frr_nexthops_nexthop_mpls_label_stack_entry_ttl_modify,
203 .destroy = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_src_list_path_list_frr_nexthops_nexthop_mpls_label_stack_entry_ttl_destroy,
204 }
205 },
206 {
207 .xpath = "/frr-routing:routing/control-plane-protocols/control-plane-protocol/frr-staticd:staticd/route-list/src-list/path-list/frr-nexthops/nexthop/mpls-label-stack/entry/traffic-class",
208 .cbs = {
209 .modify = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_src_list_path_list_frr_nexthops_nexthop_mpls_label_stack_entry_traffic_class_modify,
210 .destroy = routing_control_plane_protocols_control_plane_protocol_staticd_route_list_src_list_path_list_frr_nexthops_nexthop_mpls_label_stack_entry_traffic_class_destroy,
211 }
212 },
213 {
214 .xpath = NULL,
215 },
216 }
217};