# HG changeset patch
# User Ian Jackson <Ian.Jackson@xxxxxxxxxxxxx>
# Date 1277824880 -3600
# Node ID 51160a8ecf7d1c3ea19173a4960a0b962b479908
# Parent 452dec73d3c1a6ad332b5fb7d941485c0ed84cc8
tools/xend: Revert 21541:7ff0e885b5c3 "a few blktap2 fixes"
Following discussion on xen-devel. This changeset is doubtful and in
any case incomplete.
---
tools/python/xen/util/blkif.py | 2 +-
tools/python/xen/xend/XendBootloader.py | 13 ++++---------
tools/python/xen/xend/XendDomainInfo.py | 2 +-
3 files changed, 6 insertions(+), 11 deletions(-)
diff -r 452dec73d3c1 -r 51160a8ecf7d tools/python/xen/util/blkif.py
--- a/tools/python/xen/util/blkif.py Tue Jun 29 15:15:57 2010 +0100
+++ b/tools/python/xen/util/blkif.py Tue Jun 29 16:21:20 2010 +0100
@@ -87,7 +87,7 @@ def _parse_uname(uname):
fn = "/dev/%s" %(fn,)
if typ in ("tap", "tap2"):
- (taptype, fn) = fn.split(":", 2)[1:3]
+ (taptype, fn) = fn.split(":", 1)
return (fn, taptype)
def blkdev_uname_to_file(uname):
diff -r 452dec73d3c1 -r 51160a8ecf7d tools/python/xen/xend/XendBootloader.py
--- a/tools/python/xen/xend/XendBootloader.py Tue Jun 29 15:15:57 2010 +0100
+++ b/tools/python/xen/xend/XendBootloader.py Tue Jun 29 16:21:20 2010 +0100
@@ -38,15 +38,10 @@ def bootloader(blexec, disk, dom, quiet
msg = "Bootloader isn't executable"
log.error(msg)
raise VmError(msg)
- attempt = 0
- while True:
- if not os.access(disk, os.R_OK) and attempt > 3:
- msg = "Disk isn't accessible"
- log.error(msg)
- raise VmError(msg)
- else:
- break
- attempt = attempt + 1
+ if not os.access(disk, os.R_OK):
+ msg = "Disk isn't accessible"
+ log.error(msg)
+ raise VmError(msg)
if os.uname()[0] == "NetBSD" and disk.startswith('/dev/'):
disk = disk.replace("/dev/", "/dev/r")
diff -r 452dec73d3c1 -r 51160a8ecf7d tools/python/xen/xend/XendDomainInfo.py
--- a/tools/python/xen/xend/XendDomainInfo.py Tue Jun 29 15:15:57 2010 +0100
+++ b/tools/python/xen/xend/XendDomainInfo.py Tue Jun 29 16:21:20 2010 +0100
@@ -3287,7 +3287,7 @@ class XendDomainInfo:
log.info("Unmounting %s from %s." %
(fn, BOOTLOADER_LOOPBACK_DEVICE))
- dom0.destroyDevice(devtype, BOOTLOADER_LOOPBACK_DEVICE,
force = True)
+ dom0.destroyDevice('tap', BOOTLOADER_LOOPBACK_DEVICE)
if blcfg is None:
msg = "Had a bootloader specified, but can't find disk"
_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog
|