[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250107064951.200e9dfd@kernel.org>
Date: Tue, 7 Jan 2025 06:49:51 -0800
From: Jakub Kicinski <kuba@...nel.org>
To: Willem de Bruijn <willemdebruijn.kernel@...il.com>
Cc: davem@...emloft.net, netdev@...r.kernel.org, edumazet@...gle.com,
pabeni@...hat.com, dw@...idwei.uk, almasrymina@...gle.com,
jdamato@...tly.com
Subject: Re: [PATCH net-next 6/8] netdevsim: add queue management API
support
On Tue, 07 Jan 2025 09:03:54 -0500 Willem de Bruijn wrote:
> Jakub Kicinski wrote:
> > +/* Queue reset mode is controled by ns->rq_reset_mode.
>
> controlled
ack
> also perhaps an enum for the modes?
I couldn't come up with concise yet meaningful names for them, TBH :(
> > + * - normal - new NAPI new pool (old NAPI enabled when new added)
> > + * - mode 1 - allocate new pool (NAPI is only disabled / enabled)
> > + * - mode 2 - new NAPI new pool (old NAPI removed before new added)
> > + * - mode 3 - new NAPI new pool (old NAPI disabled when new added)
> > + */
> > + /* netif_napi_add()/_del() should normally be called from alloc/free,
> > + * here we want to test various call orders.
> > + */
> > + if (ns->rq_reset_mode == 2) {
> > + netif_napi_del(&ns->rq[idx]->napi);
> > + netif_napi_add_config(dev, &qmem->rq->napi, nsim_poll, idx);
> > + } else if (ns->rq_reset_mode == 3) {
> > + netif_napi_add_config(dev, &qmem->rq->napi, nsim_poll, idx);
> > + netif_napi_del(&ns->rq[idx]->napi);
>
> Just to make sure my understanding: this is expected to not change
> anything, due to test_and_(set|clear)_bit(NAPI_STATE_LISTED, ..),
> right?
Say more..
Note that ns->rq[idx]->napi != qmem->rq->napi
Powered by blists - more mailing lists