{"id":1307005,"url":"http://patchwork.ozlabs.org/api/covers/1307005/?format=json","web_url":"http://patchwork.ozlabs.org/project/qemu-devel/cover/cover.1591801197.git.berto@igalia.com/","project":{"id":14,"url":"http://patchwork.ozlabs.org/api/projects/14/?format=json","name":"QEMU Development","link_name":"qemu-devel","list_id":"qemu-devel.nongnu.org","list_email":"qemu-devel@nongnu.org","web_url":"","scm_url":"","webscm_url":"","list_archive_url":"","list_archive_url_format":"","commit_url_format":""},"msgid":"<cover.1591801197.git.berto@igalia.com>","list_archive_url":null,"date":"2020-06-10T15:02:38","name":"[v8,00/34] Add subcluster allocation to qcow2","submitter":{"id":65704,"url":"http://patchwork.ozlabs.org/api/people/65704/?format=json","name":"Alberto Garcia","email":"berto@igalia.com"},"mbox":"http://patchwork.ozlabs.org/project/qemu-devel/cover/cover.1591801197.git.berto@igalia.com/mbox/","series":[{"id":182563,"url":"http://patchwork.ozlabs.org/api/series/182563/?format=json","web_url":"http://patchwork.ozlabs.org/project/qemu-devel/list/?series=182563","date":"2020-06-10T15:02:49","name":"Add subcluster allocation to qcow2","version":8,"mbox":"http://patchwork.ozlabs.org/series/182563/mbox/"}],"comments":"http://patchwork.ozlabs.org/api/covers/1307005/comments/","headers":{"Return-Path":"<qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org>","X-Original-To":"incoming@patchwork.ozlabs.org","Delivered-To":"patchwork-incoming@bilbo.ozlabs.org","Authentication-Results":["ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=nongnu.org\n (client-ip=209.51.188.17; helo=lists.gnu.org;\n envelope-from=qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org;\n receiver=<UNKNOWN>)","ozlabs.org;\n dmarc=none (p=none dis=none) header.from=igalia.com","ozlabs.org;\n\tdkim=fail reason=\"signature verification failed\" (2048-bit key;\n unprotected) header.d=igalia.com header.i=@igalia.com header.a=rsa-sha256\n header.s=20170329 header.b=ntgM3cF4;\n\tdkim-atps=neutral"],"Received":["from lists.gnu.org (lists.gnu.org [209.51.188.17])\n\t(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))\n\t(No client certificate requested)\n\tby ozlabs.org (Postfix) with ESMTPS id 49hr2n5bhVz9sRW\n\tfor <incoming@patchwork.ozlabs.org>; Thu, 11 Jun 2020 01:08:01 +1000 (AEST)","from localhost ([::1]:57698 helo=lists1p.gnu.org)\n\tby lists.gnu.org with esmtp (Exim 4.90_1)\n\t(envelope-from <qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org>)\n\tid 1jj2Kd-0006sA-8d\n\tfor incoming@patchwork.ozlabs.org; Wed, 10 Jun 2020 11:07:59 -0400","from eggs.gnu.org ([2001:470:142:3::10]:35970)\n by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)\n (Exim 4.90_1) (envelope-from <berto@igalia.com>)\n id 1jj2Gf-0002Lc-EB; Wed, 10 Jun 2020 11:03:53 -0400","from fanzine.igalia.com ([178.60.130.6]:58017)\n by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128)\n (Exim 4.90_1) (envelope-from <berto@igalia.com>)\n id 1jj2GX-0006vt-PK; Wed, 10 Jun 2020 11:03:51 -0400","from [81.0.38.199] (helo=perseus.local)\n by fanzine.igalia.com with esmtpsa\n (Cipher TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim)\n id 1jj2GQ-0007ge-Sj; Wed, 10 Jun 2020 17:03:38 +0200","from berto by perseus.local with local (Exim 4.92)\n (envelope-from <berto@igalia.com>)\n id 1jj2GB-0007MS-KK; Wed, 10 Jun 2020 17:03:23 +0200"],"DKIM-Signature":"v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=igalia.com;\n s=20170329;\n h=Content-Transfer-Encoding:MIME-Version:Message-Id:Date:Subject:Cc:To:From;\n bh=lQ3bovAyFtHjaZFEaq0k6hBdSfIQPeMdTE7wL25voOI=;\n b=ntgM3cF4meWD+BEt6Qc9k5Cwvmovr3N/vgZDBzQRP3C3CJvW88SASfATXIJ/yiQZqg1oTbZuINoaij0QWdomcPEjXdHSuU503SVSEz8IdxFw1n28majDfjPYj0aMoOusfEyrt0oBr/Gw7idx7Og1yBOvkE/CbF5S9ZMFFx/bgF6X2r2luob6dDZTCFch7AL53TZLfDZmBZQ3U/1ZlKTgYtnzI9jfIbrAmZNPI249Qw0A92/3YyAxXJBwkVj1cJIo5hj3Bv8hKMZ+MyMx8TMw2FXppO/vqkxJ6NE9pcPmzY675Ek3BNvJiKI/IaL1zOks0ogvW2aU6D88ID695Ah9eA==;","From":"Alberto Garcia <berto@igalia.com>","To":"qemu-devel@nongnu.org","Subject":"[PATCH v8 00/34] Add subcluster allocation to qcow2","Date":"Wed, 10 Jun 2020 17:02:38 +0200","Message-Id":"<cover.1591801197.git.berto@igalia.com>","X-Mailer":"git-send-email 2.20.1","MIME-Version":"1.0","Content-Transfer-Encoding":"8bit","Received-SPF":"pass client-ip=178.60.130.6; envelope-from=berto@igalia.com;\n helo=fanzine.igalia.com","X-detected-operating-system":"by eggs.gnu.org: First seen = 2020/06/10 11:03:39","X-ACL-Warn":"Detected OS   = Linux 2.2.x-3.x (no timestamps) [generic] [fuzzy]","X-Spam_score_int":"-20","X-Spam_score":"-2.1","X-Spam_bar":"--","X-Spam_report":"(-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1,\n DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, SPF_HELO_NONE=0.001,\n SPF_PASS=-0.001 autolearn=_AUTOLEARN","X-Spam_action":"no action","X-BeenThere":"qemu-devel@nongnu.org","X-Mailman-Version":"2.1.23","Precedence":"list","List-Id":"<qemu-devel.nongnu.org>","List-Unsubscribe":"<https://lists.nongnu.org/mailman/options/qemu-devel>,\n <mailto:qemu-devel-request@nongnu.org?subject=unsubscribe>","List-Archive":"<https://lists.nongnu.org/archive/html/qemu-devel>","List-Post":"<mailto:qemu-devel@nongnu.org>","List-Help":"<mailto:qemu-devel-request@nongnu.org?subject=help>","List-Subscribe":"<https://lists.nongnu.org/mailman/listinfo/qemu-devel>,\n <mailto:qemu-devel-request@nongnu.org?subject=subscribe>","Cc":"Kevin Wolf <kwolf@redhat.com>,\n Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>,\n Alberto Garcia <berto@igalia.com>, qemu-block@nongnu.org,\n Derek Su <dereksu@qnap.com>, Max Reitz <mreitz@redhat.com>","Errors-To":"qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org","Sender":"\"Qemu-devel\"\n <qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org>"},"content":"Hi,\n\nhere's the new version of the patches to add subcluster allocation\nsupport to qcow2.\n\nPlease refer to the cover letter of the first version for a full\ndescription of the patches:\n\n   https://lists.gnu.org/archive/html/qemu-block/2019-10/msg00983.html\n\nThe big change here is that now when an image is preallocated then the\nrequested clusters are allocated but the L2 bitmap is left untouched.\nThis makes it possible to preallocate an image that has a backing\nfile.\n\nIf you want to test this series make sure to apply this patch first:\n\n   https://lists.gnu.org/archive/html/qemu-block/2020-06/msg00504.html\n\nBerto\n\nv8:\n- Patch 30: New patch\n- Patch 31: Update test expectations after commit cf2d1203dc\n- Patch 32: New patch\n- Patch 34: New tests, fixes and general refactoring of the code\n\nv7: https://lists.gnu.org/archive/html/qemu-block/2020-05/msg01683.html\nv6: https://lists.gnu.org/archive/html/qemu-block/2020-05/msg01583.html\nv5: https://lists.gnu.org/archive/html/qemu-block/2020-05/msg00251.html\nv4: https://lists.gnu.org/archive/html/qemu-block/2020-03/msg00966.html\nv3: https://lists.gnu.org/archive/html/qemu-block/2019-12/msg00587.html\nv2: https://lists.gnu.org/archive/html/qemu-block/2019-10/msg01642.html\nv1: https://lists.gnu.org/archive/html/qemu-block/2019-10/msg00983.html\n\nOutput of git backport-diff against v7:\n\nKey:\n[----] : patches are identical\n[####] : number of functional differences between upstream/downstream patch\n[down] : patch is downstream-only\nThe flags [FC] indicate (F)unctional and (C)ontextual differences, respectively\n\n001/34:[----] [--] 'qcow2: Make Qcow2AioTask store the full host offset'\n002/34:[----] [--] 'qcow2: Convert qcow2_get_cluster_offset() into qcow2_get_host_offset()'\n003/34:[----] [--] 'qcow2: Add calculate_l2_meta()'\n004/34:[----] [--] 'qcow2: Split cluster_needs_cow() out of count_cow_clusters()'\n005/34:[----] [--] 'qcow2: Process QCOW2_CLUSTER_ZERO_ALLOC clusters in handle_copied()'\n006/34:[----] [--] 'qcow2: Add get_l2_entry() and set_l2_entry()'\n007/34:[----] [--] 'qcow2: Document the Extended L2 Entries feature'\n008/34:[----] [--] 'qcow2: Add dummy has_subclusters() function'\n009/34:[----] [--] 'qcow2: Add subcluster-related fields to BDRVQcow2State'\n010/34:[----] [--] 'qcow2: Add offset_to_sc_index()'\n011/34:[----] [--] 'qcow2: Add offset_into_subcluster() and size_to_subclusters()'\n012/34:[----] [--] 'qcow2: Add l2_entry_size()'\n013/34:[----] [--] 'qcow2: Update get/set_l2_entry() and add get/set_l2_bitmap()'\n014/34:[----] [--] 'qcow2: Add QCow2SubclusterType and qcow2_get_subcluster_type()'\n015/34:[----] [--] 'qcow2: Add qcow2_get_subcluster_range_type()'\n016/34:[----] [--] 'qcow2: Add qcow2_cluster_is_allocated()'\n017/34:[----] [--] 'qcow2: Add cluster type parameter to qcow2_get_host_offset()'\n018/34:[----] [--] 'qcow2: Replace QCOW2_CLUSTER_* with QCOW2_SUBCLUSTER_*'\n019/34:[----] [--] 'qcow2: Handle QCOW2_SUBCLUSTER_UNALLOCATED_ALLOC'\n020/34:[----] [--] 'qcow2: Add subcluster support to calculate_l2_meta()'\n021/34:[----] [--] 'qcow2: Add subcluster support to qcow2_get_host_offset()'\n022/34:[----] [--] 'qcow2: Add subcluster support to zero_in_l2_slice()'\n023/34:[----] [--] 'qcow2: Add subcluster support to discard_in_l2_slice()'\n024/34:[----] [--] 'qcow2: Add subcluster support to check_refcounts_l2()'\n025/34:[----] [--] 'qcow2: Update L2 bitmap in qcow2_alloc_cluster_link_l2()'\n026/34:[----] [--] 'qcow2: Clear the L2 bitmap when allocating a compressed cluster'\n027/34:[----] [--] 'qcow2: Add subcluster support to handle_alloc_space()'\n028/34:[----] [--] 'qcow2: Add subcluster support to qcow2_co_pwrite_zeroes()'\n029/34:[----] [-C] 'qcow2: Add subcluster support to qcow2_measure()'\n030/34:[down] 'qcow2: Add prealloc field to QCowL2Meta'\n031/34:[0002] [FC] 'qcow2: Add the 'extended_l2' option and the QCOW2_INCOMPAT_EXTL2 bit'\n032/34:[down] 'qcow2: Allow preallocation and backing files if extended_l2 is set'\n033/34:[----] [--] 'qcow2: Assert that expand_zero_clusters_in_l1() does not support subclusters'\n034/34:[0669] [FC] 'iotests: Add tests for qcow2 images with extended L2 entries'\n\nAlberto Garcia (34):\n  qcow2: Make Qcow2AioTask store the full host offset\n  qcow2: Convert qcow2_get_cluster_offset() into qcow2_get_host_offset()\n  qcow2: Add calculate_l2_meta()\n  qcow2: Split cluster_needs_cow() out of count_cow_clusters()\n  qcow2: Process QCOW2_CLUSTER_ZERO_ALLOC clusters in handle_copied()\n  qcow2: Add get_l2_entry() and set_l2_entry()\n  qcow2: Document the Extended L2 Entries feature\n  qcow2: Add dummy has_subclusters() function\n  qcow2: Add subcluster-related fields to BDRVQcow2State\n  qcow2: Add offset_to_sc_index()\n  qcow2: Add offset_into_subcluster() and size_to_subclusters()\n  qcow2: Add l2_entry_size()\n  qcow2: Update get/set_l2_entry() and add get/set_l2_bitmap()\n  qcow2: Add QCow2SubclusterType and qcow2_get_subcluster_type()\n  qcow2: Add qcow2_get_subcluster_range_type()\n  qcow2: Add qcow2_cluster_is_allocated()\n  qcow2: Add cluster type parameter to qcow2_get_host_offset()\n  qcow2: Replace QCOW2_CLUSTER_* with QCOW2_SUBCLUSTER_*\n  qcow2: Handle QCOW2_SUBCLUSTER_UNALLOCATED_ALLOC\n  qcow2: Add subcluster support to calculate_l2_meta()\n  qcow2: Add subcluster support to qcow2_get_host_offset()\n  qcow2: Add subcluster support to zero_in_l2_slice()\n  qcow2: Add subcluster support to discard_in_l2_slice()\n  qcow2: Add subcluster support to check_refcounts_l2()\n  qcow2: Update L2 bitmap in qcow2_alloc_cluster_link_l2()\n  qcow2: Clear the L2 bitmap when allocating a compressed cluster\n  qcow2: Add subcluster support to handle_alloc_space()\n  qcow2: Add subcluster support to qcow2_co_pwrite_zeroes()\n  qcow2: Add subcluster support to qcow2_measure()\n  qcow2: Add prealloc field to QCowL2Meta\n  qcow2: Add the 'extended_l2' option and the QCOW2_INCOMPAT_EXTL2 bit\n  qcow2: Allow preallocation and backing files if extended_l2 is set\n  qcow2: Assert that expand_zero_clusters_in_l1() does not support\n    subclusters\n  iotests: Add tests for qcow2 images with extended L2 entries\n\n docs/interop/qcow2.txt           |  68 ++-\n docs/qcow2-cache.txt             |  19 +-\n qapi/block-core.json             |   7 +\n block/qcow2.h                    | 211 ++++++-\n include/block/block_int.h        |   1 +\n block/qcow2-cluster.c            | 912 +++++++++++++++++++++----------\n block/qcow2-refcount.c           |  38 +-\n block/qcow2.c                    | 304 +++++++----\n block/trace-events               |   2 +-\n tests/qemu-iotests/031.out       |   8 +-\n tests/qemu-iotests/036.out       |   4 +-\n tests/qemu-iotests/049.out       | 102 ++--\n tests/qemu-iotests/060.out       |   1 +\n tests/qemu-iotests/061           |   6 +\n tests/qemu-iotests/061.out       |  25 +-\n tests/qemu-iotests/065           |  12 +-\n tests/qemu-iotests/082.out       |  48 +-\n tests/qemu-iotests/085.out       |  38 +-\n tests/qemu-iotests/144.out       |   4 +-\n tests/qemu-iotests/182.out       |   2 +-\n tests/qemu-iotests/185.out       |   8 +-\n tests/qemu-iotests/198.out       |   2 +\n tests/qemu-iotests/206.out       |   6 +-\n tests/qemu-iotests/242.out       |   5 +\n tests/qemu-iotests/255.out       |   8 +-\n tests/qemu-iotests/271           | 801 +++++++++++++++++++++++++++\n tests/qemu-iotests/271.out       | 676 +++++++++++++++++++++++\n tests/qemu-iotests/274.out       |  49 +-\n tests/qemu-iotests/280.out       |   2 +-\n tests/qemu-iotests/291.out       |   2 +\n tests/qemu-iotests/common.filter |   1 +\n tests/qemu-iotests/group         |   1 +\n 32 files changed, 2807 insertions(+), 566 deletions(-)\n create mode 100755 tests/qemu-iotests/271\n create mode 100644 tests/qemu-iotests/271.out"}