]> git.proxmox.com Git - mirror_frr.git/blame - pimd/pim_mlag.h
Merge pull request #11918 from patrasar/show_ipv6_mld_interface_fix
[mirror_frr.git] / pimd / pim_mlag.h
CommitLineData
36b5b98f
SK
1/*
2 * This is an implementation of PIM MLAG Functionality
3 *
4 * Module name: PIM MLAG
5 *
6 * Author: sathesh Kumar karra <sathk@cumulusnetworks.com>
7 *
8 * Copyright (C) 2019 Cumulus Networks http://www.cumulusnetworks.com
9 *
10 * This program is free software; you can redistribute it and/or modify it
11 * under the terms of the GNU General Public License as published by the Free
12 * Software Foundation; either version 2 of the License, or (at your option)
13 * any later version.
14 *
15 * This program is distributed in the hope that it will be useful, but WITHOUT
16 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
17 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
18 * more details.
19 *
20 * You should have received a copy of the GNU General Public License along
21 * with this program; see the file COPYING; if not, write to the Free Software
22 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
23 */
24#ifndef __PIM_MLAG_H__
25#define __PIM_MLAG_H__
26
a243d1db 27#include "zclient.h"
36b5b98f
SK
28#include "mlag.h"
29#include "pim_iface.h"
30
deb76ca4 31#if PIM_IPV == 4
36b5b98f 32extern void pim_mlag_init(void);
892c2c44 33extern void pim_mlag_terminate(void);
36b5b98f
SK
34extern void pim_instance_mlag_init(struct pim_instance *pim);
35extern void pim_instance_mlag_terminate(struct pim_instance *pim);
36extern void pim_if_configure_mlag_dualactive(struct pim_interface *pim_ifp);
37extern void pim_if_unconfigure_mlag_dualactive(struct pim_interface *pim_ifp);
a243d1db
DL
38extern int pim_zebra_mlag_process_up(ZAPI_CALLBACK_ARGS);
39extern int pim_zebra_mlag_process_down(ZAPI_CALLBACK_ARGS);
40extern int pim_zebra_mlag_handle_msg(ZAPI_CALLBACK_ARGS);
17823cdd
DS
41
42/* pm_zpthread.c */
43extern int pim_mlag_signal_zpthread(void);
44extern void pim_zpthread_init(void);
45extern void pim_zpthread_terminate(void);
46
22c35834
SK
47extern void pim_mlag_register(void);
48extern void pim_mlag_deregister(void);
05ca004b 49extern void pim_mlag_up_local_add(struct pim_instance *pim,
22c35834 50 struct pim_upstream *upstream);
05ca004b 51extern void pim_mlag_up_local_del(struct pim_instance *pim,
22c35834 52 struct pim_upstream *upstream);
05ca004b 53extern bool pim_mlag_up_df_role_update(struct pim_instance *pim,
22c35834
SK
54 struct pim_upstream *up, bool is_df,
55 const char *reason);
deb76ca4
DL
56#else /* PIM_IPV == 4 */
57static inline void pim_mlag_terminate(void)
58{
59}
60
61static inline void pim_instance_mlag_init(struct pim_instance *pim)
62{
63}
64
65static inline void pim_instance_mlag_terminate(struct pim_instance *pim)
66{
67}
68
69static inline void pim_if_configure_mlag_dualactive(
70 struct pim_interface *pim_ifp)
71{
72}
73
74static inline void pim_if_unconfigure_mlag_dualactive(
75 struct pim_interface *pim_ifp)
76{
77}
78
79static inline void pim_mlag_register(void)
80{
81}
82
83static inline void pim_mlag_up_local_add(struct pim_instance *pim,
84 struct pim_upstream *upstream)
85{
86}
87
88static inline void pim_mlag_up_local_del(struct pim_instance *pim,
89 struct pim_upstream *upstream)
90{
91}
92
93static inline bool pim_mlag_up_df_role_update(struct pim_instance *pim,
94 struct pim_upstream *up,
95 bool is_df, const char *reason)
96{
97 return false;
98}
99#endif
100
36b5b98f 101#endif