}
/* interface start */
- if (oi->area)
- thread_add_event (master, interface_up, oi, 0);
+ ospf6_interface_state_update(oi->interface);
}
void
if (CHECK_FLAG (oi->flag, OSPF6_INTERFACE_DISABLE))
return;
- if (if_is_operative (ifp))
+ if (if_is_operative (ifp)
+ && (ospf6_interface_get_linklocal_address(oi->interface)
+ || if_is_loopback(oi->interface)))
thread_add_event (master, interface_up, oi, 0);
else
thread_add_event (master, interface_down, oi, 0);
return 0;
}
+ /* check interface has a link-local address */
+ if (! (ospf6_interface_get_linklocal_address(oi->interface)
+ || if_is_loopback(oi->interface)))
+ {
+ if (IS_OSPF6_DEBUG_INTERFACE)
+ zlog_debug ("Interface %s has no link local address, can't execute [InterfaceUp]",
+ oi->interface->name);
+ return 0;
+ }
+
/* if already enabled, do nothing */
if (oi->state > OSPF6_INTERFACE_DOWN)
{
buf, sizeof (buf)), c->address->prefixlen);
if (c->address->family == AF_INET6)
- ospf6_interface_connected_route_update (c->ifp);
-
+ {
+ ospf6_interface_state_update (c->ifp);
+ ospf6_interface_connected_route_update (c->ifp);
+ }
return 0;
}
buf, sizeof (buf)), c->address->prefixlen);
if (c->address->family == AF_INET6)
- ospf6_interface_connected_route_update (c->ifp);
+ {
+ ospf6_interface_connected_route_update (c->ifp);
+ ospf6_interface_state_update (c->ifp);
+ }
return 0;
}