summaryrefslogtreecommitdiff
path: root/bfdd/ptm_adapter.c
diff options
context:
space:
mode:
authorDonald Sharp <sharpd@cumulusnetworks.com>2019-09-19 09:40:57 -0400
committerDonald Sharp <sharpd@cumulusnetworks.com>2019-09-19 13:34:06 -0400
commit3c3c325203848994bae83a85cb606d4e4deeeb25 (patch)
treeac8447eb389883d0f009599cb4ea460401f5af8b /bfdd/ptm_adapter.c
parentb0b69e59f463b696d0e20f30c46c59c9cf0044b1 (diff)
*: Convert zapi->interface_delete to ifp callback
Convert the callback of the interface_delete to the new ifp callback. Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
Diffstat (limited to 'bfdd/ptm_adapter.c')
-rw-r--r--bfdd/ptm_adapter.c19
1 files changed, 1 insertions, 18 deletions
diff --git a/bfdd/ptm_adapter.c b/bfdd/ptm_adapter.c
index dc90b4d6e1..1b3219c235 100644
--- a/bfdd/ptm_adapter.c
+++ b/bfdd/ptm_adapter.c
@@ -673,19 +673,10 @@ void bfdd_sessions_disable_vrf(struct vrf *vrf)
}
}
-static int bfdd_interface_update(ZAPI_CALLBACK_ARGS)
+static int bfd_ifp_destroy(struct interface *ifp)
{
- struct interface *ifp;
-
- /* Update interface information. */
- ifp = zebra_interface_state_read(zclient->ibuf, vrf_id);
- if (ifp == NULL)
- return 0;
-
bfdd_sessions_disable_interface(ifp);
- if_set_index(ifp, IFINDEX_INTERNAL);
-
return 0;
}
@@ -749,11 +740,6 @@ static int bfd_ifp_create(struct interface *ifp)
return 0;
}
-static int bfd_ifp_destroy(struct interface *ifp)
-{
- return 0;
-}
-
void bfdd_zclient_init(struct zebra_privs_t *bfdd_priv)
{
if_zapi_callbacks(bfd_ifp_create, NULL, NULL, bfd_ifp_destroy);
@@ -771,9 +757,6 @@ void bfdd_zclient_init(struct zebra_privs_t *bfdd_priv)
/* Send replay request on zebra connect. */
zclient->zebra_connected = bfdd_zebra_connected;
- /* Learn interfaces from zebra instead of the OS. */
- zclient->interface_delete = bfdd_interface_update;
-
/* Learn about interface VRF. */
zclient->interface_vrf_update = bfdd_interface_vrf_update;