]> git.baikalelectronics.ru Git - kernel.git/commit
IB/cma: Allow port reuse for rdma_id
authorMoni Shoua <monis@mellanox.com>
Thu, 5 Jan 2017 14:16:36 +0000 (16:16 +0200)
committerDoug Ledford <dledford@redhat.com>
Tue, 24 Jan 2017 21:20:37 +0000 (16:20 -0500)
commitd4a1ddcdc56d9946910e4beaf641d6f076d7f087
tree604eeaf270cf8764728a5f23c8848bc6a5835ded
parent8eeb1c7a1e3404a31a0765df065bbdcf9af752e9
IB/cma: Allow port reuse for rdma_id

When allocating a port number for binding to a rdma_id, assuming the
allocation is not for a specific port, the rule is to allow only ports
that were not in use before by any other rdma_id.

This condition is too strong to achieve the goal of a unique 5 tuple
rdma_id. Instead, we can compare current rdma_id with other rdma_id for
difference in one of destination port, source address and destination
address to allow port reuse.

Signed-off-by: Moni Shoua <monis@mellanox.com>
Signed-off-by: Leon Romanovsky <leon@kernel.org>
Acked-by: Sean Hefty <sean.hefty@intel.com>
Signed-off-by: Doug Ledford <dledford@redhat.com>
drivers/infiniband/core/cma.c