diff options
author | David Howells <dhowells@redhat.com> | 2022-02-17 13:30:38 +0000 |
---|---|---|
committer | David Howells <dhowells@redhat.com> | 2022-03-18 09:24:00 +0000 |
commit | 3a4a38e66d2443ab3c27a689c62a6937b854010e (patch) | |
tree | 8593f3f30de17a1d2ac4f89fd33c0f7e732506a2 /fs/netfs/internal.h | |
parent | f18a378580a761c8559b7d90afaa157269559c05 (diff) | |
download | linux-3a4a38e66d2443ab3c27a689c62a6937b854010e.tar.gz |
netfs: Split netfs_io_* object handling out
Split netfs_io_* object handling out into a file that's going to contain
object allocation, get and put routines.
Signed-off-by: David Howells <dhowells@redhat.com>
Reviewed-by: Jeff Layton <jlayton@redhat.com>
cc: linux-cachefs@redhat.com
Link: https://lore.kernel.org/r/164622995118.3564931.6089530629052064470.stgit@warthog.procyon.org.uk/ # v1
Link: https://lore.kernel.org/r/164678197044.1200972.11511937252083343775.stgit@warthog.procyon.org.uk/ # v2
Link: https://lore.kernel.org/r/164692894693.2099075.7831091294248735173.stgit@warthog.procyon.org.uk/ # v3
Diffstat (limited to 'fs/netfs/internal.h')
-rw-r--r-- | fs/netfs/internal.h | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/fs/netfs/internal.h b/fs/netfs/internal.h index b7f2c4459f33..cf7a3ddb16a4 100644 --- a/fs/netfs/internal.h +++ b/fs/netfs/internal.h @@ -5,6 +5,9 @@ * Written by David Howells (dhowells@redhat.com) */ +#include <linux/netfs.h> +#include <trace/events/netfs.h> + #ifdef pr_fmt #undef pr_fmt #endif @@ -12,10 +15,25 @@ #define pr_fmt(fmt) "netfs: " fmt /* + * objects.c + */ +struct netfs_io_request *netfs_alloc_request(const struct netfs_request_ops *ops, + void *netfs_priv, + struct file *file); +void netfs_get_request(struct netfs_io_request *rreq); +void netfs_clear_subrequests(struct netfs_io_request *rreq, bool was_async); +void netfs_put_request(struct netfs_io_request *rreq, bool was_async); +struct netfs_io_subrequest *netfs_alloc_subrequest(struct netfs_io_request *rreq); +void netfs_put_subrequest(struct netfs_io_subrequest *subreq, bool was_async); +void netfs_get_subrequest(struct netfs_io_subrequest *subreq); + +/* * read_helper.c */ extern unsigned int netfs_debug; +void netfs_rreq_work(struct work_struct *work); + /* * stats.c */ |