diff options
| author | Michael Biebl <biebl@debian.org> | 2020-03-13 00:44:14 +0100 |
|---|---|---|
| committer | Michael Biebl <biebl@debian.org> | 2020-03-13 00:44:14 +0100 |
| commit | b012fa6e1d808e0736c009799c62d835cbfcc1dd (patch) | |
| tree | ff9a3777f6740e91b55f0a566914bfe4ab37935f /src/devices | |
| parent | e536d40eaea5dcdc0743b0a5e8e17faa46608a50 (diff) | |
New upstream version 1.22.10 upstream/1.22.10
Diffstat (limited to 'src/devices')
| -rw-r--r-- | src/devices/nm-device-bond.c | 11 | ||||
| -rw-r--r-- | src/devices/nm-device-ethernet.c | 4 | ||||
| -rw-r--r-- | src/devices/nm-device.c | 6 | ||||
| -rw-r--r-- | src/devices/ovs/nm-device-ovs-port.c | 13 | ||||
| -rw-r--r-- | src/devices/wwan/nm-modem-broadband.c | 10 |
5 files changed, 23 insertions, 21 deletions
diff --git a/src/devices/nm-device-bond.c b/src/devices/nm-device-bond.c index c6ecb2e8..36d00328 100644 --- a/src/devices/nm-device-bond.c +++ b/src/devices/nm-device-bond.c @@ -214,7 +214,7 @@ apply_bonding_config (NMDeviceBond *self) * * arp_interval conflicts miimon > 0 * arp_interval conflicts [ alb, tlb ] - * arp_validate needs [ active-backup ] + * arp_validate does not work with [ BOND_MODE_8023AD, BOND_MODE_TLB, BOND_MODE_ALB ] * downdelay needs miimon * updelay needs miimon * primary needs [ active-backup, tlb, alb ] @@ -266,15 +266,8 @@ apply_bonding_config (NMDeviceBond *self) */ } - /* ARP validate: value > 0 only valid in active-backup mode */ value = nm_setting_bond_get_option_by_name (s_bond, NM_SETTING_BOND_OPTION_ARP_VALIDATE); - if ( value - && !nm_streq (value, "0") - && !nm_streq (value, "none") - && mode == NM_BOND_MODE_ACTIVEBACKUP) - set_bond_attr (device, mode, NM_SETTING_BOND_OPTION_ARP_VALIDATE, value); - else - set_bond_attr (device, mode, NM_SETTING_BOND_OPTION_ARP_VALIDATE, "0"); + set_bond_attr (device, mode, NM_SETTING_BOND_OPTION_ARP_VALIDATE, value ?: "0"); /* Primary */ value = nm_setting_bond_get_option_by_name (s_bond, NM_SETTING_BOND_OPTION_PRIMARY); diff --git a/src/devices/nm-device-ethernet.c b/src/devices/nm-device-ethernet.c index 6b80c4ed..86e50c52 100644 --- a/src/devices/nm-device-ethernet.c +++ b/src/devices/nm-device-ethernet.c @@ -1242,7 +1242,7 @@ dcb_state (NMDevice *device, gboolean timeout) break; } _LOGD (LOGD_DCB, "dcb_state() preconfig down falling through"); - /* fall through */ + /* fall-through */ case DCB_WAIT_CARRIER_PRECONFIG_UP: if (timeout || carrier) { _LOGD (LOGD_DCB, "dcb_state() preconfig up configuring DCB"); @@ -1266,7 +1266,7 @@ dcb_state (NMDevice *device, gboolean timeout) break; } _LOGD (LOGD_DCB, "dcb_state() postconfig down falling through"); - /* fall through */ + /* fall-through */ case DCB_WAIT_CARRIER_POSTCONFIG_UP: if (timeout || carrier) { _LOGD (LOGD_DCB, "dcb_state() postconfig up starting IP"); diff --git a/src/devices/nm-device.c b/src/devices/nm-device.c index 3bbc9757..72ec29a1 100644 --- a/src/devices/nm-device.c +++ b/src/devices/nm-device.c @@ -8005,7 +8005,7 @@ dhcp4_state_changed (NMDhcpClient *client, /* Ignore expiry before we even have a lease (NAK, old lease, etc) */ if (priv->ip_state_4 == NM_DEVICE_IP_STATE_CONF) break; - /* fall through */ + /* fall-through */ case NM_DHCP_STATE_DONE: case NM_DHCP_STATE_FAIL: case NM_DHCP_STATE_TERMINATED: @@ -8812,7 +8812,7 @@ dhcp6_state_changed (NMDhcpClient *client, */ if (priv->dhcp6.mode == NM_NDISC_DHCP_LEVEL_OTHERCONF) break; - /* fall through */ + /* fall-through */ case NM_DHCP_STATE_DONE: case NM_DHCP_STATE_FAIL: dhcp6_fail (self, state); @@ -13858,7 +13858,7 @@ device_ipx_changed (NMPlatform *platform, (gpointer) nmp_object_ref (NMP_OBJECT_UP_CAST (addr))); } - /* fall through */ + /* fall-through */ case NMP_OBJECT_TYPE_IP6_ROUTE: if (!priv->queued_ip_config_id_6) { priv->queued_ip_config_id_6 = g_idle_add (queued_ip6_config_change, self); diff --git a/src/devices/ovs/nm-device-ovs-port.c b/src/devices/ovs/nm-device-ovs-port.c index 0955e8a9..e0216377 100644 --- a/src/devices/ovs/nm-device-ovs-port.c +++ b/src/devices/ovs/nm-device-ovs-port.c @@ -86,6 +86,7 @@ add_iface_cb (GError *error, gpointer user_data) static gboolean enslave_slave (NMDevice *device, NMDevice *slave, NMConnection *connection, gboolean configure) { + NMDeviceOvsPort *self = NM_DEVICE_OVS_PORT (device); NMActiveConnection *ac_port = NULL; NMActiveConnection *ac_bridge = NULL; NMDevice *bridge_device; @@ -95,10 +96,18 @@ enslave_slave (NMDevice *device, NMDevice *slave, NMConnection *connection, gboo ac_port = NM_ACTIVE_CONNECTION (nm_device_get_act_request (device)); ac_bridge = nm_active_connection_get_master (ac_port); - if (!ac_bridge) - ac_bridge = ac_port; + if (!ac_bridge) { + _LOGW (LOGD_DEVICE, "can't enslave %s: bridge active-connection not found", + nm_device_get_iface (slave)); + return FALSE; + } bridge_device = nm_active_connection_get_device (ac_bridge); + if (!bridge_device) { + _LOGW (LOGD_DEVICE, "can't enslave %s: bridge device not found", + nm_device_get_iface (slave)); + return FALSE; + } nm_ovsdb_add_interface (nm_ovsdb_get (), nm_active_connection_get_applied_connection (ac_bridge), diff --git a/src/devices/wwan/nm-modem-broadband.c b/src/devices/wwan/nm-modem-broadband.c index a1ae8671..947aa4c8 100644 --- a/src/devices/wwan/nm-modem-broadband.c +++ b/src/devices/wwan/nm-modem-broadband.c @@ -548,7 +548,7 @@ connect_context_step (NMModemBroadband *self) switch (ctx->step) { case CONNECT_STEP_FIRST: ctx->step++; - /* fall through */ + /* fall-through */ case CONNECT_STEP_WAIT_FOR_SIM: if (MODEM_CAPS_3GPP (ctx->caps) && !self->_priv.sim_iface) { @@ -556,7 +556,7 @@ connect_context_step (NMModemBroadband *self) break; } ctx->step++; - /* fall through */ + /* fall-through */ case CONNECT_STEP_UNLOCK: if ( MODEM_CAPS_3GPP (ctx->caps) @@ -577,7 +577,7 @@ connect_context_step (NMModemBroadband *self) break; } ctx->step++; - /* fall through */ + /* fall-through */ case CONNECT_STEP_WAIT_FOR_READY: { GError *error = NULL; @@ -605,7 +605,7 @@ connect_context_step (NMModemBroadband *self) ctx->step++; } - /* fall through */ + /* fall-through */ case CONNECT_STEP_CONNECT: if (!ctx->connect_properties) break; @@ -639,7 +639,7 @@ connect_context_step (NMModemBroadband *self) } ctx->step++; - /* fall through */ + /* fall-through */ case CONNECT_STEP_LAST: if (self->_priv.ipv4_config || self->_priv.ipv6_config) |