[ofa-general] Re: [PATCH] libibmad: initialize sm portid in ib_resolve_smlid()

Sasha Khapyorsky sashak at voltaire.com
Fri Dec 21 11:45:30 PST 2007


On 08:42 Fri 21 Dec     , akepner at sgi.com wrote:
> On Fri, Dec 21, 2007 at 04:30:37PM +0000, Sasha Khapyorsky wrote:
> > 
> > Initialize sm portid in ib_resolve_smlid() - likely it fixes crash when
> > in debug mode uninitialized direct path array printed.
> > 
> > Signed-off-by: Sasha Khapyorsky <sashak at voltaire.com>
> 
> Tested by: Arthur Kepner <akepner at sgi.com>

Thanks!

> Sasha - seems to fix things up when using the debug flags, 
> furthermore, it seems to make the original problem (the 
> failure of "smpquery -G ...") go away:

After looking more in the code I see that it is very possible - when
smpquery asks SA for PathRecord it uses PKey index value from sm_id
which was uninitialized before the patch. Assuming that PKey index
value was garbaged PathRecord query has been rejected by CA even
before it reached SM.

Seems we fixed both bugs in this patch (by initializing sm_id) - cool.
Thanks for the reporting and the great help with debugging this.

Sasha



More information about the general mailing list