Skip to contentSkip to conversation

Remove ':disk' suffix from device name in config

PATCH New Jim Fehlig 1 participant 1 message Dec 19, 2006

lore
Share & tools
lore

Jim Fehlig

author
#0 lore raw

PATCH 1/1 Remove ':disk' suffix from device name in config

Remove ':disk' suffix from dev entry in dev_info dictionary in XendConfig.py.

The suffix is added regardless of device type (vbd or tap) so it doesn't appear to add any semantics. Additionally, clients would be forced to strip this suffix from the device name since something like 'hda:disk" is not a device name.

Regards,
Jim

# HG changeset patch
# User [email protected]
# Date 1166568442 25200
# Node ID 72a013bc923efa47b3262849cd5611a16353abc5
# Parent 057f7c4dbed1c75a3fbe446d346cee04cff31497
Remove ':disk' suffix from dev entry in dev_info dictionary in XendConfig.py.

The suffix was added regardless of device type so it doesn't appear to add any semantics. Additionally, clients would be forced to strip this suffix from the device name since something like 'hda:disk" is not a device name.

tools/python/xen/xend/XendConfig.py +2 -2
diff -r 057f7c4dbed1 -r 72a013bc923e tools/python/xen/xend/XendConfig.py
@@ -970,10 +970,10 @@ class XendConfig(dict):
             elif dev_type in ('vbd', 'tap'):
                 if dev_type == 'vbd':
                     dev_info['uname'] = cfg_xenapi.get('image', '')
-                    dev_info['dev'] = '%s:disk' % cfg_xenapi.get('device')
+                    dev_info['dev'] = cfg_xenapi.get('device')
                 elif dev_type == 'tap':
                     dev_info['uname'] = 'tap:qcow:%s' % cfg_xenapi.get('image')
-                    dev_info['dev'] = '%s:disk' % cfg_xenapi.get('device')
+                    dev_info['dev'] = cfg_xenapi.get('device')
                     
                 dev_info['driver'] = cfg_xenapi.get('driver')
                 dev_info['VDI'] = cfg_xenapi.get('VDI', '')

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel