ia64/xen-unstable

changeset 16637:9b37cabe0485

xend: Indicate a resume operation

Indicate that the domain is created as part of a resume operation
rather than a 'create'.

Signed-off-by: Stefan Berger <stefanb@us.ibm.com>
author Keir Fraser <keir.fraser@citrix.com>
date Wed Dec 19 14:45:04 2007 +0000 (2007-12-19)
parents 181483b8e959
children 28921e83000b
files tools/python/xen/xend/XendDomain.py tools/python/xen/xend/XendDomainInfo.py
line diff
     1.1 --- a/tools/python/xen/xend/XendDomain.py	Wed Dec 19 11:14:05 2007 +0000
     1.2 +++ b/tools/python/xen/xend/XendDomain.py	Wed Dec 19 14:45:04 2007 +0000
     1.3 @@ -913,6 +913,8 @@ class XendDomain:
     1.4                  if dominfo._stateGet() != XEN_API_VM_POWER_STATE_SUSPENDED:
     1.5                      raise XendError("Cannot resume domain that is not suspended.")
     1.6  
     1.7 +                dominfo.setResume(True)
     1.8 +
     1.9                  dom_uuid = dominfo.get_uuid()
    1.10                  chkpath = self._managed_check_point_path(dom_uuid)
    1.11                  if not os.path.exists(chkpath):
     2.1 --- a/tools/python/xen/xend/XendDomainInfo.py	Wed Dec 19 11:14:05 2007 +0000
     2.2 +++ b/tools/python/xen/xend/XendDomainInfo.py	Wed Dec 19 14:45:04 2007 +0000
     2.3 @@ -1178,6 +1178,9 @@ class XendDomainInfo:
     2.4      def getResume(self):
     2.5          return str(self._resume)
     2.6  
     2.7 +    def setResume(self, isresume):
     2.8 +        self._resume = isresume
     2.9 +
    2.10      def getCap(self):
    2.11          return self.info['vcpus_params']['cap']
    2.12