diff options
author | Donald Sharp <sharpd@cumulusnetworks.com> | 2017-03-10 21:48:43 +0100 |
---|---|---|
committer | Donald Sharp <sharpd@cumulusnetworks.com> | 2017-03-15 15:29:09 +0100 |
commit | 4e5266b8a3fb5f1928a610bf86739b415d078bee (patch) | |
tree | 88515e1cfb8e55af85d2dc38f9ccda269d8c6a8c /lib/if.c | |
parent | *: Remove non-vrf based ifindex lookup (diff) | |
download | frr-4e5266b8a3fb5f1928a610bf86739b415d078bee.tar.xz frr-4e5266b8a3fb5f1928a610bf86739b415d078bee.zip |
lib, ospfd, pimd: Convert to using VRF based interface creation
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
Diffstat (limited to 'lib/if.c')
-rw-r--r-- | lib/if.c | 12 |
1 files changed, 3 insertions, 9 deletions
@@ -123,7 +123,7 @@ if_cmp_func (struct interface *ifp1, struct interface *ifp2) /* Create new interface structure. */ struct interface * -if_create_vrf (const char *name, int namelen, vrf_id_t vrf_id) +if_create (const char *name, int namelen, vrf_id_t vrf_id) { struct interface *ifp; struct list *intf_list = vrf_iflist_get (vrf_id); @@ -158,12 +158,6 @@ if_create_vrf (const char *name, int namelen, vrf_id_t vrf_id) return ifp; } -struct interface * -if_create (const char *name, int namelen) -{ - return if_create_vrf (name, namelen, VRF_DEFAULT); -} - /* Create new interface structure. */ void if_update_vrf (struct interface *ifp, const char *name, int namelen, vrf_id_t vrf_id) @@ -468,7 +462,7 @@ if_get_by_name_vrf (const char *name, vrf_id_t vrf_id) struct interface *ifp; return ((ifp = if_lookup_by_name_vrf (name, vrf_id)) != NULL) ? ifp : - if_create_vrf (name, strlen(name), vrf_id); + if_create (name, strlen(name), vrf_id); } struct interface * @@ -515,7 +509,7 @@ if_get_by_name_len_vrf (const char *name, size_t namelen, vrf_id_t vrf_id, int v } } } - return (if_create_vrf (name, namelen, vrf_id)); + return (if_create (name, namelen, vrf_id)); } struct interface * |