[ofa-general] [PATCH] opensm: set hop limit when creating ipoib multicast groups

Rolf Manderscheid rvm at obsidianresearch.com
Thu Aug 30 16:08:34 PDT 2007


On Thu, Aug 30, 2007 at 01:25:43PM -0400, Hal Rosenstock wrote:
> On 8/30/07, Rolf Manderscheid <rvm at obsidianresearch.com> wrote:
> > On Thu, Aug 30, 2007 at 12:01:57PM -0400, Hal Rosenstock wrote:
> > > On 8/30/07, Rolf Manderscheid <rvm at obsidianresearch.com> wrote:
> > > > Hi Sasha,
> > > >
> > > > This patch sets the hop limit for the IPv4 broadcast groups so that broadcasts work
> > > > through IB routers.
> > > >
> > > > Signed-off-by: Rolf Manderscheid <rvm at obsidianresearch.com>
> > > >
> > > > ---
> > > >
> > > > diff --git a/opensm/opensm/osm_prtn.c b/opensm/opensm/osm_prtn.c
> > > > index 46ee429..fc000b1 100644
> > > > --- a/opensm/opensm/osm_prtn.c
> > > > +++ b/opensm/opensm/osm_prtn.c
> > > > @@ -213,7 +213,7 @@ ib_api_status_t osm_prtn_add_mcgroup(osm_log_t * p_log,
> > > >        mc_rec.pkey = pkey;
> > > >        mc_rec.rate = (rate ? rate : OSM_DEFAULT_MGRP_RATE) | (2 << 6); /* 10Gb/sec */
> > > >        mc_rec.pkt_life = OSM_DEFAULT_SUBNET_TIMEOUT;
> > > > -       mc_rec.sl_flow_hop = ib_member_set_sl_flow_hop(p->sl, 0, 0);
> > > > +       mc_rec.sl_flow_hop = ib_member_set_sl_flow_hop(p->sl, 0, 0xff);
> > >
> > > Shouldn't this be based on whether the group is local scope or not ?
> >
> > If the group has local scope then the hop limit is irrelevant, packets will get
> > dropped by the router anyway.  I certainly don't object to making the hop limit
> > conditional on scope if that's the preference.
> 
> Looking at the PathRecord code, it only checks whether a DGID was
> requested or not and then sets the hop limit only being dependent on
> whether ROUTER_EXP was defined or not. Should we follow continue to
> follow this or make PathRecord responses consistent with this ?


Isn't the plan to incorporate the ROUTER_EXP code eventually?  I would
rather not add any more #ifdefs if we can avoid it.  I think your suggestion
of setting the hop limit according to the scope of the multicast group seems
like the better option to me ... I'll post a new patch.  Are you OK with the
other patch to fix the scope of the second MGID?  If so, I'll base the new
patch on that.

    Rolf



More information about the general mailing list