[openib-general] opensm RFC: access switch object via node

Sasha Khapyorsky sashak at voltaire.com
Mon Nov 27 04:21:16 PST 2006


On 13:40 Mon 27 Nov     , Eitan Zahavi wrote:
> Looks like a good idea to me.

Glad to hear this.

> I propose adding this rule to osm_drop_mgr.c too so cases where this 
> rule breaks are caught.

Do you mean (node->sw == NULL) checks? If so, I agree - good idea.

Sasha

> 
> Thanks
> 
> EZ
> Sasha Khapyorsky wrote:
> >Hi,
> >
> >I noticed that in most of cases when switch object lookup is performed
> >in OpenSM it is done by searching sw_guid_tbl map by switch node's
> >GUID value.
> >
> >For me it looks better and simpler just to keep pointer to switch object
> >as member of its node structure. So for switch nodes such pointer will
> >point to node's valid switch object and for other nodes this will be
> >initialized as NULL.
> >
> >Then instead of sw_guid_tbl map searching we will have switch object
> >pointer directly available from the node structure (and sw_guid_tbl map
> >can be replaced by "cheaper" linked list).
> >
> >Other positive "side effect" is nice way (one more) to detect
> >switch/non-switch node type just as (node->sw != NULL).
> >
> >Any comments?
> >
> >If no real objections I can prepare patches.
> >
> >Sasha
> >
> >_______________________________________________
> >openib-general mailing list
> >openib-general at openib.org
> >http://openib.org/mailman/listinfo/openib-general
> >
> >To unsubscribe, please visit 
> >http://openib.org/mailman/listinfo/openib-general
> >  
> 




More information about the general mailing list