]> Git Repo - qemu.git/blobdiff - vl.c
use TARGET_<arch name> for selection
[qemu.git] / vl.c
diff --git a/vl.c b/vl.c
index d82c3d84d254422d8ab0fc2c70cbb2c20d8a2277..978041f3390ae999db9f9362e1d579d59268e2a5 100644 (file)
--- a/vl.c
+++ b/vl.c
@@ -992,7 +992,7 @@ int qemu_timer_pending(QEMUTimer *ts)
     return 0;
 }
 
-static inline int qemu_timer_expired(QEMUTimer *timer_head, int64_t current_time)
+int qemu_timer_expired(QEMUTimer *timer_head, int64_t current_time)
 {
     if (!timer_head)
         return 0;
@@ -1982,6 +1982,9 @@ DriveInfo *drive_init(QemuOpts *opts, void *opaque,
        } else if (!strcmp(buf, "xen")) {
            type = IF_XEN;
             max_devs = 0;
+       } else if (!strcmp(buf, "none")) {
+           type = IF_NONE;
+            max_devs = 0;
        } else {
             fprintf(stderr, "qemu: unsupported bus type '%s'\n", buf);
             return NULL;
@@ -2194,7 +2197,15 @@ DriveInfo *drive_init(QemuOpts *opts, void *opaque,
         break;
     case IF_PFLASH:
     case IF_MTD:
+    case IF_NONE:
+        break;
     case IF_VIRTIO:
+        /* add virtio block device */
+        opts = qemu_opts_create(&qemu_device_opts, NULL, 0);
+        qemu_opt_set(opts, "driver", "virtio-blk-pci");
+        qemu_opt_set(opts, "drive", dinfo->id);
+        if (devaddr)
+            qemu_opt_set(opts, "addr", devaddr);
         break;
     case IF_COUNT:
         abort();
This page took 0.024997 seconds and 4 git commands to generate.