]> git.proxmox.com Git - qemu.git/commitdiff
defaults: update device_list[]
authorGerd Hoffmann <kraxel@redhat.com>
Wed, 16 Dec 2009 13:25:40 +0000 (14:25 +0100)
committerAnthony Liguori <aliguori@us.ibm.com>
Sat, 19 Dec 2009 14:26:21 +0000 (08:26 -0600)
Add isa-fdc (disables default_floppy).
Add ide-drive (disables default_cdrom).

Also walk the -global QemuOpts, so we'll catch
-global isa-fdc.drive{A,B}=<name> too.

Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
(cherry picked from commit d8bcbabf260a4ecce73180991cad576de850b66d)

qemu-config.h
vl.c

index 34dfadc5f3f8415e0574e12396f9c112a4527826..dd89ae4683c958cc2396fbe01ca129de1e549792 100644 (file)
@@ -7,6 +7,7 @@ extern QemuOptsList qemu_device_opts;
 extern QemuOptsList qemu_netdev_opts;
 extern QemuOptsList qemu_net_opts;
 extern QemuOptsList qemu_rtc_opts;
+extern QemuOptsList qemu_global_opts;
 extern QemuOptsList qemu_mon_opts;
 
 int qemu_set_option(const char *str);
diff --git a/vl.c b/vl.c
index ffa1aec90490bc7670e4c2a2de0b4d5f0d8e667c..95abe7e67fe777cfb0e72b2147248b45c488ed4f 100644 (file)
--- a/vl.c
+++ b/vl.c
@@ -284,6 +284,8 @@ static struct {
 } default_list[] = {
     { .driver = "isa-serial",           .flag = &default_serial    },
     { .driver = "isa-parallel",         .flag = &default_parallel  },
+    { .driver = "isa-fdc",              .flag = &default_floppy    },
+    { .driver = "ide-drive",            .flag = &default_cdrom     },
     { .driver = "virtio-console-pci",   .flag = &default_virtcon   },
     { .driver = "virtio-console-s390",  .flag = &default_virtcon   },
     { .driver = "VGA",                  .flag = &default_vga       },
@@ -5676,6 +5678,7 @@ int main(int argc, char **argv, char **envp)
     }
 
     qemu_opts_foreach(&qemu_device_opts, default_driver_check, NULL, 0);
+    qemu_opts_foreach(&qemu_global_opts, default_driver_check, NULL, 0);
 
     if (machine->no_serial) {
         default_serial = 0;