summaryrefslogtreecommitdiff
path: root/lib/vrf.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/vrf.c')
-rw-r--r--lib/vrf.c16
1 files changed, 2 insertions, 14 deletions
diff --git a/lib/vrf.c b/lib/vrf.c
index a9a5a83794..b5f06048b7 100644
--- a/lib/vrf.c
+++ b/lib/vrf.c
@@ -354,13 +354,6 @@ const char *vrf_id_to_name(vrf_id_t vrf_id)
return VRF_LOGNAME(vrf);
}
-/* Get the data pointer of the specified VRF. If not found, create one. */
-void *vrf_info_get(vrf_id_t vrf_id)
-{
- struct vrf *vrf = vrf_get(vrf_id, NULL);
- return vrf->info;
-}
-
/* Look up the data pointer of the specified VRF. */
void *vrf_info_lookup(vrf_id_t vrf_id)
{
@@ -697,15 +690,10 @@ DEFUN_YANG (no_vrf,
if (vrf_get_backend() == VRF_BACKEND_VRF_LITE) {
/*
- * Remove the VRF interface config. Currently, we allow to
- * remove only inactive VRFs, so we use VRF_DEFAULT_NAME here,
- * because when the VRF is removed from kernel, the interface
- * is moved to the default VRF. If we ever allow removing
- * active VRFs, this code have to be updated accordingly.
+ * Remove the VRF interface config when removing the VRF.
*/
snprintf(xpath_list, sizeof(xpath_list),
- "/frr-interface:lib/interface[name='%s'][vrf='%s']",
- vrfname, VRF_DEFAULT_NAME);
+ "/frr-interface:lib/interface[name='%s']", vrfname);
nb_cli_enqueue_change(vty, xpath_list, NB_OP_DESTROY, NULL);
}