summaryrefslogtreecommitdiffstats
path: root/lib/if.c
diff options
context:
space:
mode:
authorChirag Shah <chirag@cumulusnetworks.com>2018-03-06 21:55:59 +0100
committerChirag Shah <chirag@cumulusnetworks.com>2018-03-08 22:15:58 +0100
commit0c74bbe03e7e47af698e3f74a4eddec190193063 (patch)
tree12e29b3977ced79c9dfab8bb642b2f5df941e8b6 /lib/if.c
parentzebra: set vrf as loopback upon interface add (diff)
downloadfrr-0c74bbe03e7e47af698e3f74a4eddec190193063.tar.xz
frr-0c74bbe03e7e47af698e3f74a4eddec190193063.zip
ospfd: Treat vrf interface as loopback type
Ticket:CM-19914 Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
Diffstat (limited to 'lib/if.c')
-rw-r--r--lib/if.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/if.c b/lib/if.c
index c00418bac..2541e6e45 100644
--- a/lib/if.c
+++ b/lib/if.c
@@ -476,6 +476,12 @@ int if_is_loopback(struct interface *ifp)
return (ifp->flags & (IFF_LOOPBACK | IFF_NOXMIT | IFF_VIRTUAL));
}
+/* Check interface is VRF */
+int if_is_vrf(struct interface *ifp)
+{
+ return CHECK_FLAG(ifp->status, ZEBRA_INTERFACE_VRF_LOOPBACK);
+}
+
/* Does this interface support broadcast ? */
int if_is_broadcast(struct interface *ifp)
{