Message ID | 20231117211544.1740466-17-dhowells@redhat.com (mailing list archive) |
---|---|
State | New |
Headers | show
Return-Path: <owner-linux-mm@kvack.org> X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 9ECABC5AD4C for <linux-mm@archiver.kernel.org>; Fri, 17 Nov 2023 21:16:48 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 2C5D48D001D; Fri, 17 Nov 2023 16:16:48 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 24BF38D001C; Fri, 17 Nov 2023 16:16:48 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 09F458D001D; Fri, 17 Nov 2023 16:16:48 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0012.hostedemail.com [216.40.44.12]) by kanga.kvack.org (Postfix) with ESMTP id E752C8D0012 for <linux-mm@kvack.org>; Fri, 17 Nov 2023 16:16:47 -0500 (EST) Received: from smtpin03.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay10.hostedemail.com (Postfix) with ESMTP id BFE2AC0D05 for <linux-mm@kvack.org>; Fri, 17 Nov 2023 21:16:47 +0000 (UTC) X-FDA: 81468705654.03.2B8EFEF Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by imf29.hostedemail.com (Postfix) with ESMTP id 1D139120025 for <linux-mm@kvack.org>; Fri, 17 Nov 2023 21:16:45 +0000 (UTC) Authentication-Results: imf29.hostedemail.com; dkim=pass header.d=redhat.com header.s=mimecast20190719 header.b=cQgrw5Cc; dmarc=pass (policy=none) header.from=redhat.com; spf=pass (imf29.hostedemail.com: domain of dhowells@redhat.com designates 170.10.129.124 as permitted sender) smtp.mailfrom=dhowells@redhat.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1700255806; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=/h/RtPpFFvVcBRZ5JrGbnLPxoOOyaaScpnNAYMwDAl8=; b=YTXjILjbvhE+swfu6/WS9wR/7IvP7J8yorR1Xkc1PJrn/+xSbEnmd0WuR/fVC/URaBvyqc U3Q4xBHGGXDpfzwSJdkjtd2NDEW/6SjHmOrY9QsX8/+n8TUn9/IiPQrigtPhwLMwP/5YG5 ilAixCuULd93qFS0oftsSjmuCzdpk7g= ARC-Authentication-Results: i=1; imf29.hostedemail.com; dkim=pass header.d=redhat.com header.s=mimecast20190719 header.b=cQgrw5Cc; dmarc=pass (policy=none) header.from=redhat.com; spf=pass (imf29.hostedemail.com: domain of dhowells@redhat.com designates 170.10.129.124 as permitted sender) smtp.mailfrom=dhowells@redhat.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1700255806; a=rsa-sha256; cv=none; b=plJAjyDg1w6ly1G5I1K/8oRHCKdYRyZVerq/1v2yZJDafv7AJYisuQjxuKrCiJMtCLy/5e VdhUE4CVZJB/x53hLBAIloIPpKlFQzu+yX/m49gAV1vuRpD0NVJ93mFT0i6MgtaOG4x9dB oc01q5mZ7R6zI0lhqJmxiCt/J9UNBX8= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1700255805; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=/h/RtPpFFvVcBRZ5JrGbnLPxoOOyaaScpnNAYMwDAl8=; b=cQgrw5CckKRMClxf4CF95rcIgeHv7agMFSMxj4ByAsBk/6PPnyhYDi4ZjZnsUpQq1oNx5W zZk7yeLf0pS6W/1BBFJ6nB6ZJH6rMiT/FO3z1tE1DqgZdT9OG5wVy9Z1J6GAovbERr52oX wkf9lIGiw89AaDTVvb33Ckj1g4weM30= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-693-mgGBp15dO3CSvbe2TYPwvg-1; Fri, 17 Nov 2023 16:16:44 -0500 X-MC-Unique: mgGBp15dO3CSvbe2TYPwvg-1 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.rdu2.redhat.com [10.11.54.4]) (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 mimecast-mx02.redhat.com (Postfix) with ESMTPS id 2FB708527A9; Fri, 17 Nov 2023 21:16:43 +0000 (UTC) Received: from warthog.procyon.org.com (unknown [10.42.28.16]) by smtp.corp.redhat.com (Postfix) with ESMTP id 929962026D4C; Fri, 17 Nov 2023 21:16:40 +0000 (UTC) From: David Howells <dhowells@redhat.com> To: Jeff Layton <jlayton@kernel.org>, Steve French <smfrench@gmail.com> Cc: David Howells <dhowells@redhat.com>, Matthew Wilcox <willy@infradead.org>, Marc Dionne <marc.dionne@auristor.com>, Paulo Alcantara <pc@manguebit.com>, Shyam Prasad N <sprasad@microsoft.com>, Tom Talpey <tom@talpey.com>, Dominique Martinet <asmadeus@codewreck.org>, Ilya Dryomov <idryomov@gmail.com>, Christian Brauner <christian@brauner.io>, linux-cachefs@redhat.com, linux-afs@lists.infradead.org, linux-cifs@vger.kernel.org, linux-nfs@vger.kernel.org, ceph-devel@vger.kernel.org, v9fs@lists.linux.dev, linux-fsdevel@vger.kernel.org, linux-mm@kvack.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v2 16/51] netfs: Add a hook to allow tell the netfs to update its i_size Date: Fri, 17 Nov 2023 21:15:08 +0000 Message-ID: <20231117211544.1740466-17-dhowells@redhat.com> In-Reply-To: <20231117211544.1740466-1-dhowells@redhat.com> References: <20231117211544.1740466-1-dhowells@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Scanned-By: MIMEDefang 3.4.1 on 10.11.54.4 X-Rspam-User: X-Rspamd-Server: rspam12 X-Rspamd-Queue-Id: 1D139120025 X-Stat-Signature: mo7xunjmoyog9xq6cigoiezg1xkkqybz X-HE-Tag: 1700255805-621000 X-HE-Meta: U2FsdGVkX198KDOTuXuZPchfQZc52MpWOHhSxXNKin6z0SqfDevqDU0U3Bwe1jh4Gans0XxJvIl2B2zKkpQVU17/YjFRaNJUypMS+TfRqHo02yncOvmN/i3aCz1Ke5X5MxLpWlp9UrxXcEt0mE7JWAgYdYQp7iqxwcx23nsQgS+ldnHGCOOjY1MQvrS1ZwTKefBl2PKbpOlhENTH3ZvqpWvIiPOxJq5wLdWjFkPsMGea2+Z4CctW+0qnWb5uZDaGGboCBIgRmV+7vwRxiuUFbtOoTd3xCV41Ia1S1cRQ6Dl7bDrDHKE3WfA7ticRV1E+XlewM4828mB1Wc+dwYjbonOtWko11cZPd+kdbE8xRkmFAYgKUYrPI0i+2ydmzIFvZt0fiyH/bVwKW+jwLOZ0xvO3EJFD3c7kp72eHVv9KViHu6CVFKiJLBz15lB0q4FXXdMzsbI6m/ID7nEHQE8bL1fmMRIqbbASYMPqLji4yZS4r5cNdqPg/YimMsXxh64IzRt0GY+YxBpYmbkqEBYWFMev8i80OLUdqi/wsgi8t4HDd4q4sslhmlsu8ao39iUFRisJqp/iHj6MTixVz4QrnFKciiPYCaWRn/nk6+X4bIhc5balCsvS2v/qQm2L559JvhZuPSPwVPWn27h1kXl5jpa25s7RVgZv2q8q1EV9Cb4NiA7nB4ypaNllHlWUOdB37WKn/enJRl441yxZd8CJtX+NO9fL3VegBpHrmf4tV83oVZPttSPRB9ELBKfmm8V0IgAABYLkLxc6eCgggY08oZmf2pVsdnlMWi+JRGhEmnN0akfu91fklDwD4aMyJDherBrRQZBeDNGmW8J/JBIWkfhMqNqumTxG06QsrxAHmGUe1CIHWLYFCLnI5TewVO85KHT8bKS1TTvHVIrzbtzyWZfeAg7O3Gr9sMFuZWHo9n59DwMvaPwTLlpPhySz8OQqruaW3Osz5fvNLiGe7AL qaPuQ8ws rnb1A+RCFkLJzZGFsQAkEdnpMmdWPml6Upi2uPpbdgCHtn2XaGo4TPcD63hXpDeq6mnH8AFpmLqBlRukoyXezcYSRU7oSYpL+lbsrPDobuJAf+LK6ZJDPd2AhOfy95biNq6MKNWSP0KZaoQOUFNsl6taqi+wJ/LkC0jcw3P5WLdQd+IVVZ2mWKCChE1i/R6cnaaMyXEjm/fJ3wLBuPAw2RN+K/wQAOzdM7ppW1vvZTGd1Qv/cbF5CLdv32PnD/MsPwLow9rq/PrWWCqPdLHraOgIY8WVaHtI9hVCZh5oT5hMT2pJnG0B197VjhP3cBzJdGEdPq+uiPAP2Xh+LHWltr1k2NPbIxDimv1NSDyzkKsTtMSETSdTQdR0a4v4sEUne56Ie0wtwYi7b/TIF3e6FmSt1+Q== X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: <linux-mm.kvack.org> List-Subscribe: <mailto:majordomo@kvack.org> List-Unsubscribe: <mailto:majordomo@kvack.org> |
Series |
netfs, afs, cifs: Delegate high-level I/O to netfslib
|
expand
|
diff --git a/include/linux/netfs.h b/include/linux/netfs.h index 62b768260eda..21650db7da54 100644 --- a/include/linux/netfs.h +++ b/include/linux/netfs.h @@ -248,6 +248,7 @@ struct netfs_request_ops { void (*free_subrequest)(struct netfs_io_subrequest *rreq); int (*begin_cache_operation)(struct netfs_io_request *rreq); + /* Read request handling */ void (*expand_readahead)(struct netfs_io_request *rreq); bool (*clamp_length)(struct netfs_io_subrequest *subreq); void (*issue_read)(struct netfs_io_subrequest *subreq); @@ -255,6 +256,9 @@ struct netfs_request_ops { int (*check_write_begin)(struct file *file, loff_t pos, unsigned len, struct folio **foliop, void **_fsdata); void (*done)(struct netfs_io_request *rreq); + + /* Modification handling */ + void (*update_i_size)(struct inode *inode, loff_t i_size); }; /*
Add a hook for netfslib's write helpers to call to tell the network filesystem that it should update its i_size. Signed-off-by: David Howells <dhowells@redhat.com> cc: Jeff Layton <jlayton@kernel.org> cc: linux-cachefs@redhat.com cc: linux-fsdevel@vger.kernel.org cc: linux-mm@kvack.org --- include/linux/netfs.h | 4 ++++ 1 file changed, 4 insertions(+)