# HG changeset patch # User Ewan Mellor # Date 1170343936 0 # Node ID 1fb0302683d34317d363f5e7b627fb432f1ac19e # Parent 2b4b07391df2d63dc419701099b04f8a0c202111 Fix handling of HVM boot. Signed-off-by: Ewan Mellor Index: xen-3.0.4-testing/tools/python/xen/xend/XendConfig.py =================================================================== --- xen-3.0.4-testing.orig/tools/python/xen/xend/XendConfig.py +++ xen-3.0.4-testing/tools/python/xen/xend/XendConfig.py @@ -707,6 +707,7 @@ class XendConfig(dict): val = sxp.child_value(image_sxp, imgkey, None) if val != None: self[apikey] = val + self._hvm_boot_params_from_sxp(image_sxp) # extract backend value @@ -1310,11 +1311,18 @@ class XendConfig(dict): val = sxp.child_value(image_sxp, imgkey, None) if val != None: type_conv = XENAPI_CFG_TYPES[apikey] - if callable(conv): + if callable(type_conv): self[apikey] = type_conv(val) else: self[apikey] = val + self._hvm_boot_params_from_sxp(image_sxp) + + def _hvm_boot_params_from_sxp(self, image_sxp): + boot = sxp.child_value(image_sxp, 'boot', None) + if boot is not None: + self['HVM_boot_policy'] = 'BIOS order' + self['HVM_boot_params'] = { 'order' : boot } # # debugging