summaryrefslogtreecommitdiff
path: root/bgpd
diff options
context:
space:
mode:
Diffstat (limited to 'bgpd')
-rw-r--r--bgpd/bgp_fsm.c2
-rw-r--r--bgpd/bgp_packet.c24
-rw-r--r--bgpd/bgp_route.c17
-rw-r--r--bgpd/bgp_zebra.c33
4 files changed, 1 insertions, 75 deletions
diff --git a/bgpd/bgp_fsm.c b/bgpd/bgp_fsm.c
index 6121e74a..c815f9a1 100644
--- a/bgpd/bgp_fsm.c
+++ b/bgpd/bgp_fsm.c
@@ -427,7 +427,7 @@ bgp_fsm_change_status (struct peer *peer, int status)
}
/* Flush the event queue and ensure the peer is shut down */
-int
+static int
bgp_clearing_completed (struct peer *peer)
{
int rc = bgp_stop(peer);
diff --git a/bgpd/bgp_packet.c b/bgpd/bgp_packet.c
index 1c9a3c91..61534191 100644
--- a/bgpd/bgp_packet.c
+++ b/bgpd/bgp_packet.c
@@ -920,30 +920,6 @@ bgp_notify_send (struct peer *peer, u_char code, u_char sub_code)
bgp_notify_send_with_data (peer, code, sub_code, NULL, 0);
}
-static const char *
-afi2str (afi_t afi)
-{
- if (afi == AFI_IP)
- return "AFI_IP";
- else if (afi == AFI_IP6)
- return "AFI_IP6";
- else
- return "Unknown AFI";
-}
-
-static const char *
-safi2str (safi_t safi)
-{
- if (safi == SAFI_UNICAST)
- return "SAFI_UNICAST";
- else if (safi == SAFI_MULTICAST)
- return "SAFI_MULTICAST";
- else if (safi == SAFI_MPLS_VPN || safi == BGP_SAFI_VPNV4)
- return "SAFI_MPLS_VPN";
- else
- return "Unknown SAFI";
-}
-
/* Send route refresh message to the peer. */
void
bgp_route_refresh_send (struct peer *peer, afi_t afi, safi_t safi,
diff --git a/bgpd/bgp_route.c b/bgpd/bgp_route.c
index 20880396..f3144fea 100644
--- a/bgpd/bgp_route.c
+++ b/bgpd/bgp_route.c
@@ -11031,23 +11031,6 @@ bgp_distance_unset (struct vty *vty, const char *distance_str,
return CMD_SUCCESS;
}
-static void
-bgp_distance_reset (void)
-{
- struct bgp_node *rn;
- struct bgp_distance *bdistance;
-
- for (rn = bgp_table_top (bgp_distance_table); rn; rn = bgp_route_next (rn))
- if ((bdistance = rn->info) != NULL)
- {
- if (bdistance->access_list)
- free (bdistance->access_list);
- bgp_distance_free (bdistance);
- rn->info = NULL;
- bgp_unlock_node (rn);
- }
-}
-
/* Apply BGP information to distance method. */
u_char
bgp_distance_apply (struct prefix *p, struct bgp_info *rinfo, struct bgp *bgp)
diff --git a/bgpd/bgp_zebra.c b/bgpd/bgp_zebra.c
index 49380cc3..f3baeee0 100644
--- a/bgpd/bgp_zebra.c
+++ b/bgpd/bgp_zebra.c
@@ -639,39 +639,6 @@ bgp_nexthop_set (union sockunion *local, union sockunion *remote,
return ret;
}
-#ifdef HAVE_IPV6
-static unsigned int
-bgp_ifindex_by_nexthop (struct in6_addr *addr)
-{
- struct listnode *ifnode;
- struct listnode *cnode;
- struct interface *ifp;
- struct connected *connected;
- struct prefix_ipv6 p;
-
- p.family = AF_INET6;
- p.prefix = *addr;
- p.prefixlen = IPV6_MAX_BITLEN;
-
- for (ALL_LIST_ELEMENTS_RO (iflist, ifnode, ifp))
- {
- for (ALL_LIST_ELEMENTS_RO (ifp->connected, cnode, connected))
- {
- struct prefix *cp;
-
- cp = connected->address;
-
- if (cp->family == AF_INET6)
- {
- if (prefix_match (cp, (struct prefix *)&p))
- return ifp->ifindex;
- }
- }
- }
- return 0;
-}
-#endif /* HAVE_IPV6 */
-
void
bgp_zebra_announce (struct prefix *p, struct bgp_info *info, struct bgp *bgp)
{