public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Rusty Russell <rusty@rustcorp.com.au>
To: Ingo Molnar <mingo@elte.hu>
Cc: "Paweł Sikora" <pluto@agmk.net>,
	"linux kernel mailing list" <linux-kernel@vger.kernel.org>,
	netfilter-devel@lists.netfilter.org
Subject: Re: [2.6.14-rt1] slowdown / oops.
Date: Thu, 03 Nov 2005 13:09:01 +1100	[thread overview]
Message-ID: <1130983742.8734.19.camel@localhost.localdomain> (raw)
In-Reply-To: <20051102153352.GA26115@elte.hu>

On Wed, 2005-11-02 at 16:33 +0100, Ingo Molnar wrote:
> local_bh_disable()/enable() is a NOP under PREEMPT_RT, and the 
> ip_ct_deliver_cached_events PER_CPU code relies on not being preempted 
> by the net_rx_action softirq handler. So this is a bug in PREEMPT_RT and 
> the upstream code should be fine.
> 
> 	Ingo
> 
> Index: linux/net/ipv4/netfilter/ip_conntrack_core.c
> ===================================================================
> --- linux.orig/net/ipv4/netfilter/ip_conntrack_core.c
> +++ linux/net/ipv4/netfilter/ip_conntrack_core.c
> @@ -105,11 +105,11 @@ void ip_ct_deliver_cached_events(const s
>  {
>  	struct ip_conntrack_ecache *ecache;
>  	
> -	local_bh_disable();
> +	read_lock_bh(&ip_conntrack_lock);
>  	ecache = &__get_cpu_var(ip_conntrack_ecache);
>  	if (ecache->ct == ct)
>  		__ip_ct_deliver_cached_events(ecache);
> -	local_bh_enable();
> +	read_unlock_bh(&ip_conntrack_lock);

This kind of change is troubling.  I suppose we could go to per-cpu
locks, but it's still a loss.

Rusty.
-- 
A bad analogy is like a leaky screwdriver -- Richard Braakman


  reply	other threads:[~2005-11-03  2:09 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-11-02 13:20 [2.6.14-rt1] slowdown / oops Paweł Sikora
2005-11-02 13:29 ` Ingo Molnar
2005-11-02 13:40   ` Paweł Sikora
2005-11-02 13:44     ` Ingo Molnar
2005-11-02 13:47 ` Ingo Molnar
2005-11-02 13:55   ` Ingo Molnar
2005-11-02 14:00     ` Ingo Molnar
2005-11-02 14:25       ` Ingo Molnar
2005-11-02 15:12         ` Ingo Molnar
2005-11-02 15:33           ` Ingo Molnar
2005-11-03  2:09             ` Rusty Russell [this message]
2005-11-03 10:12               ` Ingo Molnar
  -- strict thread matches above, loose matches on Subject: below --
2005-11-02 17:36 Paweł Sikora

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=1130983742.8734.19.camel@localhost.localdomain \
    --to=rusty@rustcorp.com.au \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=netfilter-devel@lists.netfilter.org \
    --cc=pluto@agmk.net \
    /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