Skip to contentSkip to conversation

Scale memory parameter for tests using XenAPIDomain

PATCH New Stefan Berger 1 participant 1 message Apr 20, 2007

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Scale memory parameter for tests using XenAPIDomain

Scale the memory parameter for domains using the XenAPIDomain to create a domain. Those domains use the normal configuration where the memory parameter is given in 'Mb', so it needs to be adapted to 'bytes'.

xen-unstable.hg/tools/xm-test/lib/XmTestLib/XenAPIDomain.py +2 -0
Index: root/xen-unstable.hg/tools/xm-test/lib/XmTestLib/XenAPIDomain.py
===================================================================
@@ -41,6 +41,8 @@ class XenAPIConfig:
 
     def setOpt(self, name, value):
         """Set an option in the config"""
+        if name == "memory":
+            value <<= 20
         if name in self.opttrlate.keys():
             _name = self.opttrlate[name]
         else:

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel