From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) (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 79390302158 for ; Mon, 10 Nov 2025 10:03:59 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=170.10.129.124 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1762769041; cv=none; b=FgMTosz94lK9JmW38jurmrfhfgGnkR+HvOv9hYIGTfrAh8jGBmtBFh4I96xh9hsVz3S5xdvvgkTuw/uPbPQczWmATRCTncsGStLQEMxUmJuCcRxtx4EzflnCleMdDkd3UM4yg+mLdknc19O8cpIGb7CxSOmZezq4403i1rTkzkA= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1762769041; c=relaxed/simple; bh=xMPm2roPNOiQD1q4be1XihMW21gDvf9YbXLroWX6Tnw=; h=From:To:Cc:Subject:In-Reply-To:References:Date:Message-ID: MIME-Version:Content-Type; b=V54tEuJGacxrJVO2JGSfCawUjaecdC5aWT3yvm60YCU8x4RxP1zQV7W/nDx27n3RmCNzSWPepJrIwgdFEWan9D0+ZFnsu/rvvSMdnKX3GdGiXxhY+1KtVPFjB5S3qwL8xcTxuT4slyUvd/M+tEpd/PDW6Kxf4880invUgHYEpNI= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=redhat.com; spf=pass smtp.mailfrom=redhat.com; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b=iAdN9uOK; arc=none smtp.client-ip=170.10.129.124 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=redhat.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=redhat.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b="iAdN9uOK" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1762769038; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=qycs3QBWuphW6IaV/2MMmVqLjCAStIYoGfDJBOz4Br0=; b=iAdN9uOKiD6e2AUNt1DOWER6Yx8Ici7KifijqbPvIWKT3gfTrpRB88vTdd0oGeEakrXQdQ rcKL/c1nqwIcpsOnWoVfOrXR0Jb15m7qlXgr064h3uDAE75Ps+GqH9Xg7KiCjyETrWC05Z oxGDnukPlGSfycXrbbZPNiNqCmELEAk= Received: from mx-prod-mc-01.mail-002.prod.us-west-2.aws.redhat.com (ec2-54-186-198-63.us-west-2.compute.amazonaws.com [54.186.198.63]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-345-aFxD10TfOmGWdUeGPQvyBQ-1; Mon, 10 Nov 2025 05:03:56 -0500 X-MC-Unique: aFxD10TfOmGWdUeGPQvyBQ-1 X-Mimecast-MFC-AGG-ID: aFxD10TfOmGWdUeGPQvyBQ_1762769034 Received: from mx-prod-int-06.mail-002.prod.us-west-2.aws.redhat.com (mx-prod-int-06.mail-002.prod.us-west-2.aws.redhat.com [10.30.177.93]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mx-prod-mc-01.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id 6EADA195609F; Mon, 10 Nov 2025 10:03:54 +0000 (UTC) Received: from fweimer-oldenburg.csb.redhat.com (unknown [10.44.32.47]) by mx-prod-int-06.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id 3A5391800576; Mon, 10 Nov 2025 10:03:50 +0000 (UTC) From: Florian Weimer To: Christoph Hellwig Cc: Dave Chinner , Matthew Wilcox , Hans Holmberg , linux-xfs@vger.kernel.org, Carlos Maiolino , "Darrick J . Wong" , 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 In-Reply-To: <20251110093828.GC22674@lst.de> (Christoph Hellwig's message of "Mon, 10 Nov 2025 10:38:28 +0100") References: <20251106133530.12927-1-hans.holmberg@wdc.com> <20251106135212.GA10477@lst.de> <20251106170501.GA25601@lst.de> <878qgg4sh1.fsf@mid.deneb.enyo.de> <20251110093828.GC22674@lst.de> Date: Mon, 10 Nov 2025 11:03:48 +0100 Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain X-Scanned-By: MIMEDefang 3.4.1 on 10.30.177.93 * Christoph Hellwig: > On Mon, Nov 10, 2025 at 06:27:41AM +0100, Florian Weimer wrote: >> Sorry, I made the example confusing. >> >> How would the application deal with failure due to lack of fallocate >> support? It would have to do a pwrite, like posix_fallocate does to >> today, or maybe ftruncate. This is way I think removing the fallback >> from posix_fallocate completely is mostly pointless. > > In general it would ftruncate. If it thinks it can't work without > preallocation at all the application will fail, as again the lack > of posix_fallocate means that space can't be preallocated. Hmm. It's not a 1:1 replacement: someone really needs to understand the code and see what the appropriate way to deal with the situation is. Of course the posix_fallocate fallback path (or an application-level equivalent) has the potential for data loss, too. It's just a different trade-off. Thanks, Florian