Petr Horáček has posted comments on this change.

Change subject: net: Split OVS setup transaction to adjust for bond setup
......................................................................


Patch Set 4:

(3 comments)

https://gerrit.ovirt.org/#/c/64118/4/lib/vdsm/network/netswitch.py
File lib/vdsm/network/netswitch.py:

Line 202: 
Line 203: def _add_networks(nets2add, ovs_info, config, acq):
Line 204:     net_add_setup = ovs_switch.create_network_addition_setup(ovs_info)
Line 205:     net_add_setup.add(nets2add)
Line 206:     acq.acquire(net_add_setup.acquired_ifaces)
but we should acquire before we commit add(), right?
Line 207:     for net, attrs in six.iteritems(nets2add):
Line 208:         config.setNetwork(net, attrs)
Line 209: 
Line 210: 


https://gerrit.ovirt.org/#/c/64118/4/lib/vdsm/network/ovs/switch.py
File lib/vdsm/network/ovs/switch.py:

Line 122:                 # FIXME: What about an existing bond?
Line 123:                 if nic is not None and vlan is None:
Line 124:                     self._copy_nic_hwaddr_to_nb(net, nic)
Line 125: 
Line 126:                 self._ovs_info.northbounds_by_sb.setdefault(sb, set())
.add(net) won't  fit here?
Line 127:                 self._ovs_info.northbounds_by_sb[sb].add(net)
Line 128: 
Line 129:     @property
Line 130:     def acquired_ifaces(self):


Line 197:     """
Line 198:     return [ovsdb.del_br(bridge) for bridge in _unused_bridges()]
Line 199: 
Line 200: 
Line 201: # TODO: we can just check for bridges with no NB port
can we address this? we detach both NICs and bonds from bridge when not used 
anymore.
Line 202: def _unused_bridges():
Line 203:     unused_bridges = set()
Line 204:     ovs_info = info.OvsInfo()
Line 205:     for bridge, attrs in six.iteritems(ovs_info.bridges):


-- 
To view, visit https://gerrit.ovirt.org/64118
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I0bd351e755be9d5dcaf5a05e5b79345e6f7bcfe8
Gerrit-PatchSet: 4
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Edward Haas <edwa...@redhat.com>
Gerrit-Reviewer: Edward Haas <edwa...@redhat.com>
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Petr Horáček <phora...@redhat.com>
Gerrit-Reviewer: gerrit-hooks <automat...@ovirt.org>
Gerrit-HasComments: Yes
_______________________________________________
vdsm-patches mailing list -- vdsm-patches@lists.fedorahosted.org
To unsubscribe send an email to vdsm-patches-le...@lists.fedorahosted.org

Reply via email to