From nobody Sat Nov 15 23:39:36 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=dupond.be ARC-Seal: i=1; a=rsa-sha256; t=1745922734; cv=none; d=zohomail.com; s=zohoarc; b=QkPRU1Q8he3WpqsT+a4TPV4iC6EIxcRMMmfiKjM9vjHEVn0MSfZBbsarISx4hF+AoKaJjsulcAqSCsI6aHuP28LCl2a4bDun2Z6TMBisbVwshsRV17A5nLD0DxHc0n4muToc6EqezCvedFwtwsbXehBVnzn7Bc3WP4Z4c8mC7wk= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1745922734; 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=WYCS5iAb/Nn8x3gGPhGp/cJX9hFVTuhSLnP3r8HVESs=; b=DYa+XXEEQN3Db3AWsSVsOhteMb2yvpWWFKbVAtQplCKDt4Tn3r17lo3n1H+BIffVblXJJlL+ltET7yOllV28Xj9tQz22gIlbVeV6DvBNE4+QAGeabUkPv5Vj2pnyE1LTlBjtHXGKz0YWn69D559qBtOwIiYgDoZh5vMPiQwVkFU= 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 174592273432832.15501300715687; Tue, 29 Apr 2025 03:32:14 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1u9iFr-0000Wo-2k; Tue, 29 Apr 2025 06:31:59 -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 1u9iFk-0000Pl-8k; Tue, 29 Apr 2025 06:31:52 -0400 Received: from apollo.dupie.be ([51.159.20.238]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1u9iFh-0007QB-82; Tue, 29 Apr 2025 06:31:51 -0400 Received: from localhost.localdomain (unknown [IPv6:2a00:1c98:fff1:1001:aee7:ee9c:3ae8:78e2]) by apollo.dupie.be (Postfix) with ESMTPSA id 70BE91520F34; Tue, 29 Apr 2025 12:31:39 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=dupond.be; s=dkim; t=1745922699; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=WYCS5iAb/Nn8x3gGPhGp/cJX9hFVTuhSLnP3r8HVESs=; b=P9QWHKX+5+MKLiQOa0jN+Bm5Sq/wbcI0pr5Ddg0AXCs4h5xcHmcJYBBvz2RhFTWxkVUTw4 wcY6mlPaHiU05+OBYhBFEhrWz3TJEAPSl6baguBKeZK+oAMCm/vwBolO7ke1hUUfwR+/g1 EIeJwJPLNR4FC//DXKxV5mng8d/SSFxCyMXGXzDA6PknsNVCoXoTYNLFXrIzzJ9IlWSSar Tia2nKCiMbRjSQkHaHAdxtXHB9zXsnT17V2LUU36xDUXlZDnGZe0RyaqUeYe0N0kkFyN0f S+K+gcnatrIOIurxTPjwpCnivW/gjcY/Kk/WFKOTpfifG+7sGSgJ3JX8WvwFbw== From: Jean-Louis Dupond To: qemu-devel@nongnu.org Cc: Alexander Ivanov , Kevin Wolf , Andrey Drobyshev , Hanna Reitz , qemu-block@nongnu.org, Jean-Louis Dupond Subject: [PATCH 1/2] qcow2: rename update_refcount_discard to queue_discard Date: Tue, 29 Apr 2025 12:31:09 +0200 Message-ID: <20250429103110.761910-2-jean-louis@dupond.be> X-Mailer: git-send-email 2.49.0 In-Reply-To: <20250429103110.761910-1-jean-louis@dupond.be> References: <20250429103110.761910-1-jean-louis@dupond.be> 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=51.159.20.238; envelope-from=jean-louis@dupond.be; helo=apollo.dupie.be 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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, 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 @dupond.be) X-ZM-MESSAGEID: 1745922737375019000 Content-Type: text/plain; charset="utf-8" The function just queues discards, and doesn't do any refcount change. So let's change the function name to align with its function. Signed-off-by: Jean-Louis Dupond --- block/qcow2-refcount.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/block/qcow2-refcount.c b/block/qcow2-refcount.c index 0266542cee..d796018970 100644 --- a/block/qcow2-refcount.c +++ b/block/qcow2-refcount.c @@ -754,8 +754,8 @@ void qcow2_process_discards(BlockDriverState *bs, int r= et) } } =20 -static void update_refcount_discard(BlockDriverState *bs, - uint64_t offset, uint64_t length) +static void queue_discard(BlockDriverState *bs, + uint64_t offset, uint64_t length) { BDRVQcow2State *s =3D bs->opaque; Qcow2DiscardRegion *d, *p, *next; @@ -902,7 +902,7 @@ update_refcount(BlockDriverState *bs, int64_t offset, i= nt64_t length, } =20 if (s->discard_passthrough[type]) { - update_refcount_discard(bs, cluster_offset, s->cluster_siz= e); + queue_discard(bs, cluster_offset, s->cluster_size); } } } --=20 2.49.0