Netdev List
 help / color / mirror / Atom feed
From: Stephen Hemminger <shemminger@linux-foundation.org>
To: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: linux-kernel <linux-kernel@vger.kernel.org>,
	netdev <netdev@vger.kernel.org>, Jeff Dike <jdike@addtoit.com>,
	David Miller <davem@davemloft.net>
Subject: Re: [PATCH] net: fix race in process_backlog
Date: Wed, 3 Oct 2007 09:15:26 -0700	[thread overview]
Message-ID: <20071003091526.2c1c6c1d@freepuppy.rosehill> (raw)
In-Reply-To: <1191426293.5599.27.camel@lappy>

On Wed, 03 Oct 2007 17:44:53 +0200
Peter Zijlstra <a.p.zijlstra@chello.nl> wrote:

> Subject: net: fix race in process_backlog
> 
> The recent NAPI rework (4fa57c9ea9f36f9ca852f3a88ca5d2f1aebbc960)
> introduced a race between netif_rx() and process_backlog() which
> resulted in softirq processing to drop dead.
> 
> netif_rx()		process_backlog()
> 
> 			irq_disable();
> 			skb = __skb_dequeue();
> 			irq_enable();
> 
> irq_disable();
> __skb_queue_tail();
> napi_schedule();
> irq_enable();
> 
> 			if (!skb)
> 			  napi_complete();  <-- oops!
> 
> we cleared the napi bit, even though there is data to process.
> 
> Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>

Acked-by: Stephen Hemminger <shemminger@linux-foundation.org>


-- 
Stephen Hemminger <shemminger@linux-foundation.org>

  reply	other threads:[~2007-10-03 16:15 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-10-03 15:44 [PATCH] net: fix race in process_backlog Peter Zijlstra
2007-10-03 16:15 ` Stephen Hemminger [this message]
2007-10-03 21:58 ` David Miller
2007-10-03 22:05   ` Stephen Hemminger
2007-10-03 23:39     ` David Miller

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=20071003091526.2c1c6c1d@freepuppy.rosehill \
    --to=shemminger@linux-foundation.org \
    --cc=a.p.zijlstra@chello.nl \
    --cc=davem@davemloft.net \
    --cc=jdike@addtoit.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    /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