[openib-general] Re: Running libibcm/example/simple.c

Libor Michalek libor at topspin.com
Tue May 17 14:18:57 PDT 2005


On Tue, May 17, 2005 at 04:48:25PM -0400, Hal Rosenstock wrote:
> On Tue, 2005-05-17 at 16:44, Libor Michalek wrote:
> > On Mon, May 16, 2005 at 12:58:05PM -0400, Hal Rosenstock wrote:
> > > Hi again Libor,
> > > 
> > > When I run the example I get the following:
> > > server:
> > > CM ID <3> Event <1> State <3>
> > > client:
> > > CM ID <2> Event <0> State <0>
> > > server:
> > > CM ID <3> Event <2> State <0>
> 
> >  If you run the
> > client without a server running do you get the following:
> > 
> >   CM ID <2> Event <11> State <0>
> 
> (When I ran the server also), I ran it server/client on same machine.

  That is what's exposing the problem. Since the test is using a fake QPN,
a check in the kernel CM see's it as a collision. This patch fixes the issue.

-Libor

Index: examples/simple.c
===================================================================
--- examples/simple.c	(revision 2370)
+++ examples/simple.c	(working copy)
@@ -183,7 +183,7 @@ int main(int argc, char **argv)
 			
 			cm_id = event->cm_id;
 
-			rep.qp_num       = event->param.req_rcvd.remote_qpn;
+			rep.qp_num = event->param.req_rcvd.remote_qpn + 1;
 			rep.starting_psn = event->param.req_rcvd.starting_psn;
 
 			rep.private_data        = NULL;




More information about the general mailing list