From: Jakub Kicinski <kuba@kernel.org>
To: Eric Dumazet <edumazet@google.com>
Cc: davem@davemloft.net, netdev@vger.kernel.org, pabeni@redhat.com,
saeedm@nvidia.com, leon@kernel.org, brouer@redhat.com,
tariqt@mellanox.com
Subject: Re: [PATCH net] net/mlx5e: do as little as possible in napi poll when budget is 0
Date: Tue, 16 May 2023 19:02:32 -0700 [thread overview]
Message-ID: <20230516190232.71b1ba28@kernel.org> (raw)
In-Reply-To: <CANn89iJgT49PKvwZKXShQXivayESxRWYOHC5tHC8CLwkTSwmZg@mail.gmail.com>
On Mon, 15 May 2023 18:39:20 +0200 Eric Dumazet wrote:
> > + /* budget=0 means we may be in IRQ context, do as little as possible */
> > + if (unlikely(!budget)) {
> > + /* no work done, can't be asked to re-enable IRQs */
> > + WARN_ON_ONCE(napi_complete_done(napi, work_done));
>
> This is not clear why you call napi_complete_done() here ?
>
> Note the fine doc ( https://www.kernel.org/doc/html/next/networking/napi.html )
> says:
>
> <quote>If the budget is 0 napi_complete_done() should never be called.</quote>
fair point, I was trying to be conservative because I think it would
have gotten called before
prev parent reply other threads:[~2023-05-17 2:02 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-05-12 2:57 [PATCH net] net/mlx5e: do as little as possible in napi poll when budget is 0 Jakub Kicinski
2023-05-15 6:10 ` Tariq Toukan
2023-05-15 16:39 ` Eric Dumazet
2023-05-17 2:02 ` Jakub Kicinski [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20230516190232.71b1ba28@kernel.org \
--to=kuba@kernel.org \
--cc=brouer@redhat.com \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=leon@kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=saeedm@nvidia.com \
--cc=tariqt@mellanox.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).