From nobody Sat Nov 15 22:35:15 2025 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=quarantine dis=none) header.from=virtuozzo.com ARC-Seal: i=1; a=rsa-sha256; t=1747100223; cv=none; d=zohomail.com; s=zohoarc; b=U9PC0c14BEiKrqIAAuAPq9621w3K8hFcRmrT8X+CUQpAznUDpgCFcLHpEPV5LQvf2jkuVrO4UdTX4aLU2ZaZ3YPWJ7DwlmAqWx5fJsUh3hK6TJEzYNCIn4AI0HKTFrorDLgYnsUoin3CUWeec/9+s3xhpmfIzkldL+R0TLHDQ+Y= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1747100223; h=Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=o76L16+85oXwxINpy+kttS3ujUGzFeqh/Z5rK6Yd30A=; b=nqLfqmbcEw4ScLdmFLVv+9W+Zy2gn1AOx8sK0VRmIcMR5gNLNlJWvgBNFymtkUuemFMGodXYGV8MqUkbx9J+x9uksVvms5J2/zHzg1pegLb5RfAEP7gxy+9BaAMUOx+NofewCPwuSJJTEYQSr/nuFTvnPkhvM21qWDy8SF5m9jc= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=quarantine dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1747100223011906.5920028817487; Mon, 12 May 2025 18:37:03 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1uEeYm-0002If-SP; Mon, 12 May 2025 21:35:56 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1uEeYi-0002F1-Cy; Mon, 12 May 2025 21:35:52 -0400 Received: from relay.virtuozzo.com ([130.117.225.111]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1uEeYf-00021T-Vp; Mon, 12 May 2025 21:35:52 -0400 Received: from ch-vpn.virtuozzo.com ([130.117.225.6] helo=debian.fritz.box) by relay.virtuozzo.com with esmtp (Exim 4.96) (envelope-from ) id 1uEeUe-00DboQ-0k; Tue, 13 May 2025 03:35:36 +0200 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=virtuozzo.com; s=relay; h=MIME-Version:Message-ID:Date:Subject:From: Content-Type; bh=o76L16+85oXwxINpy+kttS3ujUGzFeqh/Z5rK6Yd30A=; b=sYq6qqZJtCIi mob/IlvSIwTcwVRxDbI2ZBcogj/VFPV27TEIVL2GpW/Ybg/MQlnE9Ax5z0j2VN46VokneLb9CKyAc oowjJ6K0Wxolize8ytDSwdaQBcHv6UeOAJ04jmD9y0up9yyzig0I2J2FR1uEeDRUm0ypk3YB0ehb6 EoWpmjAEgC7+ZRiva5VJVTwqK8xp/rBrgPwPu4RG/mQmt0wQOOCbGIwtyZAjzK7L04qdsjKEZwPMV mbMYbajDft+Zmd4psP+DzcFw7Oau67H3zkgDJDmihiNEYgWWqw36+lDzrwHj/znYK/H41EetFVolQ MKeaLjmQhLfL+hU0zs/4Wg==; From: Andrey Zhadchenko To: qemu-block@nongnu.org, vsementsov@yandex-team.ru, eblake@redhat.com Cc: jsnow@redhat.com, kwolf@redhat.com, hreitz@redhat.com, qemu-devel@nongnu.org, andrey.drobyshev@virtuozzo.com, den@virtuozzo.com Subject: [PATCH 1/4] hbitmap: drop meta bitmap leftovers Date: Tue, 13 May 2025 03:32:35 +0200 Message-ID: <20250513013238.1213539-2-andrey.zhadchenko@virtuozzo.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20250513013238.1213539-1-andrey.zhadchenko@virtuozzo.com> References: <20250513013238.1213539-1-andrey.zhadchenko@virtuozzo.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.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; Received-SPF: pass client-ip=130.117.225.111; envelope-from=andrey.zhadchenko@virtuozzo.com; helo=relay.virtuozzo.com X-Spam_score_int: -43 X-Spam_score: -4.4 X-Spam_bar: ---- X-Spam_report: (-4.4 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_MED=-2.3, RCVD_IN_VALIDITY_CERTIFIED_BLOCKED=0.001, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @virtuozzo.com) X-ZM-MESSAGEID: 1747100224055116600 Content-Type: text/plain; charset="utf-8" API to manipulate meta bitmap was removed with commit 0c88f1970c76 Signed-off-by: Andrey Zhadchenko Reviewed-by: Eric Blake --- util/hbitmap.c | 17 ++--------------- 1 file changed, 2 insertions(+), 15 deletions(-) diff --git a/util/hbitmap.c b/util/hbitmap.c index d9a1dabc63..16674f33e4 100644 --- a/util/hbitmap.c +++ b/util/hbitmap.c @@ -84,9 +84,6 @@ struct HBitmap { */ int granularity; =20 - /* A meta dirty bitmap to track the dirtiness of bits in this HBitmap.= */ - HBitmap *meta; - /* A number of progressively less coarse bitmaps (i.e. level 0 is the * coarsest). Each bit in level N represents a word in level N+1 that * has a set bit, except the last level where each bit represents the @@ -480,10 +477,7 @@ void hbitmap_set(HBitmap *hb, uint64_t start, uint64_t= count) n =3D last - first + 1; =20 hb->count +=3D n - hb_count_between(hb, first, last); - if (hb_set_between(hb, HBITMAP_LEVELS - 1, first, last) && - hb->meta) { - hbitmap_set(hb->meta, start, count); - } + hb_set_between(hb, HBITMAP_LEVELS - 1, first, last); } =20 /* Resetting works the other way round: propagate up if the new @@ -577,10 +571,7 @@ void hbitmap_reset(HBitmap *hb, uint64_t start, uint64= _t count) assert(last < hb->size); =20 hb->count -=3D hb_count_between(hb, first, last); - if (hb_reset_between(hb, HBITMAP_LEVELS - 1, first, last) && - hb->meta) { - hbitmap_set(hb->meta, start, count); - } + hb_reset_between(hb, HBITMAP_LEVELS - 1, first, last); } =20 void hbitmap_reset_all(HBitmap *hb) @@ -784,7 +775,6 @@ void hbitmap_deserialize_finish(HBitmap *bitmap) void hbitmap_free(HBitmap *hb) { unsigned i; - assert(!hb->meta); for (i =3D HBITMAP_LEVELS; i-- > 0; ) { g_free(hb->levels[i]); } @@ -868,9 +858,6 @@ void hbitmap_truncate(HBitmap *hb, uint64_t size) (size - old) * sizeof(*hb->levels[i])); } } - if (hb->meta) { - hbitmap_truncate(hb->meta, hb->size << hb->granularity); - } } =20 /** --=20 2.43.0