]>
git.proxmox.com Git - mirror_frr.git/blob - pimd/pim_mlag.h
2 * This is an implementation of PIM MLAG Functionality
4 * Module name: PIM MLAG
6 * Author: sathesh Kumar karra <sathk@cumulusnetworks.com>
8 * Copyright (C) 2019 Cumulus Networks http://www.cumulusnetworks.com
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)
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
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
24 #ifndef __PIM_MLAG_H__
25 #define __PIM_MLAG_H__
29 #include "pim_iface.h"
32 extern void pim_mlag_init(void);
33 extern void pim_mlag_terminate(void);
34 extern void pim_instance_mlag_init(struct pim_instance
*pim
);
35 extern void pim_instance_mlag_terminate(struct pim_instance
*pim
);
36 extern void pim_if_configure_mlag_dualactive(struct pim_interface
*pim_ifp
);
37 extern void pim_if_unconfigure_mlag_dualactive(struct pim_interface
*pim_ifp
);
38 extern int pim_zebra_mlag_process_up(ZAPI_CALLBACK_ARGS
);
39 extern int pim_zebra_mlag_process_down(ZAPI_CALLBACK_ARGS
);
40 extern int pim_zebra_mlag_handle_msg(ZAPI_CALLBACK_ARGS
);
43 extern int pim_mlag_signal_zpthread(void);
44 extern void pim_zpthread_init(void);
45 extern void pim_zpthread_terminate(void);
47 extern void pim_mlag_register(void);
48 extern void pim_mlag_deregister(void);
49 extern void pim_mlag_up_local_add(struct pim_instance
*pim
,
50 struct pim_upstream
*upstream
);
51 extern void pim_mlag_up_local_del(struct pim_instance
*pim
,
52 struct pim_upstream
*upstream
);
53 extern bool pim_mlag_up_df_role_update(struct pim_instance
*pim
,
54 struct pim_upstream
*up
, bool is_df
,
56 #else /* PIM_IPV == 4 */
57 static inline void pim_mlag_terminate(void)
61 static inline void pim_instance_mlag_init(struct pim_instance
*pim
)
65 static inline void pim_instance_mlag_terminate(struct pim_instance
*pim
)
69 static inline void pim_if_configure_mlag_dualactive(
70 struct pim_interface
*pim_ifp
)
74 static inline void pim_if_unconfigure_mlag_dualactive(
75 struct pim_interface
*pim_ifp
)
79 static inline void pim_mlag_register(void)
83 static inline void pim_mlag_up_local_add(struct pim_instance
*pim
,
84 struct pim_upstream
*upstream
)
88 static inline void pim_mlag_up_local_del(struct pim_instance
*pim
,
89 struct pim_upstream
*upstream
)
93 static inline bool pim_mlag_up_df_role_update(struct pim_instance
*pim
,
94 struct pim_upstream
*up
,
95 bool is_df
, const char *reason
)