]> xenbits.xensource.com Git - libvirt.git/commitdiff
qemu: Add Qemu capability for bps_max and friends
authorMatthias Gatto <matthias.gatto@outscale.com>
Wed, 29 Oct 2014 12:16:01 +0000 (13:16 +0100)
committerMichal Privoznik <mprivozn@redhat.com>
Mon, 10 Nov 2014 14:48:59 +0000 (15:48 +0100)
Add the capability to detect if the qemu binary have the capability
to use bps_max and friends
Add a value in the enum virQEMUCapsFlags for the qemu capability.
Set it with virQEMUCapsSet if the binary suport bps_max and they friends.

Signed-off-by: Matthias Gatto <matthias.gatto@outscale.com>
src/qemu/qemu_capabilities.c
src/qemu/qemu_capabilities.h
tests/qemucapabilitiesdata/caps_2.1.1-1.caps

index 2505d32624a345b0918a36dc15f3f3105233ef5a..74a3b24b97a542b48062b47d17ffa95fce234e68 100644 (file)
@@ -271,6 +271,7 @@ VIR_ENUM_IMPL(virQEMUCaps, QEMU_CAPS_LAST,
               "iothread",
               "migrate-rdma",
               "ivshmem",
+              "drive-iotune-max",
     );
 
 
@@ -2450,6 +2451,7 @@ static struct virQEMUCapsCommandLineProps virQEMUCapsCommandLine[] = {
     { "spice", "disable-agent-file-xfer", QEMU_CAPS_SPICE_FILE_XFER_DISABLE },
     { "msg", "timestamp", QEMU_CAPS_MSG_TIMESTAMP },
     { "numa", NULL, QEMU_CAPS_NUMA },
+    { "drive", "throttling.bps-total-max", QEMU_CAPS_DRIVE_IOTUNE_MAX},
 };
 
 static int
index c0e2172b18a6f104fc8533fe322bfac6496666e1..ffe3494b35ece21a9343e4be2f6fc5804eff2892 100644 (file)
@@ -218,6 +218,7 @@ typedef enum {
     QEMU_CAPS_OBJECT_IOTHREAD    = 176, /* -object iothread */
     QEMU_CAPS_MIGRATE_RDMA       = 177, /* have rdma migration */
     QEMU_CAPS_DEVICE_IVSHMEM     = 178, /* -device ivshmem */
+    QEMU_CAPS_DRIVE_IOTUNE_MAX   = 179, /* -drive bps_max= and friends */
 
     QEMU_CAPS_LAST,                   /* this must always be the last item */
 } virQEMUCapsFlags;
index 7fc654d6fc570353e2361e5bec73d21c9c2ed401..7003ad8b5daca853505398f17c401d29d8caa58c 100644 (file)
     <flag name='iothread'/>
     <flag name='migrate-rdma'/>
     <flag name='ivshmem'/>
+    <flag name='drive-iotune-max'/>
   </qemuCaps>