On Fri, 3 Jul 2020 17:31:59 -0700 Michael Chan wrote:
> > >       bp->rx_nr_rings = rx_rings;
> > >       bp->cp_nr_rings = cp;
> > >
> > > @@ -8265,7 +8269,8 @@ int bnxt_reserve_rings(struct bnxt *bp, bool 
> > > irq_re_init)
> > >                       rc = bnxt_init_int_mode(bp);
> > >               bnxt_ulp_irq_restart(bp, rc);
> > >       }
> > > -     bnxt_set_dflt_rss_indir_tbl(bp);
> > > +     if (!netif_is_rxfh_configured(bp->dev))
> > > +             bnxt_set_dflt_rss_indir_tbl(bp);
> > >
> > >       if (rc) {
> > >               netdev_err(bp->dev, "ring reservation/IRQ init failure rc: 
> > > %d\n", rc);
> > > diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c 
> > > b/drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c
> > > index 46f3978..9098818 100644
> > > --- a/drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c
> > > +++ b/drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c
> > > @@ -926,6 +926,13 @@ static int bnxt_set_channels(struct net_device *dev,
> > >               return rc;
> > >       }
> > >
> > > +     if (bnxt_get_nr_rss_ctxs(bp, req_rx_rings) !=
> > > +         bnxt_get_nr_rss_ctxs(bp, bp->rx_nr_rings) &&
> > > +         (dev->priv_flags & IFF_RXFH_CONFIGURED)) {  
> >
> > In this case copy the old values over and zero-fill the new rings.  
> 
> If the existing RSS table has 128 entries and a custom map.  And now
> the table needs to expand to 192 entries with 64 new entries, we
> cannot just copy, right?  The weights will all be messed up if we try.
> I think requiring the user to change back to default or force it back
> to default are the only sane options.

I see it now, you're right.

Reply via email to