diff options
author | Steve Wise <swise@opengridcomputing.com> | 2019-02-01 12:44:27 -0800 |
---|---|---|
committer | Jason Gunthorpe <jgg@mellanox.com> | 2019-02-08 16:15:40 -0700 |
commit | 9491128f780e5be382a5b22990439d017f6dfc59 (patch) | |
tree | 38d325f517d7334e250645fd5077871b5496d732 | |
parent | 2c1619edef61a03cb516efaa81750784c3071d10 (diff) | |
download | blackbird-op-linux-9491128f780e5be382a5b22990439d017f6dfc59.tar.gz blackbird-op-linux-9491128f780e5be382a5b22990439d017f6dfc59.zip |
RDMA/cma: listening device cm_ids should inherit tos
If a user binds to INADDR_ANY and sets the service id, then the
device-specific cm_ids should also use this tos. This allows an app to
do:
rdma_bind_addr(INADDR_ANY)
set_service_type()
rdma_listen()
And connections setup via this listening endpoint will use the correct
tos.
Signed-off-by: Steve Wise <swise@opengridcomputing.com>
Reviewed-by: Parav Pandit <parav@mellanox.com>
Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
-rw-r--r-- | drivers/infiniband/core/cma.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/infiniband/core/cma.c b/drivers/infiniband/core/cma.c index 83aa2ad0c27e..e761ddd09aed 100644 --- a/drivers/infiniband/core/cma.c +++ b/drivers/infiniband/core/cma.c @@ -2466,6 +2466,8 @@ static void cma_listen_on_dev(struct rdma_id_private *id_priv, atomic_inc(&id_priv->refcount); dev_id_priv->internal_id = 1; dev_id_priv->afonly = id_priv->afonly; + dev_id_priv->tos_set = id_priv->tos_set; + dev_id_priv->tos = id_priv->tos; ret = rdma_listen(id, id_priv->backlog); if (ret) |