[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20100821032832.GB8616@verge.net.au>
Date: Sat, 21 Aug 2010 12:28:32 +0900
From: Simon Horman <horms@...ge.net.au>
To: "Paul E. McKenney" <paulmck@...ux.vnet.ibm.com>
Cc: lvs-devel@...r.kernel.org, netdev@...r.kernel.org,
netfilter-devel@...r.kernel.org,
Stephen Hemminger <shemminger@...tta.com>,
Wensong Zhang <wensong@...ux-vs.org>,
Julian Anastasov <ja@....bg>
Subject: Re: [rfc] IPVS: convert scheduler management to RCU
On Fri, Aug 20, 2010 at 12:29:00PM -0700, Paul E. McKenney wrote:
> On Fri, Aug 20, 2010 at 10:59:19PM +0900, Simon Horman wrote:
> > On Fri, Aug 20, 2010 at 10:33:21PM +0900, Simon Horman wrote:
> > > Signed-off-by: Simon Horman <horms@...ge.net.au>
[ snip ]
> > > @@ -223,8 +223,8 @@ int unregister_ip_vs_scheduler(struct ip
> > > /*
> > > * Remove it from the d-linked scheduler list
> > > */
> > > - list_del(&scheduler->n_list);
> > > - write_unlock_bh(&__ip_vs_sched_lock);
> > > + list_del_rcu(&scheduler->n_list);
> > > + spin_unlock_bh(&ip_vs_sched_mutex);
> >
> > On further reading, I believe that I need a synchronize_rcu(); here,
>
> Good catch!
:-)
> However, you actually need synchronize_rcu_bh() to match your
> rcu_read_lock_bh() calls. Also, given Julian's comment, you probably
> need something to show that this conversion is a real improvement.
Thanks. As suggested by Julian and others, I've decided to just
use a spinlock and not use RCU for this.
--
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