networkd-ndisc: do not start DHCPv6 when after NDISC timeout
authorTom Yan <tom.ty89@gmail.com>
Wed, 1 Jun 2016 17:05:50 +0000 (01:05 +0800)
committerTom Yan <tom.ty89@gmail.com>
Wed, 1 Jun 2016 17:05:50 +0000 (01:05 +0800)
For it's silly and unnecessary. Although it was apparently mandated by RFC 2462 in [5.5.2. Absence of Router Advertisements], that has been changed in the same section of RFC 4862, which obsoleted the former RFC.

src/network/networkd-ndisc.c

index db9be02..7359cc2 100644 (file)
@@ -197,21 +197,12 @@ static void ndisc_handler(sd_ndisc *nd, int event, void *userdata) {
         int r;
 
         assert(link);
-        assert(link->dhcp6_client);
-        assert(in_addr_is_link_local(AF_INET6, (const union in_addr_union*)&link->ipv6ll_address) > 0);
 
         if (IN_SET(link->state, LINK_STATE_FAILED, LINK_STATE_LINGER))
                 return;
 
         switch (event) {
         case SD_NDISC_EVENT_TIMEOUT:
-                /* (re)start DHCPv6 client in stateful mode */
-                r = dhcp6_request_address(link, false);
-                if (r < 0 && r != -EBUSY)
-                        log_link_warning_errno(link, r, "Could not acquire DHCPv6 lease after NDisc timeout: %m");
-                else
-                        log_link_debug(link, "Acquiring DHCPv6 lease after NDisc timeout");
-
                 link->ndisc_configured = true;
                 link_check_ready(link);