Re: [infiniband-diags] [PATCH] [2/2] split out scan specific data from ibnd_node_t

Sasha Khapyorsky
2009-11-12T16:31:05Z

On 10:34 Fri 06 Nov , Al Chu wrote:
> >
> > Why do you want to remove this? port->path_portid can be useful for
> > logging, specific querying, etc.. Even node->dnext can be helpful for
> > some "advanced" use too.
>
> The 'nodesdist' array (which is what the 'dnext' pointer is used for) is
> only used during the scan and is no longer available publicly.

Really? I thought that it could be a useful data for "advanced" uses.

> So the
> 'dnext' pointer doesn't serve a purpose being in the public ibnd_node_t
> struct.
>
> Post scan, the 'path_portid' was ony used in ibnd_update_node(), which
> is now removed.

You are saying about libibnetdisc itself. My example was about an
application which uses this. For instance after discovery application
may want to query some ports for its own purpose. What is wrong with
that?

> In addition, Ira and I felt it is one of the fields
> that shouldn't have been exported out of libibnetdisc, it is far too
> "scan specific" and shouldn't be public.

I cannot understand why are you trying to make things there as "private"
as technically possible (even on price of extra code size and
complexity). Finally it is an open source stuff, so let to users to use
it how they want and for their own responsibility. :)

Sasha