mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Paolo Abeni <pabeni@redhat.com>
To: Martin Karsten <mkarsten@uwaterloo.ca>,
	"David S. Miller" <davem@davemloft.net>,
	Eric Dumazet <edumazet@google.com>,
	Jakub Kicinski <kuba@kernel.org>, Simon Horman <horms@kernel.org>
Cc: "Joe Damato" <joe@dama.to>, "Tariq Toukan" <tariqt@nvidia.com>,
	"Gal Pressman" <gal@nvidia.com>, "Bj�rn T�pel" <bjorn@kernel.org>,
	"Frederik Deweerdt" <fdeweerdt@fastly.com>,
	"Dragos Tatulea" <dtatulea@nvidia.com>,
	netdev@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH net-next v3] net: napi: Skip last poll when arming gro timer in busy poll
Date: Thu, 21 May 2026 18:19:21 +0200	[thread overview]
Message-ID: <c75646e0-8a1c-4301-b6e8-fa2faf21563f@redhat.com> (raw)
In-Reply-To: <b785b518-3a76-4058-ab76-644df400cd0a@uwaterloo.ca>

On 5/21/26 5:42 PM, Martin Karsten wrote:
> On 2026-05-21 10:13, Paolo Abeni wrote:
>> On 5/18/26 8:13 PM, Martin Karsten wrote:
>>> +	} else {
>>> +		/* All we really want here is to re-enable device interrupts. */
>>> +		rc = napi->poll(napi, budget);
>>> +		/* We can't gro_normal_list() here, because napi->poll() might
>>> +		 * have rearmed the napi (napi_complete_done()) in which case
>>> +		 * it could already be running on another CPU.
>>> +		 */
>>> +		trace_napi_poll(napi, rc, budget);
>>> +		netpoll_poll_unlock(have_poll_lock);
>>> +		if (rc == budget) {
>>> +			gro_normal_list(&napi->gro);
>>
>> Not blocking, but I find the above slightly confusing after this
>> refactor. Perhaps it should be re-worded?
> 
> I'd be happy to reword, but I am not familiar with the internals of gro 
> processing, so would appreciate any help I can get?
> 
> Should I try-and-error via subsequent patch submission(s) or can you 
> comment on this version:
> 
> 		/* Use the driver poll to re-enable device interrupts. */
> 		rc = napi->poll(napi, budget);
> 		trace_napi_poll(napi, rc, budget);
> 		netpoll_poll_unlock(have_poll_lock);
> 		if (rc == budget) {
> 			/* If napi_complete_done has not been called by the
> 			 * driver poll, the napi needs to be rescheduled.
> 			 * Use the opportunity to pass up completed gro skbs.

Possibly something alike the following:

			/* More work to do: no concurrent napi-related 	
			 * irq is possible and the current thread can
			 * pass up the pending skb batch.
			 */

?



  reply	other threads:[~2026-05-21 16:19 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-05-18 18:13 Martin Karsten
2026-05-18 22:45 ` Joe Damato
2026-05-21 14:13 ` Paolo Abeni
2026-05-21 15:42   ` Martin Karsten
2026-05-21 16:19     ` Paolo Abeni [this message]
2026-05-22 23:50       ` Jakub Kicinski

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=c75646e0-8a1c-4301-b6e8-fa2faf21563f@redhat.com \
    --to=pabeni@redhat.com \
    --cc=bjorn@kernel.org \
    --cc=davem@davemloft.net \
    --cc=dtatulea@nvidia.com \
    --cc=edumazet@google.com \
    --cc=fdeweerdt@fastly.com \
    --cc=gal@nvidia.com \
    --cc=horms@kernel.org \
    --cc=joe@dama.to \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mkarsten@uwaterloo.ca \
    --cc=netdev@vger.kernel.org \
    --cc=tariqt@nvidia.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

all inboxes | Powered by JetHome®