render / rpms / libvirt

Forked from rpms/libvirt 10 months ago
Clone
fbe740
From 4a0a0c37c0f3ea2c8eb6b96b07c990d7a4ce1c8b Mon Sep 17 00:00:00 2001
fbe740
Message-Id: <4a0a0c37c0f3ea2c8eb6b96b07c990d7a4ce1c8b@dist-git>
fbe740
From: Peter Krempa <pkrempa@redhat.com>
fbe740
Date: Tue, 4 Feb 2020 15:07:51 +0100
fbe740
Subject: [PATCH] qemu: checkpoint: rename disk->chkdisk in
fbe740
 qemuCheckpointDiscardBitmaps
fbe740
MIME-Version: 1.0
fbe740
Content-Type: text/plain; charset=UTF-8
fbe740
Content-Transfer-Encoding: 8bit
fbe740
fbe740
Upcoming patches will also use the domain disk definition. Rename disk
fbe740
to chkdisk for clarity.
fbe740
fbe740
Signed-off-by: Peter Krempa <pkrempa@redhat.com>
fbe740
Reviewed-by: Eric Blake <eblake@redhat.com>
fbe740
(cherry picked from commit a303e8ea47c9a2caa39ae744c0bf9a2f724a6137)
fbe740
fbe740
https://bugzilla.redhat.com/show_bug.cgi?id=1207659
fbe740
Message-Id: <0799859ad288a747f1d12dd07bbb403053d78457.1580824112.git.pkrempa@redhat.com>
fbe740
Reviewed-by: Ján Tomko <jtomko@redhat.com>
fbe740
---
fbe740
 src/qemu/qemu_checkpoint.c | 12 ++++++------
fbe740
 1 file changed, 6 insertions(+), 6 deletions(-)
fbe740
fbe740
diff --git a/src/qemu/qemu_checkpoint.c b/src/qemu/qemu_checkpoint.c
fbe740
index 9ff3129570..d347b8fc6c 100644
fbe740
--- a/src/qemu/qemu_checkpoint.c
fbe740
+++ b/src/qemu/qemu_checkpoint.c
fbe740
@@ -124,13 +124,13 @@ qemuCheckpointDiscardBitmaps(virDomainObjPtr vm,
fbe740
         return -1;
fbe740
 
fbe740
     for (i = 0; i < chkdef->ndisks; i++) {
fbe740
-        virDomainCheckpointDiskDef *disk = &chkdef->disks[i];
fbe740
+        virDomainCheckpointDiskDef *chkdisk = &chkdef->disks[i];
fbe740
         const char *node;
fbe740
 
fbe740
-        if (disk->type != VIR_DOMAIN_CHECKPOINT_TYPE_BITMAP)
fbe740
+        if (chkdisk->type != VIR_DOMAIN_CHECKPOINT_TYPE_BITMAP)
fbe740
             continue;
fbe740
 
fbe740
-        node = qemuDomainDiskNodeFormatLookup(vm, disk->name);
fbe740
+        node = qemuDomainDiskNodeFormatLookup(vm, chkdisk->name);
fbe740
         /* If any ancestor checkpoint has a bitmap for the same
fbe740
          * disk, then this bitmap must be merged to the
fbe740
          * ancestor. */
fbe740
@@ -145,7 +145,7 @@ qemuCheckpointDiscardBitmaps(virDomainObjPtr vm,
fbe740
                 g_autoptr(virJSONValue) arr = NULL;
fbe740
 
fbe740
                 disk2 = &parentdef->disks[j];
fbe740
-                if (STRNEQ(disk->name, disk2->name) ||
fbe740
+                if (STRNEQ(chkdisk->name, disk2->name) ||
fbe740
                     disk2->type != VIR_DOMAIN_CHECKPOINT_TYPE_BITMAP)
fbe740
                     continue;
fbe740
                 search_parents = false;
fbe740
@@ -153,7 +153,7 @@ qemuCheckpointDiscardBitmaps(virDomainObjPtr vm,
fbe740
                 if (!(arr = virJSONValueNewArray()))
fbe740
                     return -1;
fbe740
 
fbe740
-                if (qemuMonitorTransactionBitmapMergeSourceAddBitmap(arr, node, disk->bitmap) < 0)
fbe740
+                if (qemuMonitorTransactionBitmapMergeSourceAddBitmap(arr, node, chkdisk->bitmap) < 0)
fbe740
                     return -1;
fbe740
 
fbe740
                 if (chkcurrent) {
fbe740
@@ -166,7 +166,7 @@ qemuCheckpointDiscardBitmaps(virDomainObjPtr vm,
fbe740
             }
fbe740
         }
fbe740
 
fbe740
-        if (qemuMonitorTransactionBitmapRemove(actions, node, disk->bitmap) < 0)
fbe740
+        if (qemuMonitorTransactionBitmapRemove(actions, node, chkdisk->bitmap) < 0)
fbe740
             return -1;
fbe740
     }
fbe740
 
fbe740
-- 
fbe740
2.25.0
fbe740