Re: [PATCH 4/8] Support block I/O throtte in XML

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 11/22/2011 09:45 PM, Eric Blake wrote:
> subject line: s/throtte/throttle/
> 
> On 11/15/2011 02:02 AM, Lei Li wrote:
>> Enable block I/O throttle for per-disk in XML.
>>
>> Signed-off-by: Lei Li <lilei@xxxxxxxxxxxxxxxxxx>
>> Signed-off-by: Zhi Yong Wu <wuzhy@xxxxxxxxxxxxxxxxxx>
>> ---
>>  src/conf/domain_conf.c  |  101 +++++++++++++++++++++++++++++++++++++++++++++-
>>  src/conf/domain_conf.h  |   12 ++++++
>>  src/qemu/qemu_command.c |   33 +++++++++++++++
>>  src/util/xml.h          |    2 +
>>  4 files changed, 145 insertions(+), 3 deletions(-)
> 
> I'm now applying this before 3/8.
> 
> Here's what I'm squashing in, so far:
> 

And one more (read my upcoming comments on 3/8 for why).

diff --git i/src/conf/domain_conf.h w/src/conf/domain_conf.h
index 9180769..ff6921a 100644
--- i/src/conf/domain_conf.h
+++ w/src/conf/domain_conf.h
@@ -313,6 +313,17 @@ enum virDomainDiskSecretType {
     VIR_DOMAIN_DISK_SECRET_TYPE_LAST
 };

+typedef struct _virDomainBlockIoTuneInfo virDomainBlockIoTuneInfo;
+struct _virDomainBlockIoTuneInfo {
+    unsigned long long total_bytes_sec;
+    unsigned long long read_bytes_sec;
+    unsigned long long write_bytes_sec;
+    unsigned long long total_iops_sec;
+    unsigned long long read_iops_sec;
+    unsigned long long write_iops_sec;
+};
+typedef virDomainBlockIoTuneInfo *virDomainBlockIoTuneInfoPtr;
+
 /* Stores the virtual disk configuration */
 typedef struct _virDomainDiskDef virDomainDiskDef;
 typedef virDomainDiskDef *virDomainDiskDefPtr;
@@ -336,15 +347,7 @@ struct _virDomainDiskDef {
     char *driverName;
     char *driverType;

-    /*disk I/O throttling*/
-    struct {
-        unsigned long long total_bytes_sec;
-        unsigned long long read_bytes_sec;
-        unsigned long long write_bytes_sec;
-        unsigned long long total_iops_sec;
-        unsigned long long read_iops_sec;
-        unsigned long long write_iops_sec;
-    } blkdeviotune;
+    virDomainBlockIoTuneInfo blkdeviotune;

     char *serial;
     int cachemode;

-- 
Eric Blake   eblake@xxxxxxxxxx    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list

[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]