lkml.org 
[lkml]   [2013]   [Jun]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] Generic percpu refcounting
On Wed, Jun 05, 2013 at 05:05:09PM +0930, Rusty Russell wrote:
> I think this should be rcu_read_lock(), which is currently equivalent
> but theoretically different.

I suggested using preempt_disable/enable() along with sched RCU. I
thought that was better for some reason but I was probably
misremembering something. rcu_read_lock/unlock() w/ synchronize_rcu()
should be fine too. I don't care either way.

> Does your percpu_ref_kill() *really* need to be nonblocking? (I'd have
> to read your other patches which use this to be sure). Otherwise, just
> use synchronize_rcu(), and get rid of the release function...

synchronize_rcu() can always become problematic and should always be
avoided for generic things which may be used in various ways. They
develop into very long latencies pretty quickly when chained back to
back.

Thanks.

--
tejun


\
 
 \ /
  Last update: 2013-06-05 10:01    [W:0.039 / U:0.560 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site