diff options
author | Sean Hefty <sean.hefty@intel.com> | 2013-05-29 10:09:24 -0700 |
---|---|---|
committer | Roland Dreier <roland@purestorage.com> | 2013-06-20 23:35:38 -0700 |
commit | 94d0c939416480066d4e4d69e0d3c217bc083cea (patch) | |
tree | 2ae7d0b64d01c69778fa8dca4f0c851d55784393 /drivers/infiniband | |
parent | 5c438135adf90b33cb00e5351becf1e557bbdd9d (diff) | |
download | op-kernel-dev-94d0c939416480066d4e4d69e0d3c217bc083cea.zip op-kernel-dev-94d0c939416480066d4e4d69e0d3c217bc083cea.tar.gz |
RDMA/cma: Only listen on IB devices when using AF_IB
If an rdma_cm_id is bound to AF_IB, with a wild card address, only
listen on IB devices.
Signed-off-by: Sean Hefty <sean.hefty@intel.com>
Signed-off-by: Roland Dreier <roland@purestorage.com>
Diffstat (limited to 'drivers/infiniband')
-rw-r--r-- | drivers/infiniband/core/cma.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/infiniband/core/cma.c b/drivers/infiniband/core/cma.c index 96d0b9a..6a0ee92 100644 --- a/drivers/infiniband/core/cma.c +++ b/drivers/infiniband/core/cma.c @@ -1616,6 +1616,10 @@ static void cma_listen_on_dev(struct rdma_id_private *id_priv, struct rdma_cm_id *id; int ret; + if (cma_family(id_priv) == AF_IB && + rdma_node_get_transport(cma_dev->device->node_type) != RDMA_TRANSPORT_IB) + return; + id = rdma_create_id(cma_listen_handler, id_priv, id_priv->id.ps, id_priv->id.qp_type); if (IS_ERR(id)) |