[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] [xen-unstable] xend: Fix device release for tap devices
# HG changeset patch # User Keir Fraser <keir.fraser@xxxxxxxxxx> # Date 1227877558 0 # Node ID 8dbf23c89cc6a4fbd7b9063b14e706c065ba1678 # Parent abada55aec43c15c3589a4ff28cd2b8ccaaff0f8 xend: Fix device release for tap devices I saw an error message when I shut down a domain. The error message showed that release of device(vbd/51712) failed. But the device was tap, was not vbd. I think that a cause of the error message is because _releaseDevices() calls destroyDevice() by wrong device class. Signed-off-by: Masaki Kanno <kanno.masaki@xxxxxxxxxxxxxx> --- tools/python/xen/xend/XendDomainInfo.py | 12 ++++++++++-- 1 files changed, 10 insertions(+), 2 deletions(-) diff -r abada55aec43 -r 8dbf23c89cc6 tools/python/xen/xend/XendDomainInfo.py --- a/tools/python/xen/xend/XendDomainInfo.py Fri Nov 28 13:04:30 2008 +0000 +++ b/tools/python/xen/xend/XendDomainInfo.py Fri Nov 28 13:05:58 2008 +0000 @@ -1990,13 +1990,21 @@ class XendDomainInfo: for devclass in XendDevices.valid_devices(): for dev in t.list(devclass): try: + true_devclass = devclass + if devclass == 'vbd': + # In the case of "vbd", the true device class + # may possibly be "tap". Just in case, verify + # device class. + devid = dev.split('/')[-1] + true_devclass = self.getBlockDeviceClass(devid) log.debug("Removing %s", dev); - self.destroyDevice(devclass, dev, False); + self.destroyDevice(true_devclass, dev, False); except: # Log and swallow any exceptions in removal -- # there's nothing more we can do. log.exception("Device release failed: %s; %s; %s", - self.info['name_label'], devclass, dev) + self.info['name_label'], + true_devclass, dev) finally: t.abort() _______________________________________________ Xen-changelog mailing list Xen-changelog@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-changelog
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |