Change in vdsm[master]: Add support for KVM on IBM POWER processor (ppc64)

Ryan Harper ryanh at us.ibm.com
Wed Sep 26 20:33:38 UTC 2012


Ryan Harper has posted comments on this change.

Change subject: Add support for KVM on IBM POWER processor (ppc64)
......................................................................


Patch Set 3: I would prefer that you didn't submit this

(2 inline comments)

....................................................
File vdsm_reg/deployUtil.py.in
Line 343:         if os.path.exists('/proc/device-tree/system-id'):
Line 344:             #eg. output IBM,03061C14A
Line 345:             strReturn = file('/proc/device-tree/system-id').readline().replace(",","")
Line 346:         else:
Line 347:             logging.error("getMachineUUID: Could not find machine's UUID.")
What about:

arch = platform.machine()
if arch == 'x86_64':
  # x86 stuff here
  return UUID string on success
elif arch == 'ppc64'
 # ppc stuff here
 // return UUID string on success

# error case here
logging.error("getMachineUUID: Couldn't find")
return "None"


This avoids duplicate logging errors in each case, invokes the platform.machine() only once.
Line 348:     else:
Line 349:         logging.error("getMachineUUID: Could not find machine's UUID.")
Line 350: 
Line 351:     return strReturn


Line 484:     Return '' on any failure.
Line 485:     """
Line 486: 
Line 487:     platformArch = platform.machine()
Line 488:     return platformArch
I'd drop this function altogether, see above comment.
Line 489: 
Line 490: 
Line 491: def getKernelVR():
Line 492:     """Return current kernel version and release."""


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

Gerrit-MessageType: comment
Gerrit-Change-Id: I2d8767c52488ab8083123d0ec1e789d3857e2358
Gerrit-PatchSet: 3
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Pradipta Banerjee <bpradip at in.ibm.com>
Gerrit-Reviewer: Alon Bar-Lev <alonbl at redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <danken at redhat.com>
Gerrit-Reviewer: Pradipta Banerjee <bpradip at in.ibm.com>
Gerrit-Reviewer: Ryan Harper <ryanh at us.ibm.com>


More information about the vdsm-patches mailing list