]> git.apps.os.sepia.ceph.com Git - ceph-client.git/commit
libceph: allow ceph_osdc_new_request to accept a multi-op read
authorJeff Layton <jlayton@kernel.org>
Thu, 25 Aug 2022 13:31:16 +0000 (09:31 -0400)
committerXiubo Li <xiubli@redhat.com>
Fri, 26 Aug 2022 23:58:55 +0000 (07:58 +0800)
commit467d376b811184edc72d23ea0aba35f99c8f369f
tree368a08bd8ab63ca573db7fa81812a6d8f1512626
parentcd00450cd57c8b391597c6f14f65d20d28d329c4
libceph: allow ceph_osdc_new_request to accept a multi-op read

Currently we have some special-casing for multi-op writes, but in the
case of a read, we can't really handle it. All of the current multi-op
callers call it with CEPH_OSD_FLAG_WRITE set.

Have ceph_osdc_new_request check for CEPH_OSD_FLAG_READ and if it's set,
allocate multiple reply ops instead of multiple request ops. If neither
flag is set, return -EINVAL.

Reviewed-by: Xiubo Li <xiubli@redhat.com>
Signed-off-by: Jeff Layton <jlayton@kernel.org>
net/ceph/osd_client.c