diff options
author | Bart Van Assche <bart.vanassche@sandisk.com> | 2016-07-21 13:03:30 -0700 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2016-08-20 18:11:02 +0200 |
commit | 84c9756c8bf7b7130b506679e7a2509a64fb758a (patch) | |
tree | 97c0e27e754daebc328ac1db2c07f1ff0f556c54 /include | |
parent | 1406586821b660baba40ba98881e9ce7d932b409 (diff) | |
download | lwn-84c9756c8bf7b7130b506679e7a2509a64fb758a.tar.gz lwn-84c9756c8bf7b7130b506679e7a2509a64fb758a.zip |
IB/core, RDMA RW API: Do not exceed QP SGE send limit
commit 632bc3f65081dd1e2e5394a9161580a0f78e8839 upstream.
Compute the SGE limit for RDMA READ and WRITE requests in
ib_create_qp(). Use that limit in the RDMA RW API implementation.
Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com>
Cc: Christoph Hellwig <hch@lst.de>
Cc: Sagi Grimberg <sagi@grimberg.me>
Cc: Steve Wise <swise@opengridcomputing.com>
Cc: Parav Pandit <pandit.parav@gmail.com>
Cc: Nicholas Bellinger <nab@linux-iscsi.org>
Cc: Laurence Oberman <loberman@redhat.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Doug Ledford <dledford@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'include')
-rw-r--r-- | include/rdma/ib_verbs.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/include/rdma/ib_verbs.h b/include/rdma/ib_verbs.h index 7e440d41487a..e694f02d42e3 100644 --- a/include/rdma/ib_verbs.h +++ b/include/rdma/ib_verbs.h @@ -1428,6 +1428,10 @@ struct ib_srq { } ext; }; +/* + * @max_write_sge: Maximum SGE elements per RDMA WRITE request. + * @max_read_sge: Maximum SGE elements per RDMA READ request. + */ struct ib_qp { struct ib_device *device; struct ib_pd *pd; @@ -1449,6 +1453,8 @@ struct ib_qp { void (*event_handler)(struct ib_event *, void *); void *qp_context; u32 qp_num; + u32 max_write_sge; + u32 max_read_sge; enum ib_qp_type qp_type; }; |