[openib-general] opensm RFC: access switch object via node
Eitan Zahavi
eitan at mellanox.co.il
Mon Nov 27 03:40:30 PST 2006
Looks like a good idea to me.
I propose adding this rule to osm_drop_mgr.c too so cases where this
rule breaks are caught.
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