diff --git a/src/devices/nm-device.c b/src/devices/nm-device.c index 1597d18fa..87bebdb1e 100644 --- a/src/devices/nm-device.c +++ b/src/devices/nm-device.c @@ -2994,9 +2994,7 @@ act_stage3_ip4_config_start (NMDevice *self, connection = nm_device_get_connection (self); g_assert (connection); - method = nm_utils_get_ip_config_method (connection, NM_TYPE_SETTING_IP4_CONFIG); - - if ( strcmp (method, NM_SETTING_IP4_CONFIG_METHOD_MANUAL) != 0 + if ( connection_ip4_method_requires_carrier (connection, NULL) && priv->is_master && !priv->carrier) { _LOGI (LOGD_IP4 | LOGD_DEVICE, @@ -3019,6 +3017,8 @@ act_stage3_ip4_config_start (NMDevice *self, } } + method = nm_utils_get_ip_config_method (connection, NM_TYPE_SETTING_IP4_CONFIG); + /* Start IPv4 addressing based on the method requested */ if (strcmp (method, NM_SETTING_IP4_CONFIG_METHOD_AUTO) == 0) ret = dhcp4_start (self, connection, reason); @@ -4011,9 +4011,7 @@ act_stage3_ip6_config_start (NMDevice *self, connection = nm_device_get_connection (self); g_assert (connection); - method = nm_utils_get_ip_config_method (connection, NM_TYPE_SETTING_IP6_CONFIG); - - if ( strcmp (method, NM_SETTING_IP6_CONFIG_METHOD_MANUAL) != 0 + if ( connection_ip4_method_requires_carrier (connection, NULL) && priv->is_master && !priv->carrier) { _LOGI (LOGD_IP6 | LOGD_DEVICE, @@ -4038,6 +4036,8 @@ act_stage3_ip6_config_start (NMDevice *self, priv->dhcp6_mode = NM_RDISC_DHCP_LEVEL_NONE; + method = nm_utils_get_ip_config_method (connection, NM_TYPE_SETTING_IP6_CONFIG); + if (strcmp (method, NM_SETTING_IP6_CONFIG_METHOD_IGNORE) == 0) { if (!priv->master) { /* When activating an IPv6 'ignore' connection we need to revert back