]> git.puffer.fish Git - matthieu/frr.git/commitdiff
Zebra: Fix ptm-enable config failure on internally created interfaces
authorradhika <radhika@cumulusnetworks.com>
Tue, 1 Aug 2017 17:10:35 +0000 (10:10 -0700)
committerDonald Sharp <sharpd@cumulusnetworks.com>
Tue, 8 May 2018 23:24:15 +0000 (19:24 -0400)
Ticket: CM-15658
Reviewed By: CCR-6534
Testing Done: Unit

Issue: frr ptm-enable command not working for interfaces that have been created by frr as a place holder.

Root Cause: The ptm-enable on interface configuration was not getting stored when the interface was internally created by frr.

Fix: Store the ptm-enable configuration even if the interface is internally created.

Signed-off-by: Radhika Mahankali <radhika@cumulusnetworks.com>
zebra/zebra_ptm.c

index 07e81aa02008a112a36bbfeafa1aabd7309f62b4..d20f93f521a8bdf65513b6058aa64c013dea8dbc 100644 (file)
@@ -298,6 +298,9 @@ DEFUN (zebra_ptm_enable_if,
        int old_ptm_enable;
        int send_linkdown = 0;
 
+       if_data = ifp->info;
+       if_data->ptm_enable = ZEBRA_IF_PTM_ENABLE_UNSPEC;
+
        if (ifp->ifindex == IFINDEX_INTERNAL) {
                return CMD_SUCCESS;
        }
@@ -317,9 +320,6 @@ DEFUN (zebra_ptm_enable_if,
                }
        }
 
-       if_data = ifp->info;
-       if_data->ptm_enable = ZEBRA_IF_PTM_ENABLE_UNSPEC;
-
        return CMD_SUCCESS;
 }