[libvirt] [PATCH] qemu: Emit bootindex even for direct boot

Direct boot (using kernel, initrd, and command line) is used by virt-install/virt-manager for network install. While any bootindex has no direct effect since -kernel is always first, we need it as a hint for SeaBIOS to present disks in the same order as they will be presented during normal boot. --- src/qemu/qemu_command.c | 3 +-- 1 files changed, 1 insertions(+), 2 deletions(-) diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c index aaccf62..9b69ad0 100644 --- a/src/qemu/qemu_command.c +++ b/src/qemu/qemu_command.c @@ -4334,8 +4334,7 @@ qemuBuildCommandLine(virConnectPtr conn, if (qemuCapsGet(qemuCaps, QEMU_CAPS_DRIVE)) { int bootCD = 0, bootFloppy = 0, bootDisk = 0; - if ((qemuCapsGet(qemuCaps, QEMU_CAPS_DRIVE_BOOT) || emitBootindex) && - !def->os.kernel) { + if ((qemuCapsGet(qemuCaps, QEMU_CAPS_DRIVE_BOOT) || emitBootindex)) { /* bootDevs will get translated into either bootindex=N or boot=on * depending on what qemu supports */ for (i = 0 ; i < def->os.nBootDevs ; i++) { -- 1.7.8.4

On 01/24/2012 03:53 PM, Jiri Denemark wrote:
Direct boot (using kernel, initrd, and command line) is used by virt-install/virt-manager for network install. While any bootindex has no direct effect since -kernel is always first, we need it as a hint for SeaBIOS to present disks in the same order as they will be presented during normal boot. --- src/qemu/qemu_command.c | 3 +-- 1 files changed, 1 insertions(+), 2 deletions(-)
diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c index aaccf62..9b69ad0 100644 --- a/src/qemu/qemu_command.c +++ b/src/qemu/qemu_command.c @@ -4334,8 +4334,7 @@ qemuBuildCommandLine(virConnectPtr conn, if (qemuCapsGet(qemuCaps, QEMU_CAPS_DRIVE)) { int bootCD = 0, bootFloppy = 0, bootDisk = 0;
- if ((qemuCapsGet(qemuCaps, QEMU_CAPS_DRIVE_BOOT) || emitBootindex) && - !def->os.kernel) { + if ((qemuCapsGet(qemuCaps, QEMU_CAPS_DRIVE_BOOT) || emitBootindex)) {
ACK. -- Eric Blake eblake@redhat.com +1-919-301-3266 Libvirt virtualization library http://libvirt.org

On Tue, Jan 24, 2012 at 15:59:10 -0700, Eric Blake wrote:
On 01/24/2012 03:53 PM, Jiri Denemark wrote:
Direct boot (using kernel, initrd, and command line) is used by virt-install/virt-manager for network install. While any bootindex has no direct effect since -kernel is always first, we need it as a hint for SeaBIOS to present disks in the same order as they will be presented during normal boot. --- src/qemu/qemu_command.c | 3 +-- 1 files changed, 1 insertions(+), 2 deletions(-)
diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c index aaccf62..9b69ad0 100644 --- a/src/qemu/qemu_command.c +++ b/src/qemu/qemu_command.c @@ -4334,8 +4334,7 @@ qemuBuildCommandLine(virConnectPtr conn, if (qemuCapsGet(qemuCaps, QEMU_CAPS_DRIVE)) { int bootCD = 0, bootFloppy = 0, bootDisk = 0;
- if ((qemuCapsGet(qemuCaps, QEMU_CAPS_DRIVE_BOOT) || emitBootindex) && - !def->os.kernel) { + if ((qemuCapsGet(qemuCaps, QEMU_CAPS_DRIVE_BOOT) || emitBootindex)) {
ACK.
Thanks, pushed. Jirka
participants (2)
-
Eric Blake
-
Jiri Denemark