]> git.proxmox.com Git - mirror_frr.git/commit
bgpd: move router bgp nb callback
authorChirag Shah <chirag@nvidia.com>
Sun, 20 Sep 2020 15:13:53 +0000 (08:13 -0700)
committerChirag Shah <chirag@nvidia.com>
Sat, 3 Oct 2020 18:25:38 +0000 (11:25 -0700)
commit5e42cb2fb088a28202e60ec57a4116f3d1f0afd5
treece484fe4464613a1b6c9c02fc5da0544e2ab7bbc
parent87ce25646be36bb9a27e75d177615e3d19a07df0
bgpd: move router bgp nb callback

move `router bgp` nb callback at `bgp` node level
to have access to bgp context at neighbor and peer-group
level and align create/destroy callbacks call during
no router bgp.

Earlier `no router bgp` is performed first global destroy
callback is called which essentially removes `bgp context`
then it calls to remove (parallel nodes) neighbor and peer-group
which does not have access to bgp context.
Moving router bgp at bgp solves this destroy callback ordering issue.

Signed-off-by: Chirag Shah <chirag@nvidia.com>
bgpd/bgp_nb.c
bgpd/bgp_nb.h
bgpd/bgp_nb_config.c
bgpd/bgp_vty.c
yang/frr-bgp.yang