ia64/xen-unstable

changeset 19811:bfbd7a85d2f8

xend: Fix tapdisk creation for managed domains

The first start of a managed domain succeeds. But the second
start of the managed domain fails as follows. The problem occurs
when tapdisks are given to the managed domain. I think that the
problem occurs because the uname of tapdisks is overwritten with
"phy:/dev/xen/tadisk-2/tapdev*".

Signed-off-by: Masaki Kanno <kanno.masaki@jp.fujitsu.com>
author Keir Fraser <keir.fraser@citrix.com>
date Tue Jun 23 11:20:10 2009 +0100 (2009-06-23)
parents aa472909b39c
children d9b988c65ebf
files tools/python/xen/xend/XendConfig.py tools/python/xen/xend/server/BlktapController.py
line diff
     1.1 --- a/tools/python/xen/xend/XendConfig.py	Tue Jun 23 11:14:24 2009 +0100
     1.2 +++ b/tools/python/xen/xend/XendConfig.py	Tue Jun 23 11:20:10 2009 +0100
     1.3 @@ -1360,6 +1360,7 @@ class XendConfig(dict):
     1.4                  if dev_info['uname'].split(':')[1] not in blktap_disk_types:
     1.5                      raise XendConfigError("tap:%s not a valid disk type" %
     1.6                                      dev_info['uname'].split(':')[1])
     1.7 +                dev_info['required_uname'] = dev_info['uname']
     1.8  
     1.9              if dev_type == 'vif':
    1.10                  if not dev_info.get('mac'):
     2.1 --- a/tools/python/xen/xend/server/BlktapController.py	Tue Jun 23 11:14:24 2009 +0100
     2.2 +++ b/tools/python/xen/xend/server/BlktapController.py	Tue Jun 23 11:20:10 2009 +0100
     2.3 @@ -120,7 +120,7 @@ class BlktapController(BlkifController):
     2.4  
     2.5      def createDevice(self, config):
     2.6  
     2.7 -        uname = config.get('uname', '')
     2.8 +        uname = config.get('required_uname', '')
     2.9          try:
    2.10              (typ, subtyp, params, file) = string.split(uname, ':', 3)
    2.11          except: