RDMA/cm: Use DLID from inbound/outbound PathRecords as the datapath DLID
authorMark Zhang <markzhang@nvidia.com>
Thu, 8 Sep 2022 10:09:03 +0000 (13:09 +0300)
committerLeon Romanovsky <leon@kernel.org>
Thu, 22 Sep 2022 09:35:31 +0000 (12:35 +0300)
commiteb8336dbe373edd1ad6061c543e4ba6ea60f6cc9
treef4049acda44c00546abdaba60b82f7e26a7650ab
parentb7d95040c13f61a4a6a859c5355faf583eff9658
RDMA/cm: Use DLID from inbound/outbound PathRecords as the datapath DLID

In inter-subnet cases, when inbound/outbound PRs are available,
outbound_PR.dlid is used as the requestor's datapath DLID and
inbound_PR.dlid is used as the responder's DLID. The inbound_PR.dlid
is passed to responder side with the "ConnectReq.Primary_Local_Port_LID"
field. With this solution the PERMISSIVE_LID is no longer used in
Primary Local LID field.

Signed-off-by: Mark Zhang <markzhang@nvidia.com>
Reviewed-by: Mark Bloch <mbloch@nvidia.com>
Link: https://lore.kernel.org/r/b3f6cac685bce9dde37c610be82e2c19d9e51d9e.1662631201.git.leonro@nvidia.com
Signed-off-by: Leon Romanovsky <leon@kernel.org>
drivers/infiniband/core/cm.c
drivers/infiniband/core/cma.c
include/rdma/ib_cm.h