mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-08-13 22:26:14 +00:00
zebra: Add some small infrastructure to get the mlag code in zebra started
Add a zebra_mlag.h and a zebra_mlag.c startup/shutdown code to zebra. Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
This commit is contained in:
parent
14beb5484f
commit
df39560091
@ -64,6 +64,7 @@ zebra_zebra_SOURCES = \
|
||||
zebra/rtread_sysctl.c \
|
||||
zebra/rule_netlink.c \
|
||||
zebra/rule_socket.c \
|
||||
zebra/zebra_mlag.c \
|
||||
zebra/zebra_l2.c \
|
||||
zebra/zebra_memory.c \
|
||||
zebra/zebra_dplane.c \
|
||||
@ -119,6 +120,7 @@ noinst_HEADERS += \
|
||||
zebra/rt_netlink.h \
|
||||
zebra/rtadv.h \
|
||||
zebra/rule_netlink.h \
|
||||
zebra/zebra_mlag.h \
|
||||
zebra/zebra_fpm_private.h \
|
||||
zebra/zebra_l2.h \
|
||||
zebra/zebra_dplane.h \
|
||||
|
34
zebra/zebra_mlag.c
Normal file
34
zebra/zebra_mlag.c
Normal file
@ -0,0 +1,34 @@
|
||||
/* Zebra Mlag Code.
|
||||
* Copyright (C) 2018 Cumulus Networks, Inc.
|
||||
* Donald Sharp
|
||||
*
|
||||
* This file is part of FRR.
|
||||
*
|
||||
* FRR is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License as published by the
|
||||
* Free Software Foundation; either version 2, or (at your option) any
|
||||
* later version.
|
||||
*
|
||||
* FRR is distributed in the hope that it will be useful, but
|
||||
* WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with FRR; see the file COPYING. If not, write to the Free
|
||||
* Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
|
||||
* 02111-1307, USA.
|
||||
*/
|
||||
#include "zebra.h"
|
||||
|
||||
#include "hook.h"
|
||||
|
||||
#include "zebra/zebra_mlag.h"
|
||||
|
||||
void zebra_mlag_init(void)
|
||||
{
|
||||
}
|
||||
|
||||
void zebra_mlag_terminate(void)
|
||||
{
|
||||
}
|
29
zebra/zebra_mlag.h
Normal file
29
zebra/zebra_mlag.h
Normal file
@ -0,0 +1,29 @@
|
||||
/* Zebra mlag header.
|
||||
* Copyright (C) 2018 Cumulus Networks, Inc.
|
||||
* Donald Sharp
|
||||
*
|
||||
* This file is part of FRR.
|
||||
*
|
||||
* FRR is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License as published by the
|
||||
* Free Software Foundation; either version 2, or (at your option) any
|
||||
* later version.
|
||||
*
|
||||
* FRR is distributed in the hope that it will be useful, but
|
||||
* WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with FRR; see the file COPYING. If not, write to the Free
|
||||
* Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
|
||||
* 02111-1307, USA.
|
||||
*/
|
||||
#ifndef __ZEBRA_MLAG_H__
|
||||
#define __ZEBRA_MLAG_H__
|
||||
|
||||
#include "mlag.h"
|
||||
|
||||
void zebra_mlag_init(void);
|
||||
void zebra_mlag_terminate(void);
|
||||
#endif
|
@ -25,6 +25,7 @@
|
||||
#include "zebra_memory.h"
|
||||
#include "zebra_pbr.h"
|
||||
#include "zebra_vxlan.h"
|
||||
#include "zebra_mlag.h"
|
||||
|
||||
struct zebra_router zrouter;
|
||||
|
||||
@ -159,6 +160,8 @@ void zebra_router_terminate(void)
|
||||
}
|
||||
|
||||
zebra_vxlan_disable();
|
||||
zebra_mlag_terminate();
|
||||
|
||||
hash_clean(zrouter.rules_hash, zebra_pbr_rules_free);
|
||||
hash_free(zrouter.rules_hash);
|
||||
|
||||
@ -173,6 +176,8 @@ void zebra_router_terminate(void)
|
||||
void zebra_router_init(void)
|
||||
{
|
||||
zebra_vxlan_init();
|
||||
zebra_mlag_init();
|
||||
|
||||
zrouter.rules_hash = hash_create_size(8, zebra_pbr_rules_hash_key,
|
||||
zebra_pbr_rules_hash_equal,
|
||||
"Rules Hash");
|
||||
|
Loading…
Reference in New Issue
Block a user