Received: by 2002:a05:6358:9144:b0:117:f937:c515 with SMTP id r4csp1446618rwr; Thu, 20 Apr 2023 15:28:58 -0700 (PDT) X-Google-Smtp-Source: AKy350Y9LQGm0UL5iWN+RqF/rk8LkuO+/8Mi9GJT8f9agyQt/UoVrTJl0U37YjmSVnRkUM4yn72v X-Received: by 2002:a05:6a20:7d89:b0:ef:e0af:120a with SMTP id v9-20020a056a207d8900b000efe0af120amr4354903pzj.22.1682029738263; Thu, 20 Apr 2023 15:28:58 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1682029738; cv=none; d=google.com; s=arc-20160816; b=a3y2WWZeuimJohFZz01uxtHbpaXsnxh7ZGEpuc9EFQ2YcdBA1V2TQB7HvCBr5QWNJI yolh8dTf5zTpguEGi0P1PSvlGb+wxgy98AHkf9DdQQqbfYsnGnbFZEeCPPxg5wR6klWa wzfu4yNkJcYOtCoVQyaiAtrXcLS731QFA5RbnPBNFcl9D0aQl/QrMaZOwmkA/tgoX7qV 72pe8u8e1/0YO8KxQOFYjHR+Vop3uIwWUIjnotSS6eLefm+iqBhxDRVlcIF+uULVSYKm +UGJSK77IBECGQ0K44yOfI8Qep6ZdPLKnKxVsurM3+O4IiKTuGucP6YslngqZ2UUbQW4 /lKw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=Xah23523mqBQohWHxtgP96LS5q9in7j2/iSJEIHA+i4=; b=jIX/QAIu07AS1/iBK3+ohYd0auXS37uiLVA7MKy7/rGs+l6zwhVqaHoFOoW6nC0g6U 9Lyc5vq5fOKciDA3auvMvP4uIB03HaBAslPWArXYmqeokbpj4oBhlE/SZfulaHjhYox5 279xNoyHkhlRA+zu7m9VmkT9xRxQJx9HR4/sODRMV8S5WNIJ3w+uDGbS7KWoDmlmpgqM d12AxUtXW3I14u3B6rY5s8kVltDXcaIA8mia8ptkA89l3/QfcaELUi9tMpJ8uYBM7YhB gIKwPG62uAmROSFMQXtvhD0kg2UfZEQbcQuUm4qJnQoM0jg0q09BBzes08iqXvJJ9g0q Pqtg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linux.org.uk header.s=zeniv-20220401 header.b=uWQX2u7n; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=zeniv.linux.org.uk Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id z31-20020a630a5f000000b0051372ef848fsi2652675pgk.697.2023.04.20.15.28.44; Thu, 20 Apr 2023 15:28:58 -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=@linux.org.uk header.s=zeniv-20220401 header.b=uWQX2u7n; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=zeniv.linux.org.uk Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232992AbjDTWXD (ORCPT + 99 others); Thu, 20 Apr 2023 18:23:03 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46490 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232698AbjDTWW5 (ORCPT ); Thu, 20 Apr 2023 18:22:57 -0400 Received: from zeniv.linux.org.uk (zeniv.linux.org.uk [IPv6:2a03:a000:7:0:5054:ff:fe1c:15ff]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C5C5B4487; Thu, 20 Apr 2023 15:22:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=linux.org.uk; s=zeniv-20220401; h=Sender:In-Reply-To:Content-Type: MIME-Version:References:Message-ID:Subject:Cc:To:From:Date:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=Xah23523mqBQohWHxtgP96LS5q9in7j2/iSJEIHA+i4=; b=uWQX2u7nCtxAfooM1lBJbswwMe yrDts7jLwaUKxWtJ6KySS/gMr1q+DoMl298/FpmeMZG4cigTuZO5FA1JMQPe+7f9w5YdnDzljFdKo I1cKGoP5tNWRThp4wROEmTC8eeAtTatxsv+0x1ngADsoWMGo1705n8DrCZyQHFPTqFHajq1tOnI2C V8NHsW3Y7sjRuWVVDwsBrbp9Znx/xhLS84lHDoQDBcBldrLC9zC6Yyl164qI2zY/ilIRGIxUtd0CV nDYwXxea1x8FUCxsE6AxpwklMdoi9mi0J5KaxB5chppMC8CZDsViwzaQU+dPLjV8JTL7QREI+VJoo wppN3E/Q==; Received: from viro by zeniv.linux.org.uk with local (Exim 4.96 #2 (Red Hat Linux)) id 1ppcff-00Ayid-0P; Thu, 20 Apr 2023 22:22:31 +0000 Date: Thu, 20 Apr 2023 23:22:31 +0100 From: Al Viro To: David Howells Cc: Jens Axboe , Christoph Hellwig , Matthew Wilcox , Jan Kara , Jeff Layton , David Hildenbrand , Jason Gunthorpe , Logan Gunthorpe , Hillf Danton , Christian Brauner , Linus Torvalds , linux-fsdevel@vger.kernel.org, linux-block@vger.kernel.org, linux-kernel@vger.kernel.org, linux-mm@kvack.org, Christoph Hellwig , John Hubbard Subject: Re: [PATCH v18 09/15] iov_iter: Kill ITER_PIPE Message-ID: <20230420222231.GT3390869@ZenIV> References: <20230314220757.3827941-1-dhowells@redhat.com> <20230314220757.3827941-10-dhowells@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20230314220757.3827941-10-dhowells@redhat.com> Sender: Al Viro X-Spam-Status: No, score=-4.3 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_EF,RCVD_IN_DNSWL_MED,SPF_HELO_NONE,SPF_NONE, T_SCC_BODY_TEXT_LINE autolearn=ham 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 Tue, Mar 14, 2023 at 10:07:51PM +0000, David Howells wrote: > The ITER_PIPE-type iterator was only used for generic_file_splice_read(), > but that has now been switched to either pull pages directly from the > pagecache for buffered file splice-reads or to use ITER_BVEC instead for > O_DIRECT file splice-reads. This leaves ITER_PIPE unused - so remove it. Wonderful, except that now you've got duplicates of ->read_iter() for everyone who wants zero-copy on ->splice_read() ;-/ I understand the attraction of arbitrary seeks on those suckers; ITER_PIPE is a massive headache in that respect. But I really don't like what your approach trades it for. And you are nowhere near done - consider e.g. NFS. Mainline has it feed ITER_PIPE to nfs_file_read(), which does call generic_file_read_iter() - after result = nfs_revalidate_mapping(inode, iocb->ki_filp->f_mapping); Sure, you can add nfs_file_splice_read() that would do what nfs_file_read() does, calling filemap_spice_read() instead of generic_file_read_iter(). Repeat the same for ocfs2 (locking of its own). And orangefs. And XFS (locking, again). And your own AFS, while we are at it. Et sodding cetera - *everything* that uses generic_file_splice_read() with ->read_iter other than generic_file_read_iter() needs review and, quite likely, a ->splice_read() instance of its own.