qemu-devel
[Top][All Lists]
Advanced

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

[Qemu-devel] [PATCH v3 0/2] mirror: fix improperly filled copy_bitmap fo


From: Denis V. Lunev
Subject: [Qemu-devel] [PATCH v3 0/2] mirror: fix improperly filled copy_bitmap for mirror block job
Date: Thu, 15 Sep 2016 19:34:48 +0300

bdrv_is_allocated_above() returns true in the case even for completel
zeroed areas as BDRV_BLOCK_ALLOCATED flag is set in both cases.

The patch stops using bdrv_is_allocated_above() wrapper and switches to
bdrv_get_block_status_above() to distinguish zeroed areas and areas with
data to avoid extra IO operations if possible.

Though this change requires some preparations in bdrv_get_block_status_above()
performed in the patch (1).

Changes from v2:
- reworked patch 1 to properly hide data below short image
- fixed comment in patch 1
- fixed mask assignment in patch 2 to cover bdrv_is_zero_initialized() case

Changes from v1:
- fixed assert in 041 test case (added patch 1)
- fixed commit message
- fixed status check to be on the safe side

Signed-off-by: Denis V. Lunev <address@hidden>
CC: Stefan Hajnoczi <address@hidden>
CC: Fam Zheng <address@hidden>
CC: Kevin Wolf <address@hidden>
CC: Max Reitz <address@hidden>
CC: Jeff Cody <address@hidden>

Denis V. Lunev (2):
  block: sync bdrv_co_get_block_status_above() with
    bdrv_is_allocated_above()
  mirror: fix improperly filled copy_bitmap for mirror block job

 block/io.c     | 25 ++++++++++++++++++++-----
 block/mirror.c | 17 +++++++++++------
 2 files changed, 31 insertions(+), 11 deletions(-)

-- 
2.7.4




reply via email to

[Prev in Thread] Current Thread [Next in Thread]