summaryrefslogtreecommitdiff
path: root/zebra/connected.c
diff options
context:
space:
mode:
Diffstat (limited to 'zebra/connected.c')
-rw-r--r--zebra/connected.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/zebra/connected.c b/zebra/connected.c
index 41b68d1564..f67b44ba80 100644
--- a/zebra/connected.c
+++ b/zebra/connected.c
@@ -36,6 +36,7 @@
#include "zebra/redistribute.h"
#include "zebra/interface.h"
#include "zebra/connected.h"
+#include "zebra/rtadv.h"
extern struct zebra_t zebrad;
/* communicate the withdrawal of a connected address */
@@ -71,6 +72,10 @@ connected_withdraw (struct connected *ifc)
listnode_delete (ifc->ifp->connected, ifc);
connected_free (ifc);
}
+
+ /* Enable RA suppression if there are no IPv6 addresses on this interface */
+ if (! ipv6_address_configured(ifc->ifp))
+ ipv6_nd_suppress_ra_set (ifc->ifp, RA_SUPPRESS);
}
static void
@@ -93,6 +98,9 @@ connected_announce (struct interface *ifp, struct connected *ifc)
if (ifc->address->family == AF_INET)
if_subnet_add (ifp, ifc);
+ else if (ifc->address->family == AF_INET6)
+ ipv6_nd_suppress_ra_set (ifp, RA_ENABLE);
+
zebra_interface_address_add_update (ifp, ifc);
if (if_is_operative(ifp))