rib_add(afi, SAFI_MULTICAST, zvrf->vrf->vrf_id, ZEBRA_ROUTE_CONNECT,
0, 0, &p, NULL, &nh, zvrf->table_id, metric, 0, 0, 0);
- if (IS_ZEBRA_DEBUG_RIB_DETAILED) {
- char buf[PREFIX_STRLEN];
-
- zlog_debug(
- "%u: IF %s address %s add/up, scheduling RIB processing",
- ifp->vrf_id, ifp->name,
- prefix2str(&p, buf, sizeof(buf)));
- }
- rib_update(zvrf->vrf->vrf_id, RIB_UPDATE_IF_CHANGE);
-
/* Schedule LSP forwarding entries for processing, if appropriate. */
if (zvrf->vrf->vrf_id == VRF_DEFAULT) {
if (IS_ZEBRA_DEBUG_MPLS) {
rib_delete(afi, SAFI_MULTICAST, zvrf->vrf->vrf_id, ZEBRA_ROUTE_CONNECT,
0, 0, &p, NULL, &nh, zvrf->table_id, 0, 0, false);
- if (IS_ZEBRA_DEBUG_RIB_DETAILED) {
- char buf[PREFIX_STRLEN];
-
- zlog_debug(
- "%u: IF %s IP %s address down, scheduling RIB processing",
- zvrf->vrf->vrf_id, ifp->name,
- prefix2str(&p, buf, sizeof(buf)));
- }
-
- rib_update(zvrf->vrf->vrf_id, RIB_UPDATE_IF_CHANGE);
-
/* Schedule LSP forwarding entries for processing, if appropriate. */
if (zvrf->vrf->vrf_id == VRF_DEFAULT) {
if (IS_ZEBRA_DEBUG_MPLS) {
connected_withdraw(ifc);
- if (IS_ZEBRA_DEBUG_RIB_DETAILED) {
- char buf[PREFIX_STRLEN];
-
- zlog_debug(
- "%u: IF %s IP %s address del, scheduling RIB processing",
- ifp->vrf_id, ifp->name,
- prefix2str(p, buf, sizeof(buf)));
- }
- rib_update(ifp->vrf_id, RIB_UPDATE_IF_CHANGE);
-
/* Schedule LSP forwarding entries for processing, if appropriate. */
if (ifp->vrf_id == VRF_DEFAULT) {
if (IS_ZEBRA_DEBUG_MPLS) {
/* Install connected routes (in new VRF). */
if (if_is_operative(ifp))
if_install_connected(ifp);
-
- /* Due to connected route change, schedule RIB processing for both old
- * and new VRF.
- */
- if (IS_ZEBRA_DEBUG_RIB_DETAILED)
- zlog_debug("%u: IF %s VRF change, scheduling RIB processing",
- ifp->vrf_id, ifp->name);
- rib_update(old_vrf_id, RIB_UPDATE_IF_CHANGE);
- rib_update(ifp->vrf_id, RIB_UPDATE_IF_CHANGE);
}
static void ipv6_ll_address_to_mac(struct in6_addr *address, uint8_t *mac)
/* Install connected routes to the kernel. */
if_install_connected(ifp);
- if (IS_ZEBRA_DEBUG_RIB_DETAILED)
- zlog_debug("%u: IF %s up, scheduling RIB processing",
- ifp->vrf_id, ifp->name);
- rib_update(ifp->vrf_id, RIB_UPDATE_IF_CHANGE);
-
/* Handle interface up for specific types for EVPN. Non-VxLAN interfaces
* are checked to see if (remote) neighbor entries need to be installed
* on them for ARP suppression.
/* Uninstall connected routes from the kernel. */
if_uninstall_connected(ifp);
- if (IS_ZEBRA_DEBUG_RIB_DETAILED)
- zlog_debug("%u: IF %s down, scheduling RIB processing",
- ifp->vrf_id, ifp->name);
- rib_update(ifp->vrf_id, RIB_UPDATE_IF_CHANGE);
-
if_nbr_ipv6ll_to_ipv4ll_neigh_del_all(ifp);
/* Delete all neighbor addresses learnt through IPv6 RA */
/* Events/reasons triggering a RIB update. */
typedef enum {
- RIB_UPDATE_IF_CHANGE,
RIB_UPDATE_RMAP_CHANGE,
RIB_UPDATE_OTHER
} rib_update_event_t;
RIB_ROUTE_ANY_QUEUED))
continue;
switch (event) {
- case RIB_UPDATE_IF_CHANGE:
- /* Examine all routes that won't get processed by the
- * protocol or
- * triggered by nexthop evaluation (NHT). This would be
- * system,
- * kernel and certain static routes. Note that NHT will
- * get
- * triggered upon an interface event as connected routes
- * always
- * get queued for processing.
- */
- RNODE_FOREACH_RE_SAFE (rn, re, next) {
- struct nexthop *nh;
-
- if (re->type != ZEBRA_ROUTE_SYSTEM
- && re->type != ZEBRA_ROUTE_KERNEL
- && re->type != ZEBRA_ROUTE_CONNECT
- && re->type != ZEBRA_ROUTE_STATIC)
- continue;
-
- if (re->type != ZEBRA_ROUTE_STATIC) {
- SET_FLAG(re->status,
- ROUTE_ENTRY_CHANGED);
- rib_queue_add(rn);
- continue;
- }
-
- for (nh = re->ng.nexthop; nh; nh = nh->next)
- if (!(nh->type == NEXTHOP_TYPE_IPV4
- || nh->type == NEXTHOP_TYPE_IPV6))
- break;
-
- /* If we only have nexthops to a
- * gateway, NHT will
- * take care.
- */
- if (nh) {
- SET_FLAG(re->status,
- ROUTE_ENTRY_CHANGED);
- rib_queue_add(rn);
- }
- }
- break;
-
case RIB_UPDATE_RMAP_CHANGE:
case RIB_UPDATE_OTHER:
/* Right now, examine all routes. Can restrict to a