[openib-general] Re: [PATCH 1/3] iWARP Header Files

Tom Tucker tom at opengridcomputing.com
Wed Mar 15 17:09:10 PST 2006


On Wed, 2006-03-15 at 16:17 -0800, Sean Hefty wrote:
> Tom Tucker wrote:
> > The iw_event_handler is registered with the provider by the IW CM. The
> > iw_cm_handler is registerd with the IW CM by the client. So when the
> > provider generates an event, it is delivered to the event_handler. When
> > the IW CM generates an event, it is delivered to the cm_handler. I guess
> > the comments aren't particularly helpful. 
> 
> The comments make more sense now.  I need to understand how one of the callbacks 
> can make use of a returned int, while the other is a void.
> 
> > The provider_id is the 'cookie' generated by the provider that uniquely
> > identifies this connection and is passed down to the HW by the provider.
> > The client doesn't use it. BTW, the alternative here is to have a
> > create_cm_id and destroy_cm_id call in the provider. I opted for the
> > 'cookie'.
> 
> None of the other core code makes use of a cookie that I'm aware of, so it's 
> worth nothing that there's inconsistency with the rest of the stack.  I'm not as 
> concerned about that as making sure that destruction is handled properly, since 
> there's not a destroy call in the provider.
> 
> > Maybe the provider_id and the event_handler should probably be in
> > private portion of the data structure.
> 
> That would provide for clearer encapsulation.
> 
BTW, the reason why I put these fields are in the public portion is
because although these fields are not used by the client, they are used
by the provider....this is different than IB, where the private portion
of the structure is known only to the IB CM...AFAIK anyway.


> - Sean




More information about the general mailing list