From nobody Wed May 8 02:48:35 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=virtuozzo.com ARC-Seal: i=1; a=rsa-sha256; t=1559748479; cv=none; d=zoho.com; s=zohoarc; b=OYm5WdcfwfOCmHfj5duVViX+0wLermdj9mcuabkheoSfE3GHYGymESkeUbv1xfaMS4qzGXDNlVOTXPj1FvswVrxcwwcIvxEVlJymGcQeBZEr64ZhitaUu7AvJ2ahmg5q1HiXq2CYEl7erX7s7CMxLf4dZHY34Z2LBHM60QdGvoc= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1559748479; h=Cc:Date:From:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:Message-ID:Sender:Subject:To:ARC-Authentication-Results; bh=uUttUxqw7g3EhIiY+dVZALh2tQ/+1VkVuibackTPs9I=; b=JmIq1Ya/cL2BEFHBjv+KTG4hLucxxt7788JTgxiVJ40HT1BoBd/yQHSF4qjPt1gNCdUimG2wx71DRf9QunVPhGB8YuWDyvSWVOX15IMpdzP2vgV2b2UZKOKpIlTeupBAB8JsZV0NkY+jq0sgtyDOGYHg9DI+cT14hfUmMFvu8cQ= ARC-Authentication-Results: i=1; mx.zoho.com; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 155974847966941.69622247602058; Wed, 5 Jun 2019 08:27:59 -0700 (PDT) Received: from localhost ([127.0.0.1]:44522 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hYXpU-0005HI-7Q for importer@patchew.org; Wed, 05 Jun 2019 11:27:56 -0400 Received: from eggs.gnu.org ([209.51.188.92]:43388) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hYXoY-0004y6-4p for qemu-devel@nongnu.org; Wed, 05 Jun 2019 11:26:59 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hYXoV-0007rp-As for qemu-devel@nongnu.org; Wed, 05 Jun 2019 11:26:57 -0400 Received: from relay.sw.ru ([185.231.240.75]:59490) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1hYXoV-0007nZ-1p; Wed, 05 Jun 2019 11:26:55 -0400 Received: from [10.94.3.0] (helo=kvm.qa.sw.ru) by relay.sw.ru with esmtp (Exim 4.91) (envelope-from ) id 1hYXoR-0003Ic-8b; Wed, 05 Jun 2019 18:26:51 +0300 From: Vladimir Sementsov-Ogievskiy To: qemu-devel@nongnu.org, qemu-block@nongnu.org Date: Wed, 5 Jun 2019 18:26:50 +0300 Message-Id: <20190605152650.103483-1-vsementsov@virtuozzo.com> X-Mailer: git-send-email 2.18.0 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 185.231.240.75 Subject: [Qemu-devel] [PATCH] iotests: fix 254 for qcow (1) X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: kwolf@redhat.com, mreitz@redhat.com Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Qcow default cluster size is 4k, but default format of created overlay image on snapshot operation is qcow2 with it's default cluster of 64k. This leads to block-dirty-bitmap-merge fail when test run for qcow format, as it can't merge bitmaps with different granularities. Let's fix it by specifying strict granularity. Reported-by: Max Reitz Signed-off-by: Vladimir Sementsov-Ogievskiy --- tests/qemu-iotests/254 | 5 +++-- tests/qemu-iotests/254.out | 3 ++- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/tests/qemu-iotests/254 b/tests/qemu-iotests/254 index 33cb80a512..a8ea5818ff 100755 --- a/tests/qemu-iotests/254 +++ b/tests/qemu-iotests/254 @@ -29,7 +29,8 @@ qemu_img_create('-f', iotests.imgfmt, disk, str(size)) vm =3D iotests.VM().add_drive(disk, opts=3D'node-name=3Dbase') vm.launch() =20 -vm.qmp_log('block-dirty-bitmap-add', node=3D'drive0', name=3D'bitmap0') +vm.qmp_log('block-dirty-bitmap-add', node=3D'drive0', name=3D'bitmap0', + granularity=3D65536) =20 vm.hmp_qemu_io('drive0', 'write 0 512K') =20 @@ -38,7 +39,7 @@ vm.qmp_log('transaction', indent=3D2, actions=3D[ 'data': {'device': 'drive0', 'snapshot-file': top, 'snapshot-node-name': 'snap'}}, {'type': 'block-dirty-bitmap-add', - 'data': {'node': 'snap', 'name': 'bitmap0'}}, + 'data': {'node': 'snap', 'name': 'bitmap0', 'granularity': 65536}}, {'type': 'block-dirty-bitmap-merge', 'data': {'node': 'snap', 'target': 'bitmap0', 'bitmaps': [{'node': 'base', 'name': 'bitmap0'}]}} diff --git a/tests/qemu-iotests/254.out b/tests/qemu-iotests/254.out index d7394cf002..dc899016da 100644 --- a/tests/qemu-iotests/254.out +++ b/tests/qemu-iotests/254.out @@ -1,4 +1,4 @@ -{"execute": "block-dirty-bitmap-add", "arguments": {"name": "bitmap0", "no= de": "drive0"}} +{"execute": "block-dirty-bitmap-add", "arguments": {"granularity": 65536, = "name": "bitmap0", "node": "drive0"}} {"return": {}} { "execute": "transaction", @@ -14,6 +14,7 @@ }, { "data": { + "granularity": 65536, "name": "bitmap0", "node": "snap" }, --=20 2.18.0