ia64/xen-unstable

changeset 18428:3e72ab517e44

xend: move the call to XendDevices.destroy_device_state()

This patch moves the call to XendDevices.destroy_device_state() to the
function _remove_domain. Previously only Xen-API calls were calling
the destroy_device_state() function.

Signed-off-by: Stefan Berger <stefanb@us.ibm.com>
author Keir Fraser <keir.fraser@citrix.com>
date Wed Sep 03 10:38:33 2008 +0100 (2008-09-03)
parents e2a8e3be7bfa
children 021189f8cd78
files tools/python/xen/xend/XendDomain.py
line diff
     1.1 --- a/tools/python/xen/xend/XendDomain.py	Tue Sep 02 12:06:56 2008 +0100
     1.2 +++ b/tools/python/xen/xend/XendDomain.py	Wed Sep 03 10:38:33 2008 +0100
     1.3 @@ -481,6 +481,7 @@ class XendDomain:
     1.4              if domid in self.domains:
     1.5                  del self.domains[domid]
     1.6  
     1.7 +            XendDevices.destroy_device_state(info)
     1.8              info.destroy_xapi_device_instances()
     1.9          else:
    1.10              log.warning("Attempted to remove non-existent domain.")
    1.11 @@ -1094,7 +1095,6 @@ class XendDomain:
    1.12          dominfo.metrics.destroy()
    1.13          self._managed_domain_unregister(dominfo)
    1.14          self._remove_domain(dominfo)
    1.15 -        XendDevices.destroy_device_state(dominfo)
    1.16          dominfo.destroy_xapi_device_instances()
    1.17  
    1.18