public inbox for linux-rdma@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] RDMA/ucma: Copy iWARP route information.
@ 2010-05-10 15:46 Steve Wise
       [not found] ` <20100510154656.22415.47740.stgit-T4OLL4TyM9aNDNWfRnPdfg@public.gmane.org>
  0 siblings, 1 reply; 17+ messages in thread
From: Steve Wise @ 2010-05-10 15:46 UTC (permalink / raw)
  To: linux-rdma-u79uwXL29TY76Z2rM5mHXA

For iWARP rdma_cm ids, the "route" information is the L2 src and
next hop addresses.

Signed-off-by: Steve Wise <swise-7bPotxP6k4+P2YhJcF5u+vpXobYPEAuW@public.gmane.org>
---

 drivers/infiniband/core/ucma.c |   13 +++++++++++++
 1 files changed, 13 insertions(+), 0 deletions(-)

diff --git a/drivers/infiniband/core/ucma.c b/drivers/infiniband/core/ucma.c
index ac7edc2..0498383 100644
--- a/drivers/infiniband/core/ucma.c
+++ b/drivers/infiniband/core/ucma.c
@@ -583,6 +583,16 @@ static void ucma_copy_ib_route(struct rdma_ucm_query_route_resp *resp,
 	}
 }
 
+static void ucma_copy_iw_route(struct rdma_ucm_query_route_resp *resp,
+			       struct rdma_route *route)
+{
+	struct rdma_dev_addr *dev_addr;
+
+	dev_addr = &route->addr.dev_addr;
+	rdma_addr_get_dgid(dev_addr, (union ib_gid *) &resp->ib_route[0].dgid);
+	rdma_addr_get_sgid(dev_addr, (union ib_gid *) &resp->ib_route[0].sgid);
+}
+
 static ssize_t ucma_query_route(struct ucma_file *file,
 				const char __user *inbuf,
 				int in_len, int out_len)
@@ -621,6 +631,9 @@ static ssize_t ucma_query_route(struct ucma_file *file,
 	case RDMA_TRANSPORT_IB:
 		ucma_copy_ib_route(&resp, &ctx->cm_id->route);
 		break;
+	case RDMA_TRANSPORT_IWARP:
+		ucma_copy_iw_route(&resp, &ctx->cm_id->route);
+		break;
 	default:
 		break;
 	}

--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply related	[flat|nested] 17+ messages in thread

end of thread, other threads:[~2011-01-18 23:16 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-05-10 15:46 [PATCH] RDMA/ucma: Copy iWARP route information Steve Wise
     [not found] ` <20100510154656.22415.47740.stgit-T4OLL4TyM9aNDNWfRnPdfg@public.gmane.org>
2010-05-10 17:36   ` Sean Hefty
     [not found]     ` <1C56604F650B44A8B00B3CA55D00B95D-Zpru7NauK7drdx17CPfAsdBPR1lH4CV8@public.gmane.org>
2010-05-11 20:28       ` Sean Hefty
     [not found]         ` <B28805226A0F4AD7B53BD430925D3D20-Zpru7NauK7drdx17CPfAsdBPR1lH4CV8@public.gmane.org>
2010-05-11 20:38           ` Steve Wise
     [not found]             ` <4BE9C04E.4040907-7bPotxP6k4+P2YhJcF5u+vpXobYPEAuW@public.gmane.org>
2010-05-11 21:22               ` Sean Hefty
     [not found]                 ` <23BD55BBBEC444B18E7B48D98CC1EBA5-Zpru7NauK7drdx17CPfAsdBPR1lH4CV8@public.gmane.org>
2010-05-12 19:33                   ` Steve Wise
     [not found]                     ` <4BEB027B.5060500-7bPotxP6k4+P2YhJcF5u+vpXobYPEAuW@public.gmane.org>
2010-05-12 21:52                       ` Sean Hefty
     [not found]                         ` <5A102C804D4348A5BCE504F433888BED-Zpru7NauK7drdx17CPfAsdBPR1lH4CV8@public.gmane.org>
2010-05-12 22:03                           ` Steve Wise
2010-05-19 21:58   ` Steve Wise
     [not found]     ` <4BF45F1A.4010707-7bPotxP6k4+P2YhJcF5u+vpXobYPEAuW@public.gmane.org>
2010-05-19 22:03       ` Roland Dreier
     [not found]         ` <adaeih7eegq.fsf-BjVyx320WGW9gfZ95n9DRSW4+XlvGpQz@public.gmane.org>
2010-05-19 22:09           ` Steve Wise
     [not found]             ` <4BF4618C.1090106-7bPotxP6k4+P2YhJcF5u+vpXobYPEAuW@public.gmane.org>
2011-01-11 21:48               ` Steve Wise
     [not found]                 ` <4D2CD02C.1000607-7bPotxP6k4+P2YhJcF5u+vpXobYPEAuW@public.gmane.org>
2011-01-12 18:32                   ` Roland Dreier
     [not found]                     ` <ada1v4i55wv.fsf-FYB4Gu1CFyUAvxtiuMwx3w@public.gmane.org>
2011-01-12 18:38                       ` Steve Wise
2011-01-18 21:56                       ` Steve Wise
     [not found]                         ` <4D360C7B.30207-7bPotxP6k4+P2YhJcF5u+vpXobYPEAuW@public.gmane.org>
2011-01-18 23:14                           ` Hefty, Sean
     [not found]                             ` <CF9C39F99A89134C9CF9C4CCB68B8DDF25C1C997FD-osO9UTpF0USkrb+BlOpmy7fspsVTdybXVpNB7YpNyf8@public.gmane.org>
2011-01-18 23:16                               ` Steve Wise

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox