summaryrefslogtreecommitdiff
path: root/include/linux/ceph
diff options
context:
space:
mode:
authorJeff Layton <jlayton@kernel.org>2022-03-24 20:33:06 +0300
committerIlya Dryomov <idryomov@gmail.com>2023-08-22 10:01:47 +0300
commitd396f89db39a2f259e2125ca43b4c31bb65afcad (patch)
tree0d08948fb59fc31c1514b25befb40df722dfbfb3 /include/linux/ceph
parentf36217e35ce13fe284fe9481711614200badebb0 (diff)
downloadlinux-d396f89db39a2f259e2125ca43b4c31bb65afcad.tar.xz
libceph: add sparse read support to msgr1
Add 2 new fields to ceph_connection_v1_info to track the necessary info in sparse reads. Skip initializing the cursor for a sparse read. Break out read_partial_message_section into a wrapper around a new read_partial_message_chunk function that doesn't zero out the crc first. Add new helper functions to drive receiving into the destinations provided by the sparse_read state machine. Signed-off-by: Jeff Layton <jlayton@kernel.org> Reviewed-by: Xiubo Li <xiubli@redhat.com> Reviewed-and-tested-by: Luís Henriques <lhenriques@suse.de> Reviewed-by: Milind Changire <mchangir@redhat.com> Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
Diffstat (limited to 'include/linux/ceph')
-rw-r--r--include/linux/ceph/messenger.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/include/linux/ceph/messenger.h b/include/linux/ceph/messenger.h
index 8a6938fa324e..9fd7255172ad 100644
--- a/include/linux/ceph/messenger.h
+++ b/include/linux/ceph/messenger.h
@@ -336,6 +336,10 @@ struct ceph_connection_v1_info {
int in_base_pos; /* bytes read */
+ /* sparse reads */
+ struct kvec in_sr_kvec; /* current location to receive into */
+ u64 in_sr_len; /* amount of data in this extent */
+
/* message in temps */
u8 in_tag; /* protocol control byte */
struct ceph_msg_header in_hdr;