ia64/xen-unstable

changeset 6903:9d4f4ff1ff77

Fix bootloader support some more.
Signed-off-by: Christian Limpach <Christian.Limpach@cl.cam.ac.uk>
author cl349@firebug.cl.cam.ac.uk
date Thu Sep 15 18:38:44 2005 +0000 (2005-09-15)
parents cedfbb032261
children 75fe7890cf01
files tools/python/xen/xend/XendDomainInfo.py
line diff
     1.1 --- a/tools/python/xen/xend/XendDomainInfo.py	Thu Sep 15 17:40:16 2005 +0000
     1.2 +++ b/tools/python/xen/xend/XendDomainInfo.py	Thu Sep 15 18:38:44 2005 +0000
     1.3 @@ -642,7 +642,6 @@ class XendDomainInfo:
     1.4              self.configure_cpus(config)
     1.5              self.init_domain()
     1.6              self.register_domain()
     1.7 -            self.configure_bootloader()
     1.8  
     1.9              # Create domain devices.
    1.10              self.configure_backends()
    1.11 @@ -909,11 +908,6 @@ class XendDomainInfo:
    1.12              self.config.remove(['device', dev_config])
    1.13          self.deleteDevice(type, dev.getId())
    1.14  
    1.15 -    def configure_bootloader(self):
    1.16 -        """Configure boot loader.
    1.17 -        """
    1.18 -        self.bootloader = sxp.child_value(self.config, "bootloader")
    1.19 -
    1.20      def configure_restart(self):
    1.21          """Configure the vm restart mode.
    1.22          """
    1.23 @@ -983,14 +977,16 @@ class XendDomainInfo:
    1.24              self.restart_check()
    1.25              self.exportToDB()
    1.26              self.restart_state = STATE_RESTART_BOOTING
    1.27 -            if self.bootloader:
    1.28 -                self.configure_bootloader()
    1.29 +            self.configure_bootloader()
    1.30              self.construct(self.config)
    1.31              self.saveToDB()
    1.32          finally:
    1.33              self.restart_state = None
    1.34  
    1.35      def configure_bootloader(self):
    1.36 +        self.bootloader = sxp.child_value(self.config, "bootloader")
    1.37 +        if not self.bootloader:
    1.38 +            return
    1.39          # if we're restarting with a bootloader, we need to run it
    1.40          # FIXME: this assumes the disk is the first device and
    1.41          # that we're booting from the first disk