lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CA+sq2Cdqw7B42mdy-K7Rric1VTWZ8cPTB_ViTqAb+Gjc+5aZ5g@mail.gmail.com>
Date:   Fri, 17 Jan 2020 23:06:36 +0530
From:   Sunil Kovvuri <sunil.kovvuri@...il.com>
To:     Jakub Kicinski <kuba@...nel.org>
Cc:     Linux Netdev List <netdev@...r.kernel.org>,
        "David S. Miller" <davem@...emloft.net>,
        Michal Kubecek <mkubecek@...e.cz>,
        Sunil Goutham <sgoutham@...vell.com>
Subject: Re: [PATCH v3 11/17] octeontx2-pf: Receive side scaling support

On Fri, Jan 17, 2020 at 7:09 AM Jakub Kicinski <kuba@...nel.org> wrote:
>
> On Fri, 17 Jan 2020 01:17:27 +0530, sunil.kovvuri@...il.com wrote:
> > +int otx2_rss_init(struct otx2_nic *pfvf)
> > +{
> > +     struct otx2_rss_info *rss = &pfvf->hw.rss_info;
> > +     int idx, ret = 0;
> > +
> > +     /* Enable RSS */
> > +     rss->enable = true;
> > +     rss->rss_size = sizeof(rss->ind_tbl);
> > +
> > +     /* Init RSS key here */
> > +     netdev_rss_key_fill(rss->key, sizeof(rss->key));
> > +     otx2_set_rss_key(pfvf);
> > +
> > +     /* Default indirection table */
> > +     for (idx = 0; idx < rss->rss_size; idx++)
> > +             rss->ind_tbl[idx] =
> > +                     ethtool_rxfh_indir_default(idx, pfvf->hw.rx_queues);
> > +
> > +     ret = otx2_set_rss_table(pfvf);
> > +     if (ret)
> > +             return ret;
> > +
> > +     /* Default flowkey or hash config to be used for generating flow tag */
> > +     rss->flowkey_cfg = NIX_FLOW_KEY_TYPE_IPV4 | NIX_FLOW_KEY_TYPE_IPV6 |
> > +                        NIX_FLOW_KEY_TYPE_TCP | NIX_FLOW_KEY_TYPE_UDP |
> > +                        NIX_FLOW_KEY_TYPE_SCTP;
> > +
> > +     return otx2_set_flowkey_cfg(pfvf);
> > +}
>
> > diff --git a/drivers/net/ethernet/marvell/octeontx2/nic/otx2_pf.c b/drivers/net/ethernet/marvell/octeontx2/nic/otx2_pf.c
> > index 557f86b..fe5b3de 100644
> > --- a/drivers/net/ethernet/marvell/octeontx2/nic/otx2_pf.c
> > +++ b/drivers/net/ethernet/marvell/octeontx2/nic/otx2_pf.c
> > @@ -838,6 +838,11 @@ int otx2_open(struct net_device *netdev)
> >       if (err)
> >               goto err_disable_napi;
> >
> > +     /* Initialize RSS */
> > +     err = otx2_rss_init(pf);
> > +     if (err)
> > +             goto err_disable_napi;
>
> Looks like you fully reset the RSS params on every close/open cycle?
> I don't think that's the expected behaviour/what most NICs do.
> For example you should only reset the indir table if
> netif_is_rxfh_configure() returns false.

Thanks for pointing, will check this.

Sunil.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ