[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20100914.142749.55853240.davem@davemloft.net>
Date: Tue, 14 Sep 2010 14:27:49 -0700 (PDT)
From: David Miller <davem@...emloft.net>
To: eric.dumazet@...il.com
Cc: nicolas.dichtel@...nd.com, netdev@...r.kernel.org,
opurdila@...acom.com, bcrl@...ck.org
Subject: Re: [PATCH] net: use rcu_barrier() in rollback_registered_many
From: Eric Dumazet <eric.dumazet@...il.com>
Date: Tue, 14 Sep 2010 00:24:54 +0200
> [PATCH] net: use rcu_barrier() in rollback_registered_many
>
> netdev_wait_allrefs() waits that all references to a device vanishes.
>
> It currently uses a _very_ pessimistic 250 ms delay between each probe.
> Some users reported that no more than 4 devices can be dismantled per
> second, this is a pretty serious problem for some setups.
>
> Most of the time, a refcount is about to be released by an RCU callback,
> that is still in flight because rollback_registered_many() uses a
> synchronize_rcu() call instead of rcu_barrier(). Problem is visible if
> number of online cpus is one, because synchronize_rcu() is then a no op.
>
> time to remove 50 ipip tunnels on a UP machine :
>
> before patch : real 11.910s
> after patch : real 1.250s
>
> Reported-by: Nicolas Dichtel <nicolas.dichtel@...nd.com>
> Reported-by: Octavian Purdila <opurdila@...acom.com>
> Reported-by: Benjamin LaHaise <bcrl@...ck.org>
> Signed-off-by: Eric Dumazet <eric.dumazet@...il.com>
Applied, thanks Eric.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists