aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKeir Fraser <keir.fraser@citrix.com>2010-06-15 11:29:31 +0100
committerKeir Fraser <keir.fraser@citrix.com>2010-06-15 11:29:31 +0100
commita4042a40976bce73f55e977dc84cd8fb5a2678d0 (patch)
tree9af18923e5f8c79a0d7ec8a695f1daccdb582b1f
parente96784240ea85c4c6aba1cbd5d8e8c3c815c74fd (diff)
downloadxen-a4042a40976bce73f55e977dc84cd8fb5a2678d0.tar.gz
xen-a4042a40976bce73f55e977dc84cd8fb5a2678d0.tar.bz2
xen-a4042a40976bce73f55e977dc84cd8fb5a2678d0.zip
Revert 21190:d6470041aa2e (xen-unstable 21541:7ff0e885b5c3).
Caused regressions in Intel's RC2 testing when parsing domain config files. Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
-rw-r--r--tools/python/xen/util/blkif.py2
-rw-r--r--tools/python/xen/xend/XendBootloader.py13
-rw-r--r--tools/python/xen/xend/XendDomainInfo.py2
3 files changed, 6 insertions, 11 deletions
diff --git a/tools/python/xen/util/blkif.py b/tools/python/xen/util/blkif.py
index ca5a3081b5..cbe76b613f 100644
--- a/tools/python/xen/util/blkif.py
+++ b/tools/python/xen/util/blkif.py
@@ -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 --git a/tools/python/xen/xend/XendBootloader.py b/tools/python/xen/xend/XendBootloader.py
index 3824d5ac17..0cef917358 100644
--- a/tools/python/xen/xend/XendBootloader.py
+++ b/tools/python/xen/xend/XendBootloader.py
@@ -38,15 +38,10 @@ def bootloader(blexec, disk, dom, quiet = False, blargs = '', kernel = '',
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 --git a/tools/python/xen/xend/XendDomainInfo.py b/tools/python/xen/xend/XendDomainInfo.py
index 15595ab536..a60342c668 100644
--- a/tools/python/xen/xend/XendDomainInfo.py
+++ b/tools/python/xen/xend/XendDomainInfo.py
@@ -3269,7 +3269,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"