Received: by 2002:ab2:1689:0:b0:1f7:5705:b850 with SMTP id d9csp1254187lqa; Mon, 29 Apr 2024 03:07:04 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCXjzELFsLYLp35XfrbVYiMNQqsD0c6fJz2ws1m+PWcStw0khZKgEqHPlsES/fM3+ck5g5o1x2etyp3jrFpwKLTfK9sAOr8sb3lRQ3Tljg== X-Google-Smtp-Source: AGHT+IGJrGCRbiVIAmPRPtIx2T9V9J+jp2TzsTRzxXma375CC+YCpRVRiuP9teufvyruMR6J0Afi X-Received: by 2002:a05:620a:3913:b0:790:ea3e:61cf with SMTP id qr19-20020a05620a391300b00790ea3e61cfmr7601923qkn.15.1714385224028; Mon, 29 Apr 2024 03:07:04 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1714385224; cv=pass; d=google.com; s=arc-20160816; b=xkz7il/UDcvgE6JVc9+u1S+ccujuEQdp9EnmrnokR2sqrasQTRrHx3qxBinZ/bhn2z DLYH6clvb8gyAj7ZQPIVJXLLHiB1lCAu+msUbemMaK1PDhSgnnwdrp6YG+lbtFomVIFU JEJOV3fYh8YRfVKjNHnil7cbFOJfxzNusClSvFDo8gh+4j4gKyAT3Ddyx+n3VJMlENg2 AQyGQNR/S6ER3imUXolKk2JrP+5XSHdnLCL3yh0r22FKAIEGTSMHbppl6lQOSb2HXndG yUzWCY8zMxmtyvY9uce4BF0pnnl8uM0EdahRIl35nWt5WvJe/kD/6MPF9LmiSCjXWwIO 8G0g== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:message-id:subject:cc :to:from:date:dkim-signature; bh=wZLTTPnjjgVPc51teM35bkMR46cidPv+y0mcRd/jT54=; fh=EU2kp9BKNoDbLTF7yPnW9aw3LK2kVj10jUgx36seWpg=; b=e2uAzsYKXQVU970PNExbcp2+xr9ikJoFTtZl/o/VIPV2BHDt2yvtV5QG2ZEPEWx9By uj0KGXEngQuRVxbK7dW/B+nODREQxb4rJvaR+j0DPP4B8lxniN5x4EMTyEpbCdDycZf/ YLPYK4LjZ0eWYcD6k2lSdT5fMlyWqtK2s3OudBnjJa6zq00szIYAIRQKQ9q51KNI+Wl4 WO1aeX9H7o2csbWdQda0g4VVfWgONfmiTehjfKcpBdX32co6WW6Geg78ZNVgUTuH1gI6 eJ0eGftVcdqGTQMfuVJkFhCcnmOlQGgCDliyvc2g6YRP73JQZ6UR1brACPxaNr8ZAUkY 9mJw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@infradead.org header.s=bombadil.20210309 header.b=iUD8i6Sk; arc=pass (i=1 dkim=pass dkdomain=infradead.org); spf=pass (google.com: domain of linux-kernel+bounces-161734-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-161734-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id f21-20020a05620a15b500b0078ee1fed4easi25526936qkk.543.2024.04.29.03.07.03 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 29 Apr 2024 03:07:04 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-161734-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; dkim=pass header.i=@infradead.org header.s=bombadil.20210309 header.b=iUD8i6Sk; arc=pass (i=1 dkim=pass dkdomain=infradead.org); spf=pass (google.com: domain of linux-kernel+bounces-161734-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-161734-linux.lists.archive=gmail.com@vger.kernel.org" Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 68A841C21AAE for ; Mon, 29 Apr 2024 04:41:59 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 7E75CD51D; Mon, 29 Apr 2024 04:41:49 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=infradead.org header.i=@infradead.org header.b="iUD8i6Sk" Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 7F5D279F9; Mon, 29 Apr 2024 04:41:47 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=198.137.202.133 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714365708; cv=none; b=hhhPZZMSepA0/bThEMNCrYksjLwsNbv/P7G3EdwTHR91f2pro7UV4NmPGhq6/sMiwSFFMcQetGv4F0e7qRCcjrYhy0asL7VlIKjR22ofBv26OOmG4ORcJ4M0BX8kxPs/YfXLfjA1x/3lKk8A6nRpq3zQreVo0oDtY+cX0tek0B0= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714365708; c=relaxed/simple; bh=owcXP+fsTgaHZFyUzCBMT1bCDgfz3/4CftWoEv2Acic=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=hMdjmxWcyDk2yVUinm4S+zGIJlSlm1VfkPG6PCy9uZwHVR9LoVL+HgZQ1jfyXhijIhLZAbzg7DNXBmgFuHyLYoMgFg3Cro2FwKG/3Rl5cGYMvHZv6pi/yca2X/RiEhjjzb3Cmntk8kvBjC3+5HsF74WttqrPd+Cn7ZrcOJ8RjJw= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=infradead.org; spf=none smtp.mailfrom=bombadil.srs.infradead.org; dkim=pass (2048-bit key) header.d=infradead.org header.i=@infradead.org header.b=iUD8i6Sk; arc=none smtp.client-ip=198.137.202.133 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=infradead.org Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=bombadil.srs.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=In-Reply-To:Content-Type:MIME-Version :References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=wZLTTPnjjgVPc51teM35bkMR46cidPv+y0mcRd/jT54=; b=iUD8i6SkDwuRDoyxK+6J+lVAFg kx4jy3bRbUcjCs4nzPAwR9bzpl1MCcr9+66rNBv8BQOwCgihP/M31/xiU6rvf6r13WjAAlIks3z5F E+gJ21n42uwY3TvDgrjA7tdv/JQh8D1KeiEzCU2Us7SeCgo05e1CnOVRq2+M0bZistaRxizzW2KyC /HeDnBbcWwCYkmXYrzI8i083Nx7QTWMMSQmUxm7GrcO6LVn3IiNzPC7vp3VGOHsxMSKBETn7Lm6Nu mwnCMr9QxVldF1Mzq06V2VhvSTzzsbErJ554QUzi9NbcdxhwnM2GlcAvjveaVySRBJmC5mAN3Xm7y ZqvYu4Nw==; Received: from hch by bombadil.infradead.org with local (Exim 4.97.1 #2 (Red Hat Linux)) id 1s1Ipl-00000001RPG-2exv; Mon, 29 Apr 2024 04:41:45 +0000 Date: Sun, 28 Apr 2024 21:41:45 -0700 From: Christoph Hellwig To: Zhang Yi Cc: Christoph Hellwig , "Darrick J. Wong" , linux-xfs@vger.kernel.org, linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org, brauner@kernel.org, david@fromorbit.com, chandanbabu@kernel.org, tytso@mit.edu, jack@suse.cz, yi.zhang@huawei.com, chengzhihao1@huawei.com, yukuai3@huawei.com Subject: Re: [PATCH v5 4/9] xfs: convert delayed extents to unwritten when zeroing post eof blocks Message-ID: References: <20240425131335.878454-1-yi.zhang@huaweicloud.com> <20240425131335.878454-5-yi.zhang@huaweicloud.com> <20240425182904.GA360919@frogsfrogsfrogs> <3be86418-e629-c7e6-fd73-f59f97a73a89@huaweicloud.com> <5b6228ce-c553-3387-dfc4-2db78e3bd810@huaweicloud.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html On Sun, Apr 28, 2024 at 11:26:00AM +0800, Zhang Yi wrote: > > > > Oh well. Given that we're full in on the speculative allocations > > we might as well deal with it. > > > > Let me confirm, so you also think the preallocations in the COW fork that > overlaps the unreflinked range is useless, we should avoid allocating > this range, is that right? If so, I suppose we can do this improvement in > another patch(set), this one works fine now. Well, not stop allocating it, but not actually convert it to a real allocation when we're just truncating it and replacing the blocks with reflinked blocks. But yes, this is a bigger project. For now for this patch to go ahead: Reviewed-by: Christoph Hellwig