[openib-general] Incoorect cm_find_port result.

Libor Michalek libor at topspin.com
Wed Jan 26 12:49:21 PST 2005


Sean,

  There is an inconsistency between the port returned by cm_find_port()
and the port needed for ib_find_cached_pkey()

  cm_find_port() is using base 0 port numbering, while 
ib_find_cached_pkey() uses base 1 port numbering. If I make this change
ib_send_cm_req() appears to work correctly:

-Libor

Index: infiniband/core/cm.c
===================================================================
--- infiniband/core/cm.c	(revision 1664)
+++ infiniband/core/cm.c	(working copy)
@@ -215,7 +215,7 @@
 	if (ret)
 		port = NULL;
 	else
-		port = &port[p-1];
+		port = &port[p];
 
 	return port;
 }



More information about the general mailing list