Skip to content

Commit

Permalink
RDMA/ocrdma: populate max_sge_rd in device attributes
Browse files Browse the repository at this point in the history
max_sge_rd is used by some of the ULPs to calculate the maximum
number of SGEs that can be used for RDMA READ. Populating this
value in the response of query_device verb. Also, avoid checking
the max_srq_sge while populating max_sge.

Signed-off-by: Selvin Xavier <[email protected]>
Signed-off-by: Doug Ledford <[email protected]>
  • Loading branch information
selvintxavier authored and dledford committed Feb 5, 2016
1 parent fd98d89 commit 7d82df1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/infiniband/hw/ocrdma/ocrdma_verbs.c
Original file line number Diff line number Diff line change
Expand Up @@ -125,8 +125,8 @@ int ocrdma_query_device(struct ib_device *ibdev, struct ib_device_attr *attr,
IB_DEVICE_SYS_IMAGE_GUID |
IB_DEVICE_LOCAL_DMA_LKEY |
IB_DEVICE_MEM_MGT_EXTENSIONS;
attr->max_sge = min(dev->attr.max_send_sge, dev->attr.max_srq_sge);
attr->max_sge_rd = 0;
attr->max_sge = dev->attr.max_send_sge;
attr->max_sge_rd = attr->max_sge;
attr->max_cq = dev->attr.max_cq;
attr->max_cqe = dev->attr.max_cqe;
attr->max_mr = dev->attr.max_mr;
Expand Down

0 comments on commit 7d82df1

Please sign in to comment.