Netdev List
 help / color / mirror / Atom feed
From: Eric Dumazet <eric.dumazet@gmail.com>
To: Michal Kubecek <mkubecek@suse.cz>
Cc: David Miller <davem@davemloft.net>,
	netdev@vger.kernel.org, kuznet@ms2.inr.ac.ru, jmorris@namei.org,
	yoshfuji@linux-ipv6.org, kaber@trash.net
Subject: Re: [PATCH net] ipv6: prevent fib6_run_gc() contention
Date: Tue, 11 Jun 2013 03:40:06 -0700	[thread overview]
Message-ID: <1370947206.3252.27.camel@edumazet-glaptop> (raw)
In-Reply-To: <20130611100718.GA7581@unicorn.suse.cz>

On Tue, 2013-06-11 at 12:07 +0200, Michal Kubecek wrote:

> That was my original idea but I was afraid that while the remaining
> window in ip6_dst_gc() would be very short and probably safe, we could
> still run into problem if fib6_gc_lock was locked by some other caller
> of fib6_run_gc() which doesn't update net->ipv6.ip6_rt_last_gc,
> especially via a timer.

This looks a bug (but not a big one) to me : 

We should update ip6_rt_last_gc if we did a gc,
not only from ip6_dst_gc()

So, I would move the "net->ipv6.ip6_rt_last_gc = now;" from ip6_dst_gc()
to fib6_run_gc(), right after the spin_lock_bh() ?

  reply	other threads:[~2013-06-11 10:40 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-06-04 11:08 [PATCH net] ipv6: prevent fib6_run_gc() contention Michal Kubecek
2013-06-10 21:26 ` David Miller
2013-06-11 10:07   ` Michal Kubecek
2013-06-11 10:40     ` Eric Dumazet [this message]
2013-06-11 20:01     ` David Miller
2013-06-11 20:49       ` Michal Kubecek
2013-06-11 21:22         ` David Miller
2013-07-31 22:19           ` Michal Kubecek
2013-07-31 23:43             ` 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=1370947206.3252.27.camel@edumazet-glaptop \
    --to=eric.dumazet@gmail.com \
    --cc=davem@davemloft.net \
    --cc=jmorris@namei.org \
    --cc=kaber@trash.net \
    --cc=kuznet@ms2.inr.ac.ru \
    --cc=mkubecek@suse.cz \
    --cc=netdev@vger.kernel.org \
    --cc=yoshfuji@linux-ipv6.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