mirror of
https://github.com/FRRouting/frr.git
synced 2025-04-30 13:37:17 +02:00

During vrf delete, the vxlan_info.work_list linked list was deleted which is a global list containing the SGs for all the VRFs. If two vrfs are configured, vrf a and vrf b and both has SGs assocaited with them which are inserted in the vxlan_info.work_list. Now if vrf a is deleted, it deletes the work_list also. Due to this when any SG add or del comes for vrf b it tries to access the work_list and crashes. Fix Delete the vxlan_info.work_list only when all the VRFs are terminated and unset the vxlan_info.flags so if new add cmd comes it re-allocates the work_list. Signed-off-by: usrivastava-nvidia <usrivastava@nvidia.com>
39 lines
952 B
C
39 lines
952 B
C
// SPDX-License-Identifier: GPL-2.0-or-later
|
|
/* PIM support for VxLAN BUM flooding
|
|
*
|
|
* Copyright (C) 2019 Cumulus Networks, Inc.
|
|
*
|
|
*/
|
|
|
|
#ifndef PIM_VXLAN_INSTANCE_H
|
|
#define PIM_VXLAN_INSTANCE_H
|
|
|
|
/* pim termination device is expected to include the substring ipmr-lo */
|
|
#define PIM_VXLAN_TERM_DEV_NAME "ipmr-lo"
|
|
|
|
struct pim_vxlan_instance {
|
|
struct hash *sg_hash;
|
|
|
|
/* this is lo for default instance and vrf-dev for non-default
|
|
* instances
|
|
*/
|
|
struct interface *default_iif;
|
|
|
|
/* In a MLAG/VxLAN-AA setup the peerlink sub-interface (ISL-rif) is
|
|
* used as the IIF in
|
|
*/
|
|
struct interface *peerlink_rif;
|
|
|
|
/* device used by the dataplane to terminate multicast encapsulated
|
|
* vxlan traffic
|
|
*/
|
|
struct interface *term_if_cfg;
|
|
struct interface *term_if;
|
|
};
|
|
|
|
extern void pim_vxlan_init(struct pim_instance *pim);
|
|
extern void pim_vxlan_exit(struct pim_instance *pim);
|
|
void pim_vxlan_work_list_delete(void);
|
|
|
|
#endif /* PIM_VXLAN_INSTANCE_H */
|