]> git.proxmox.com Git - mirror_frr.git/blob - pbrd/pbr_zebra.h
Merge pull request #5793 from ton31337/fix/formatting_show_bgp_summary_failed
[mirror_frr.git] / pbrd / pbr_zebra.h
1 /*
2 * Zebra connect library for PBR
3 * Copyright (C) 2018 Cumulus Networks, Inc.
4 * Donald Sharp
5 *
6 * FRR 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
9 * later version.
10 *
11 * FRR 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.
15 *
16 * You should have received a copy of the GNU General Public License along
17 * with this program; see the file COPYING; if not, write to the Free Software
18 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 */
20 #ifndef __PBR_ZEBRA_H__
21 #define __PBR_ZEBRA_H__
22
23 struct pbr_interface {
24 char mapname[100];
25 };
26
27 extern struct thread_master *master;
28
29 extern void pbr_zebra_init(void);
30
31 extern void route_add(struct pbr_nexthop_group_cache *pnhgc,
32 struct nexthop_group nhg, afi_t install_afi);
33 extern void route_delete(struct pbr_nexthop_group_cache *pnhgc,
34 afi_t install_afi);
35
36 extern void pbr_send_rnh(struct nexthop *nhop, bool reg);
37
38 extern void pbr_send_pbr_map(struct pbr_map_sequence *pbrms,
39 struct pbr_map_interface *pmi, bool install);
40
41 extern struct pbr_interface *pbr_if_new(struct interface *ifp);
42
43 extern int pbr_ifp_create(struct interface *ifp);
44 extern int pbr_ifp_up(struct interface *ifp);
45 extern int pbr_ifp_down(struct interface *ifp);
46 extern int pbr_ifp_destroy(struct interface *ifp);
47
48 #endif