[ofa-general] Re: [PATCHv2] infiniband-diags/perfquery.c: Support PMAs which don't support AllPortSelect option

Hal Rosenstock hrosenstock at xsigo.com
Sun Oct 21 07:37:56 PDT 2007


On Sun, 2007-10-21 at 15:52 +0200, Sasha Khapyorsky wrote:
> On 05:53 Sun 21 Oct     , Hal Rosenstock wrote:
> > On Sun, 2007-10-21 at 14:04 +0200, Sasha Khapyorsky wrote:
> > > On 16:25 Tue 16 Oct     , Hal Rosenstock wrote:
> > > > infiniband-diags/perfquery.c: Support PMAs which don't support
> > > > AllPortSelect option
> > > > 
> > > > Currently only support single port HCAs are supported in this mode but
> > > > this can be extended for other devices if needed
> > > > 
> > > > Tested-by: Greg Kurtzer <gmk at lbl.gov>
> > > > Signed-off-by: Hal Rosenstock <hal at xsigo.com>
> > > 
> > > Applied. Thanks.
> > > 
> > > However I have a question below.
> > > 
> > > > +	if (allports == 1) {
> > > > +
> > > > +		/*
> > > > +		 * Simulate all ports support in PMA
> > > > +		 * Determine node type, number of (physical) ports,
> > > > +		 * and, if switch, whether SP0 is enhanced
> > > > +		 * to determine first and last port to query
> > > > +		 */
> > > > +
> > > > +		/* For now, support single port CAs */
> > > > +		if (smp_query(data, &portid, IB_ATTR_NODE_INFO, 0, 0) < 0)
> > > > +			IBERROR("smp query nodeinfo failed");
> > > > +		node_type = mad_get_field(data, 0, IB_NODE_TYPE_F);
> > > > +		if (node_type != IB_NODE_CA)    /* NodeType other than CA ? */
> > > > +			IBERROR("smp query nodeinfo: Node type not CA");
> > > 
> > > Not supporting switches and routers
> > 
> > and multiport CAs
> > 
> > >  is temporary limitation (like
> > > all port simulation for single port CAs only), right?
> > 
> > Temporary in the sense that it can be fixed but I have no current plan
> > to do so as I am unaware of any practical need for this.
> 
> Probably it would be better to have cleaner error message then -
> something like "non-CA nodes are not supported yet."

To be more precise, it would be "Only single port CAs currently
supported". Feel free to change the message if you want.

> > Are you aware of such a need ?
> 
> Yes, assuming "all ports" queries are useful.

Can you be more specific as to where ? Greg's email was the only
indication of where this was needed.

-- Hal

> Sasha



More information about the general mailing list