diff options
author | David Howells <dhowells@redhat.com> | 2022-02-25 12:27:53 +0000 |
---|---|---|
committer | David Howells <dhowells@redhat.com> | 2023-12-28 09:45:20 +0000 |
commit | c6dc54dd91bbf597942b4975b8adec660a16827d (patch) | |
tree | 7598ebd72cc38c43a53970cb148d5e5f5037721c /include/linux/netfs.h | |
parent | 16af134ca4b7051b1587108f2066ec90ae029f74 (diff) |
netfs: Add a hook to allow tell the netfs to update its 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>
Reviewed-by: Jeff Layton <jlayton@kernel.org>
cc: linux-cachefs@redhat.com
cc: linux-fsdevel@vger.kernel.org
cc: linux-mm@kvack.org
Diffstat (limited to 'include/linux/netfs.h')
-rw-r--r-- | include/linux/netfs.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/include/linux/netfs.h b/include/linux/netfs.h index f302123a3e38..3fc41f616621 100644 --- a/include/linux/netfs.h +++ b/include/linux/netfs.h @@ -242,6 +242,7 @@ struct netfs_request_ops { void (*free_request)(struct netfs_io_request *rreq); void (*free_subrequest)(struct netfs_io_subrequest *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); @@ -249,6 +250,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); }; /* |