]>
git.proxmox.com Git - mirror_frr.git/blob - zebra/zebra_mpls_null.c
2 * Copyright (C) 2016 by Open Source Routing.
4 * This file is part of GNU Zebra.
6 * GNU Zebra is free software; you can redistribute it and/or modify it
7 * under the terms of the GNU General Public License as published by the
8 * Free Software Foundation; either version 2, or (at your option) any
11 * GNU Zebra is distributed in the hope that it will be useful, but
12 * WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 * General Public License for more details.
16 * You should have received a copy of the GNU General Public License
17 * along with GNU Zebra; see the file COPYING. If not, write to the Free
18 * Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
24 #include "zebra/zebra_mpls.h"
26 int kernel_add_lsp (zebra_lsp_t
*lsp
) { return 0; }
27 int kernel_upd_lsp (zebra_lsp_t
*lsp
) { return 0; }
28 int kernel_del_lsp (zebra_lsp_t
*lsp
) { return 0; }
29 int mpls_kernel_init (void) { return -1; };
34 mpls_label2str (u_int8_t num_labels
, mpls_label_t
*labels
,
35 char *buf
, int len
, int pretty
)
41 mpls_str2label (const char *label_str
, u_int8_t
*num_labels
,
48 zebra_mpls_label_block_add (struct zebra_vrf
*vrf
, u_int32_t start_label
,
55 zebra_mpls_label_block_del (struct zebra_vrf
*zvrf
)
61 zebra_mpls_write_label_block_config (struct vty
*vty
, struct zebra_vrf
*zvrf
)
67 zebra_mpls_lsp_install (struct zebra_vrf
*zvrf
, struct route_node
*rn
, struct rib
*rib
)
73 zebra_mpls_lsp_uninstall (struct zebra_vrf
*zvrf
, struct route_node
*rn
, struct rib
*rib
)
79 zebra_mpls_init_tables (struct zebra_vrf
*zvrf
)
84 zebra_mpls_print_lsp (struct vty
*vty
, struct zebra_vrf
*zvrf
, mpls_label_t label
,
90 zebra_mpls_print_lsp_table (struct vty
*vty
, struct zebra_vrf
*zvrf
,
96 zebra_mpls_write_lsp_config (struct vty
*vty
, struct zebra_vrf
*zvrf
)
103 zebra_mpls_lsp_label_consistent (struct zebra_vrf
*zvrf
, mpls_label_t in_label
,
104 mpls_label_t out_label
, enum nexthop_types_t gtype
,
105 union g_addr
*gate
, ifindex_t ifindex
)
112 zebra_mpls_static_lsp_add (struct zebra_vrf
*zvrf
, mpls_label_t in_label
,
113 mpls_label_t out_label
, enum nexthop_types_t gtype
,
114 union g_addr
*gate
, ifindex_t ifindex
)
120 zebra_mpls_static_lsp_del (struct zebra_vrf
*zvrf
, mpls_label_t in_label
,
121 enum nexthop_types_t gtype
, union g_addr
*gate
,
128 zebra_mpls_lsp_schedule (struct zebra_vrf
*zvrf
)
133 zebra_mpls_close_tables (struct zebra_vrf
*zvrf
)
138 zebra_mpls_fec_for_label (struct zebra_vrf
*zvrf
, mpls_label_t label
)
144 zebra_mpls_label_already_bound (struct zebra_vrf
*zvrf
, mpls_label_t label
)
150 zebra_mpls_static_fec_add (struct zebra_vrf
*zvrf
, struct prefix
*p
,
151 mpls_label_t in_label
)
157 zebra_mpls_static_fec_del (struct zebra_vrf
*zvrf
, struct prefix
*p
)
163 zebra_mpls_write_fec_config (struct vty
*vty
, struct zebra_vrf
*zvrf
)
169 zebra_mpls_print_fec_table (struct vty
*vty
, struct zebra_vrf
*zvrf
)
174 zebra_mpls_print_fec (struct vty
*vty
, struct zebra_vrf
*zvrf
, struct prefix
*p
)
179 zebra_mpls_fec_register (struct zebra_vrf
*zvrf
, struct prefix
*p
,
180 u_int32_t label_index
, struct zserv
*client
)
186 zebra_mpls_fec_unregister (struct zebra_vrf
*zvrf
, struct prefix
*p
,
187 struct zserv
*client
)
193 zebra_mpls_cleanup_fecs_for_client (struct zebra_vrf
*zvrf
, struct zserv
*client
)
198 void mpls_ldp_lsp_uninstall_all (struct hash_backet
*backet
, void *ctxt
)
203 void mpls_ldp_ftn_uninstall_all (struct zebra_vrf
*zvrf
, int afi
)
208 void zebra_mpls_init (void)
213 int mpls_lsp_install (struct zebra_vrf
*zvrf
, enum lsp_types_t type
,
214 mpls_label_t in_label
, mpls_label_t out_label
,
215 enum nexthop_types_t gtype
, union g_addr
*gate
,
221 int mpls_lsp_uninstall (struct zebra_vrf
*zvrf
, enum lsp_types_t type
,
222 mpls_label_t in_label
, enum nexthop_types_t gtype
,
223 union g_addr
*gate
, ifindex_t ifindex
)
228 int mpls_ftn_update (int add
, struct zebra_vrf
*zvrf
, enum lsp_types_t type
,
229 struct prefix
*prefix
, enum nexthop_types_t gtype
,
230 union g_addr
*gate
, ifindex_t ifindex
, u_int8_t distance
,
231 mpls_label_t out_label
)