Change in vdsm[master]: Cisco VM-FEX support vdsm hooks

danken at redhat.com danken at redhat.com
Wed Oct 17 11:21:57 UTC 2012


Dan Kenigsberg has posted comments on this change.

Change subject: Cisco VM-FEX support vdsm hooks
......................................................................


Patch Set 9: (2 inline comments)

....................................................
File vdsm_hooks/vmfex/before_vm_start.py
Line 92:     # Example ['eth0','eth1']
Line 93:     nics = []
Line 94:     for root, dirs, names in os.walk('/sys/devices/'):
Line 95:         if 'address' in names and 'pci' in root:
Line 96:             f = open(root + '/address', 'r')
you use file() elsewhere in this code...

but I did not mean file() or open() - but not needing to call close() if only you use "with"
Line 97:             mac = f.readlines()[0].strip()
Line 98:             f.close()
Line 99:             if mac == '00:00:00:00:00:00':
Line 100:                 eth = root.split('/')[-1]


Line 158:     else:
Line 159:         return False
Line 160: 
Line 161: 
Line 162: def handleDirectPool(conn):
"handle" is a sign of unclarity. if you do not have a better name, fine. I'm not a name nazi.
Line 163:     #TODO: take this part and everything it uses out and into a separate
Line 164:     # module
Line 165: 
Line 166:     #is direct-pool defined? If not, just create it and move on


--
To view, visit http://gerrit.ovirt.org/7547
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I45a7fa46919bb39a648dff190c40618395990e91
Gerrit-PatchSet: 9
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Dan Yasny <dyasny at redhat.com>
Gerrit-Reviewer: Antoni Segura Puimedon <asegurap at redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <danken at redhat.com>
Gerrit-Reviewer: Dan Yasny <dyasny at redhat.com>
Gerrit-Reviewer: Federico Simoncelli <fsimonce at redhat.com>
Gerrit-Reviewer: Igor Lvovsky <ilvovsky at redhat.com>
Gerrit-Reviewer: oVirt Jenkins CI Server


More information about the vdsm-patches mailing list