aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/infiniband/hw/mlx4/srq.c
diff options
context:
space:
mode:
authorSean Hefty <sean.hefty@intel.com>2011-05-23 16:31:36 -0700
committerRoland Dreier <roland@purestorage.com>2011-10-13 09:13:26 -0700
commit96104eda01695a26da2c8f7423ec0ba3509c8c97 (patch)
tree04e38bfe564245ebd9a62738d54a111b2d24da4a /drivers/infiniband/hw/mlx4/srq.c
parentRDMA/core: Add XRC domain support (diff)
downloadlinux-dev-96104eda01695a26da2c8f7423ec0ba3509c8c97.tar.xz
linux-dev-96104eda01695a26da2c8f7423ec0ba3509c8c97.zip
RDMA/core: Add SRQ type field
Currently, there is only a single ("basic") type of SRQ, but with XRC support we will add a second. Prepare for this by defining an SRQ type and setting all current users to IB_SRQT_BASIC. Signed-off-by: Sean Hefty <sean.hefty@intel.com> Signed-off-by: Roland Dreier <roland@purestorage.com>
Diffstat (limited to 'drivers/infiniband/hw/mlx4/srq.c')
-rw-r--r--drivers/infiniband/hw/mlx4/srq.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/infiniband/hw/mlx4/srq.c b/drivers/infiniband/hw/mlx4/srq.c
index 818b7ecace5e..4f7f7600d27c 100644
--- a/drivers/infiniband/hw/mlx4/srq.c
+++ b/drivers/infiniband/hw/mlx4/srq.c
@@ -81,6 +81,9 @@ struct ib_srq *mlx4_ib_create_srq(struct ib_pd *pd,
int err;
int i;
+ if (init_attr->srq_type != IB_SRQT_BASIC)
+ return ERR_PTR(-ENOSYS);
+
/* Sanity check SRQ size before proceeding */
if (init_attr->attr.max_wr >= dev->dev->caps.max_srq_wqes ||
init_attr->attr.max_sge > dev->dev->caps.max_srq_sge)