Skip to content

ovs: rework asynchronous deactivation of ovs interfaces

Beniamino Galvani requested to merge bg/ovs-deactivate-async-pt2 into master

Tracking the deletion of link by ifindex is difficult because the ifindex of the device is updated through delayed (idle) calls in NMDevice and so there is the possibility that at a certain time the device ifindex is not in sync with platform state. It seems simpler to watch instead the interface name. The ugly thing is that the interface name can be changed externally, but if users do that on an activating device they are looking for trouble.

Also change the deactivate code to deal with the scenario where we already created the interface in the ovsdb but the link didn't show up yet. To ensure a proper cleanup we must wait that the link appears and then goes away; however the link may never appear if vswitchd sees only the last state in ovsdb, and so we must use a ugly timeout to avoid waiting forever.

https://bugzilla.redhat.com/show_bug.cgi?id=1787989

Merge request reports

Loading