From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from verein.lst.de (verein.lst.de [213.95.11.211]) (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 725C9303CB4; Thu, 6 Nov 2025 13:52:23 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=213.95.11.211 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1762437145; cv=none; b=toOJifeStrlwgFOPtljAd7DR7aWJkcz20IEhcoGi8TMnTACFtrN6OlY5EMZaMdILJ7skJkTr03+ksC4Jk1pKF+VTfsubiwp/ihrYdogW9hP04F19WeQ7BnUXYlX54/PoaS7tEhhvwsVW4r9dnta9BKtmB2bV3f1ZpP5GJj54kIo= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1762437145; c=relaxed/simple; bh=oWDHkFTVXZZsXOi4gtkmtUtQVoQsLeLNoQFUWNDUZ5g=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=WT7a7Ex/RU258HuaI5hQs34F1TFv57LL/IcNPGeZzGBwdxJDvoRvgcQo2tm268W+6qXL1kiNLsJfNDCcipC/gPZ9n7d3hRt9A4p5ZUHfGpQLgCYlHBzAnL6QRNAlTtYCYTngY8zg86N72ZrUMpEy8cndDq/vCOxScOratXeTPTw= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=lst.de; spf=pass smtp.mailfrom=lst.de; arc=none smtp.client-ip=213.95.11.211 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=lst.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=lst.de Received: by verein.lst.de (Postfix, from userid 2407) id 13794227A87; Thu, 6 Nov 2025 14:52:13 +0100 (CET) Date: Thu, 6 Nov 2025 14:52:12 +0100 From: Christoph Hellwig To: Florian Weimer Cc: Hans Holmberg , linux-xfs@vger.kernel.org, Carlos Maiolino , Dave Chinner , "Darrick J . Wong" , Christoph Hellwig , linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org, libc-alpha@sourceware.org Subject: Re: [RFC] xfs: fake fallocate success for always CoW inodes Message-ID: <20251106135212.GA10477@lst.de> References: <20251106133530.12927-1-hans.holmberg@wdc.com> Precedence: bulk X-Mailing-List: linux-xfs@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: User-Agent: Mutt/1.5.17 (2007-11-01) On Thu, Nov 06, 2025 at 02:48:12PM +0100, Florian Weimer wrote: > * Hans Holmberg: > > > We don't support preallocations for CoW inodes and we currently fail > > with -EOPNOTSUPP, but this causes an issue for users of glibc's > > posix_fallocate[1]. If fallocate fails, posix_fallocate falls back on > > writing actual data into the range to try to allocate blocks that way. > > That does not actually gurantee anything for CoW inodes however as we > > write out of place. > > Why doesn't fallocate trigger the copy instead? Isn't this what the > user is requesting? What copy?