OSDN Git Service

netfs: Refactor arguments for netfs_alloc_read_request
authorDavid Howells <dhowells@redhat.com>
Thu, 26 Aug 2021 13:24:42 +0000 (09:24 -0400)
committerDavid Howells <dhowells@redhat.com>
Fri, 18 Mar 2022 09:24:00 +0000 (09:24 +0000)
commit663dfb65c3b3ea4b8e1944680352992d58f3aa22
tree8a1b195eabea22f85dc59a42e8b700bd6c4efc65
parent5c88705e2aeaee5521b8586e68bef47aab359914
netfs: Refactor arguments for netfs_alloc_read_request

Pass start and len to the rreq allocator. This should ensure that the
fields are set so that ->init_request() can use them.

Also add a parameter to indicates the origin of the request.  Ceph can use
this to tell whether to get caps.

Changes
=======
ver #3)
 - Change the author to me as Jeff feels that most of the patch is my
   changes now.

ver #2)
 - Show the request origin in the netfs_rreq tracepoint.

Signed-off-by: Jeff Layton <jlayton@kernel.org>
Co-developed-by: David Howells <dhowells@redhat.com>
Signed-off-by: David Howells <dhowells@redhat.com>
cc: linux-cachefs@redhat.com

Link: https://lore.kernel.org/r/164622989020.3564931.17517006047854958747.stgit@warthog.procyon.org.uk/
Link: https://lore.kernel.org/r/164678208569.1200972.12153682697842916557.stgit@warthog.procyon.org.uk/
Link: https://lore.kernel.org/r/164692904155.2099075.14717645623034355995.stgit@warthog.procyon.org.uk/
fs/netfs/internal.h
fs/netfs/objects.c
fs/netfs/read_helper.c
include/linux/netfs.h
include/trace/events/netfs.h