mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-01-22 12:35:17 +00:00
call virDomainNetNotifyActualDevice() for all interface types
Now that this function can be called regardless of interface type (and whether or not we have a conn for the network driver), let's actually call it for all interface types. This will assure that we re-connect any disconnected bridge devices for <interface type='bridge'> as mentioned in https://bugzilla.redhat.com/show_bug.cgi?id=1730084#c26 (until now we've only been reconnecting bridge devices for <interface type='network'>) Signed-off-by: Laine Stump <laine@redhat.com> Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
This commit is contained in:
parent
dad50cf855
commit
c2b2cdf746
@ -367,11 +367,10 @@ libxlReconnectNotifyNets(virDomainDefPtr def)
|
||||
if (virDomainNetGetActualType(net) == VIR_DOMAIN_NET_TYPE_DIRECT)
|
||||
virNetDevReserveName(net->ifname);
|
||||
|
||||
if (net->type == VIR_DOMAIN_NET_TYPE_NETWORK) {
|
||||
if (!conn && !(conn = virGetConnectNetwork()))
|
||||
continue;
|
||||
virDomainNetNotifyActualDevice(conn, def, net);
|
||||
}
|
||||
if (net->type == VIR_DOMAIN_NET_TYPE_NETWORK && !conn)
|
||||
conn = virGetConnectNetwork();
|
||||
|
||||
virDomainNetNotifyActualDevice(conn, def, net);
|
||||
}
|
||||
|
||||
virObjectUnref(conn);
|
||||
|
@ -1663,11 +1663,10 @@ virLXCProcessReconnectNotifyNets(virDomainDefPtr def)
|
||||
break;
|
||||
}
|
||||
|
||||
if (net->type == VIR_DOMAIN_NET_TYPE_NETWORK) {
|
||||
if (!conn && !(conn = virGetConnectNetwork()))
|
||||
continue;
|
||||
virDomainNetNotifyActualDevice(conn, def, net);
|
||||
}
|
||||
if (net->type == VIR_DOMAIN_NET_TYPE_NETWORK && !conn)
|
||||
conn = virGetConnectNetwork();
|
||||
|
||||
virDomainNetNotifyActualDevice(conn, def, net);
|
||||
}
|
||||
|
||||
virObjectUnref(conn);
|
||||
|
@ -3411,11 +3411,10 @@ qemuProcessNotifyNets(virDomainDefPtr def)
|
||||
break;
|
||||
}
|
||||
|
||||
if (net->type == VIR_DOMAIN_NET_TYPE_NETWORK) {
|
||||
if (!conn && !(conn = virGetConnectNetwork()))
|
||||
continue;
|
||||
virDomainNetNotifyActualDevice(conn, def, net);
|
||||
}
|
||||
if (net->type == VIR_DOMAIN_NET_TYPE_NETWORK && !conn)
|
||||
conn = virGetConnectNetwork();
|
||||
|
||||
virDomainNetNotifyActualDevice(conn, def, net);
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user