]> git.proxmox.com Git - mirror_frr.git/blob - zebra/zebra_routemap_nb.c
Merge pull request #8003 from donaldsharp/timings
[mirror_frr.git] / zebra / zebra_routemap_nb.c
1 /*
2 * Copyright (C) 2020 Vmware
3 * Sarita Patra
4 *
5 * This program is free software; you can redistribute it and/or modify it
6 * under the terms of the GNU General Public License as published by the Free
7 * Software Foundation; either version 2 of the License, or (at your option)
8 * any later version.
9 *
10 * This program is distributed in the hope that it will be useful, but WITHOUT
11 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
12 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
13 * more details.
14 *
15 * You should have received a copy of the GNU General Public License along
16 * with this program; see the file COPYING; if not, write to the Free Software
17 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
18 */
19
20 #include "northbound.h"
21 #include "libfrr.h"
22 #include "zebra_routemap_nb.h"
23
24 /* clang-format off */
25 const struct frr_yang_module_info frr_zebra_route_map_info = {
26 .name = "frr-zebra-route-map",
27 .nodes = {
28 {
29 .xpath = "/frr-route-map:lib/route-map/entry/match-condition/rmap-match-condition/frr-zebra-route-map:ipv4-prefix-length",
30 .cbs = {
31 .modify = lib_route_map_entry_match_condition_rmap_match_condition_ipv4_prefix_length_modify,
32 .destroy = lib_route_map_entry_match_condition_rmap_match_condition_ipv4_prefix_length_destroy,
33 }
34 },
35 {
36 .xpath = "/frr-route-map:lib/route-map/entry/match-condition/rmap-match-condition/frr-zebra-route-map:ipv6-prefix-length",
37 .cbs = {
38 .modify = lib_route_map_entry_match_condition_rmap_match_condition_ipv6_prefix_length_modify,
39 .destroy = lib_route_map_entry_match_condition_rmap_match_condition_ipv6_prefix_length_destroy,
40 }
41 },
42 {
43 .xpath = "/frr-route-map:lib/route-map/entry/match-condition/rmap-match-condition/frr-zebra-route-map:source-instance",
44 .cbs = {
45 .modify = lib_route_map_entry_match_condition_rmap_match_condition_source_instance_modify,
46 .destroy = lib_route_map_entry_match_condition_rmap_match_condition_source_instance_destroy,
47 }
48 },
49 {
50 .xpath = "/frr-route-map:lib/route-map/entry/match-condition/rmap-match-condition/frr-zebra-route-map:source-protocol",
51 .cbs = {
52 .modify = lib_route_map_entry_match_condition_rmap_match_condition_source_protocol_modify,
53 .destroy = lib_route_map_entry_match_condition_rmap_match_condition_source_protocol_destroy,
54 }
55 },
56 {
57 .xpath = "/frr-route-map:lib/route-map/entry/set-action/rmap-set-action/frr-zebra-route-map:ipv4-src-address",
58 .cbs = {
59 .modify = lib_route_map_entry_set_action_rmap_set_action_ipv4_src_address_modify,
60 .destroy = lib_route_map_entry_set_action_rmap_set_action_ipv4_src_address_destroy,
61 }
62 },
63 {
64 .xpath = "/frr-route-map:lib/route-map/entry/set-action/rmap-set-action/frr-zebra-route-map:ipv6-src-address",
65 .cbs = {
66 .modify = lib_route_map_entry_set_action_rmap_set_action_ipv6_src_address_modify,
67 .destroy = lib_route_map_entry_set_action_rmap_set_action_ipv6_src_address_destroy,
68 }
69 },
70 {
71 .xpath = NULL,
72 },
73 }
74 };