diff options
author | Beniamino Galvani <bgalvani@redhat.com> | 2022-12-16 09:43:20 +0100 |
---|---|---|
committer | Beniamino Galvani <bgalvani@redhat.com> | 2022-12-19 10:46:32 +0100 |
commit | bdd826a0441965e4f8c6f2936f0e69c3c0621828 (patch) | |
tree | 5dda950dd737f51b869a7dbe5902f13da3280c6e | |
parent | 0da9f059e106e669209460bc54faf675454d958a (diff) | |
download | NetworkManager-bdd826a0441965e4f8c6f2936f0e69c3c0621828.tar.gz |
veth: improve comment about skipping creation of interfaces
-rw-r--r-- | src/core/devices/nm-device-veth.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/core/devices/nm-device-veth.c b/src/core/devices/nm-device-veth.c index 82762ba9b2..44d4052ea1 100644 --- a/src/core/devices/nm-device-veth.c +++ b/src/core/devices/nm-device-veth.c @@ -98,11 +98,14 @@ create_and_realize(NMDevice *device, return FALSE; } + /* For veths, users can define two connection profiles referencing each + * other as 'veth.peer'. Only the first to be activated will actually + * create the veth pair; the other must detect that interfaces already + * exist and proceed. */ peer = nm_setting_veth_get_peer(s_veth); peer_device = nm_manager_get_device(NM_MANAGER_GET, peer, NM_DEVICE_TYPE_VETH); if (peer_device) { if (nm_device_parent_get_device(peer_device)) - /* The veth device and its peer already exist. No need to create it again. */ return TRUE; } |