WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-changelog

[Xen-changelog] [xen-unstable] Fix rebooting domains problem with new in

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] Fix rebooting domains problem with new internal memory storage
From: Xen patchbot-unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Fri, 23 Mar 2007 11:10:17 -0700
Delivery-date: Fri, 23 Mar 2007 11:10:00 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-changelog-request@lists.xensource.com?subject=help>
List-id: BK change log <xen-changelog.lists.xensource.com>
List-post: <mailto:xen-changelog@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=unsubscribe>
Reply-to: xen-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
# HG changeset patch
# User Tom Wilkie <tom.wilkie@xxxxxxxxx>
# Date 1174662646 0
# Node ID 6f2f72f39872f163c44ebf88b31ce0cafdcfde5b
# Parent  678b8838d361c5d5469219334d9941526978b377
Fix rebooting domains problem with new internal memory storage

signed-off-by: Tom Wilkie <tom.wilkie@xxxxxxxxx>
---
 tools/python/xen/xend/XendConfig.py |   14 ++++++++------
 1 files changed, 8 insertions(+), 6 deletions(-)

diff -r 678b8838d361 -r 6f2f72f39872 tools/python/xen/xend/XendConfig.py
--- a/tools/python/xen/xend/XendConfig.py       Fri Mar 23 13:27:29 2007 +0000
+++ b/tools/python/xen/xend/XendConfig.py       Fri Mar 23 15:10:46 2007 +0000
@@ -269,7 +269,7 @@ class XendConfig(dict):
             self.update_with_xenapi_config(xapi)
         elif dominfo:
             # output from xc.domain_getinfo
-            self._dominfo_to_xapi(dominfo)
+            self._dominfo_to_xapi(dominfo, update_mem = True)
 
         log.debug('XendConfig.init: %s' % scrub_password(self))
 
@@ -405,15 +405,17 @@ class XendConfig(dict):
         self._vcpus_sanity_check()
         self._platform_sanity_check()
 
-    def _dominfo_to_xapi(self, dominfo):
+    def _dominfo_to_xapi(self, dominfo, update_mem = False):
         self['domid'] = dominfo['domid']
         self['online_vcpus'] = dominfo['online_vcpus']
         self['VCPUs_max'] = dominfo['max_vcpu_id'] + 1
 
-        self['memory_dynamic_min'] = dominfo['mem_kb'] * 1024
-        self['memory_dynamic_max'] = dominfo['mem_kb'] * 1024
-        self['memory_static_min'] = 0
-        self['memory_static_max'] = dominfo['maxmem_kb'] * 1024
+        if update_mem:
+            self['memory_dynamic_min'] = dominfo['mem_kb'] * 1024
+            self['memory_dynamic_max'] = dominfo['mem_kb'] * 1024
+            self['memory_static_min'] = 0
+            self['memory_static_max'] = dominfo['maxmem_kb'] * 1024
+            self._memory_sanity_check()
 
         self['cpu_time'] = dominfo['cpu_time']/1e9
         # TODO: i don't know what the security stuff expects here

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] [xen-unstable] Fix rebooting domains problem with new internal memory storage, Xen patchbot-unstable <=