Received: by 2002:a05:6358:7058:b0:131:369:b2a3 with SMTP id 24csp8565889rwp; Wed, 19 Jul 2023 11:41:16 -0700 (PDT) X-Google-Smtp-Source: APBJJlEy/zFTvYvI0rW7QlaFo+1pGPOueSbwgzuVoRgTII1Is3OVQi14PWpQ82gU8fyFg/YSjPht X-Received: by 2002:a17:906:cc18:b0:988:d1d5:cd5b with SMTP id ml24-20020a170906cc1800b00988d1d5cd5bmr2936797ejb.75.1689792075981; Wed, 19 Jul 2023 11:41:15 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1689792075; cv=none; d=google.com; s=arc-20160816; b=GLd8a+ALYT63UXuwG/iG1zoNMvtSlsyTyUBtCXD4Mence+fWJk6Yth9TK/I3eBrtXr CPQ2xBIsqwLDfrO2kCTO4ul9anXDoJ3ZPq1tg89aLjeuhsrQXDEHk7uM/EWGqqC6YUTo LNpPzu6FCAZJnnIU9v1reCo4K+8/U9JJ/xznWJPG/yCXDKeATa0CC4TYdzahKnSMUseM MKt/hpv+nlW3ALD6pFd6S+8tNOOafq6vvhU3OYUuMwgySm2ZbIY3se4/dVivUWkDzaod isPMBF9yHhZapprMsFEeZ/87DLKd5uFd1srTk/dhR9shbzU/Dv4gcXymfIs6BrpDbR4a imTA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:user-agent:references :in-reply-to:message-id:mime-version:date:subject:cc:to:from :dkim-signature; bh=/6lKYap9PZZRLrRmess6iU23U+m+a8OOtwMIqKZ8RIU=; fh=iDZOAj5evGT/4CVLAWEIwqHiWhP76Wl1nEPVTFg7wBQ=; b=GNQ+bufbixvfyQcOXCkr+AVecMlgQg3uuapoKqW0iF29noGusB4YWxHnF1UVD9XTeH ELBrIf2O3rmMdQ4Vt3j4sy6GuAesffIcioZkZuMC2irXm6PzCNd/GDx10aOrZmQIqLFe EfXfGY8vow6P/ZChV3XjRtDY9KfvT0nOIR5rBNPgZ3un1q+q2cSZhoQApwoxXnwjK/My +uUtzjFfYFe18mCRALfZXHM+o58Q6fY1QQNusr9g7YIO4u857csvqlrgzR/cOlSgiwYm 1dgwkyrMNUGv2dJY/JaTUy3ALtwn6neVWwM1rrO9wbs8yHHXaSdHu6XmxShYLqhe9B3n f1HQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@comcastmailservice.net header.s=20211018a header.b=VcFEsTlS; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id c9-20020a170906d18900b00992d7428e55si2901548ejz.922.2023.07.19.11.40.51; Wed, 19 Jul 2023 11:41:15 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@comcastmailservice.net header.s=20211018a header.b=VcFEsTlS; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230128AbjGSSB6 (ORCPT + 99 others); Wed, 19 Jul 2023 14:01:58 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44246 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229788AbjGSSB4 (ORCPT ); Wed, 19 Jul 2023 14:01:56 -0400 X-Greylist: delayed 150 seconds by postgrey-1.37 at lindbergh.monkeyblade.net; Wed, 19 Jul 2023 11:01:54 PDT Received: from resqmta-a1p-077723.sys.comcast.net (resqmta-a1p-077723.sys.comcast.net [IPv6:2001:558:fd01:2bb4::9]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C80C31FCB for ; Wed, 19 Jul 2023 11:01:54 -0700 (PDT) Received: from resomta-a1p-076786.sys.comcast.net ([96.103.145.235]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 256/256 bits) (Client did not present a certificate) by resqmta-a1p-077723.sys.comcast.net with ESMTP id M6wkqkn2jHilbMBSMqc5jG; Wed, 19 Jul 2023 17:59:22 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=comcastmailservice.net; s=20211018a; t=1689789562; bh=/6lKYap9PZZRLrRmess6iU23U+m+a8OOtwMIqKZ8RIU=; h=Received:Received:From:To:Subject:Date:MIME-Version:Message-ID: Content-Type:Xfinity-Spam-Result; b=VcFEsTlS20BqPr681CCCNRDmpZF0XE0c2jsps2LTPbxdVDQRqPf0okAEeYqEhlqxN xp+3uoJEGCU+zC7GZkgZepLimVtp39sNQWbTt1UrV/OD1BR3wEWhfG0P+C3cdtKFLM LsCZSQROEyDbgA4ILeQ3QctKhL4sKi1faNS5cO9rb9UOhWNjJLRpGRTnLlZMNRLGcP 1qdkoyGtMPGAL5FTAfS2cZITQo0KsabCrRopFgH4YHANauoEVrezgdA/LyCZ96KHL2 7EQpWKwrLQUxOxD9eEczAS07louswlIQzli2YjutUK2qVQtsO6j5tlwDsPHGpc82Hp LbKd36X1Bxd9g== Received: from localhost ([IPv6:2601:18c:9082:afd:219:d1ff:fe75:dc2f]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 256/256 bits) (Client did not present a certificate) by resomta-a1p-076786.sys.comcast.net with ESMTPSA id MBSEqFdsmeadOMBSEqzqUD; Wed, 19 Jul 2023 17:59:18 +0000 X-Xfinity-VMeta: sc=-100.00;st=legit From: Matt Whitlock To: Miklos Szeredi Cc: David Howells , , Matthew Wilcox , Dave Chinner , Linus Torvalds , Jens Axboe , , , , Christoph Hellwig , Subject: Re: [RFC PATCH 1/4] splice: Fix corruption of spliced data after =?iso-8859-1?Q?splice()_returns?= Date: Wed, 19 Jul 2023 13:59:13 -0400 MIME-Version: 1.0 Message-ID: In-Reply-To: References: <20230629155433.4170837-1-dhowells@redhat.com> <20230629155433.4170837-2-dhowells@redhat.com> User-Agent: Trojita/v0.7-595-g7738cd47; Qt/5.15.10; xcb; Linux; Gentoo Linux Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MIME_QP_LONG_LINE,RCVD_IN_DNSWL_BLOCKED,SPF_HELO_PASS, SPF_PASS,T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wednesday, 19 July 2023 06:17:51 EDT, Miklos Szeredi wrote: > On Thu, 29 Jun 2023 at 17:56, David Howells wrote: >>=20 >> Splicing data from, say, a file into a pipe currently leaves the source >> pages in the pipe after splice() returns - but this means that those pages= >> can be subsequently modified by shared-writable mmap(), write(), >> fallocate(), etc. before they're consumed. > > What is this trying to fix? The above behavior is well known, so > it's not likely to be a problem. Respectfully, it's not well-known, as it's not documented. If the splice(2)=20= man page had mentioned that pages can be mutated after they're already=20 ostensibly at rest in the output pipe buffer, then my nightly backups=20 wouldn't have been incurring corruption silently for many months.