Re: [PATCH] opensm/mcast_tbl: set max_mlid_ho as actually configured mlid

Ira Weiny
2009-10-29T23:09:58Z

On Fri, 30 Oct 2009 01:02:46 +0200
Sasha Khapyorsky <sashak-smomgflXvOZWk0Htik3J/w@public.gmane.org> wrote:

> Hi Ira,
>
> Thanks for reporting.
>
> On 15:44 Thu 29 Oct , Ira Weiny wrote:
> >
> > OpenSM $ mlid_ho 49152; p_tbl->max_mlid_ho 49152
> > mlid_ho 49154; p_tbl->max_mlid_ho 49153
> > opensm: osm_mcast_tbl.c:107: osm_mcast_tbl_set: Assertion `mlid_ho <= p_tbl->max_mlid_ho' failed.
> > Aborted (core dumped)
>
> Small fix:
>
> diff --git a/opensm/opensm/osm_mcast_tbl.c b/opensm/opensm/osm_mcast_tbl.c
> index eee9290..0a45904 100644
> --- a/opensm/opensm/osm_mcast_tbl.c
> +++ b/opensm/opensm/osm_mcast_tbl.c
> @@ -145,7 +145,7 @@ int osm_mcast_tbl_realloc(IN osm_mcast_tbl_t * p_tbl, IN uintn_t mlid_offset)
> p_tbl->p_mask_tbl = p_mask_tbl;
> p_tbl->mft_depth = mft_depth;
> done:
> - p_tbl->max_mlid_ho = mlid_offset + IB_LID_MCAST_START_HO - 1;
> + p_tbl->max_mlid_ho = mlid_offset + IB_LID_MCAST_START_HO;
> return 0;
> }
>
>
> Does it work for you?

Yes that fixes the problem.

Thanks,
Ira

--
Ira Weiny
Math Programmer/Computer Scientist
Lawrence Livermore National Lab
925-423-8008
weiny2-i2BcT+NCU+M@public.gmane.org