mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-05-02 17:48:07 +02:00
bonding: wait for master connection to be available
Currently slaves only wait for the master device to be present. This is insufficient, we want to wait for the master connection to be activated. Signed-off-by: Thomas Graf <tgraf@redhat.com>
This commit is contained in:
parent
0ec51387c0
commit
6346bd60be
1 changed files with 6 additions and 0 deletions
|
|
@ -736,6 +736,7 @@ check_master_dependency (NMManager *manager, NMDevice *device, NMConnection *con
|
|||
NMSettingConnection *s_con;
|
||||
NMDevice *master_device;
|
||||
const char *master;
|
||||
NMActRequest *req;
|
||||
|
||||
s_con = nm_connection_get_setting_connection (connection);
|
||||
g_assert (s_con);
|
||||
|
|
@ -752,6 +753,11 @@ check_master_dependency (NMManager *manager, NMDevice *device, NMConnection *con
|
|||
if (!master_device)
|
||||
return FALSE;
|
||||
|
||||
/* Make all slaves wait for the master connection to activate. */
|
||||
req = nm_device_get_act_request (master_device);
|
||||
if (!req || !nm_act_request_get_connection (req))
|
||||
return FALSE;
|
||||
|
||||
nm_device_set_master (device, master_device);
|
||||
|
||||
return TRUE;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue