[Devel] Re: [PATCH v6 3/3] cgroups: make procs file writable

2011-01-12 Thread Paul E. McKenney
On Fri, Dec 24, 2010 at 03:24:45AM -0500, Ben Blum wrote: > Makes procs file writable to move all threads by tgid at once > > From: Ben Blum > > This patch adds functionality that enables users to move all threads in a > threadgroup at once to a cgroup by writing the tgid to the 'cgroup.procs' >

[Devel] Re: [PATCH 5/5] blk-cgroup: Fix an RCU warning in blkiocg_create()

2010-05-07 Thread Paul E. McKenney
On Fri, May 07, 2010 at 08:57:41AM +0200, Jens Axboe wrote: > On Fri, May 07 2010, Li Zefan wrote: > > Paul E. McKenney wrote: > > > On Thu, Apr 22, 2010 at 05:32:28PM +0800, Li Zefan wrote: > > >> with CONFIG_PROVE_RCU=y, a warning can be triggered: > > >&g

[Devel] Re: [PATCH] cgroup: Check task_lock in task_subsys_state()

2010-04-22 Thread Paul E. McKenney
On Fri, Apr 23, 2010 at 10:35:52AM +0800, Li Zefan wrote: > task_subsys_state() is safe under task_lock(). See > Documentation/cgroups/cgroups.txt for locking rule. > > This fixes an RCU warning when resume from suspend. The > warning comes from freezer cgroup in cgroup_freezing_or_frozen(). > >

[Devel] Re: [PATCH 3/5] sched: Fix an RCU warning in print_task()

2010-04-22 Thread Paul E. McKenney
On Thu, Apr 22, 2010 at 02:12:12PM -0700, Matt Helsley wrote: > On Thu, Apr 22, 2010 at 12:20:04PM +0200, Peter Zijlstra wrote: > > > > > You can also pin a cgroup by holding whatever locks are held in the > > ->attach method. But the RCU annotation doesn't know (nor reasonably can > > know abou

[Devel] Re: [PATCH 4/5] freezer cgroup: Fix an RCU warning in cgroup_freezing_or_frozen()

2010-04-22 Thread Paul E. McKenney
On Thu, Apr 22, 2010 at 02:27:55PM +0200, Peter Zijlstra wrote: > On Thu, 2010-04-22 at 17:31 +0800, Li Zefan wrote: > > with CONFIG_PROVE_RCU, a warning can be triggered when we > > resume from suspend: > > > > ... > > include/linux/cgroup.h:533 invoked rcu_dereference_check() without > > protec

[Devel] Re: [PATCH 5/5] blk-cgroup: Fix an RCU warning in blkiocg_create()

2010-04-22 Thread Paul E. McKenney
On Thu, Apr 22, 2010 at 05:32:28PM +0800, Li Zefan wrote: > with CONFIG_PROVE_RCU=y, a warning can be triggered: > > # mount -t cgroup -o blkio xxx /mnt > # mkdir /mnt/subgroup > > ... > kernel/cgroup.c:4442 invoked rcu_dereference_check() without protection! > ... > > To fix this, we avoid

[Devel] Re: [PATCH 3/5] sched: Fix an RCU warning in print_task()

2010-04-22 Thread Paul E. McKenney
On Thu, Apr 22, 2010 at 05:30:40PM +0800, Li Zefan wrote: > With CONFIG_PROVE_RCU=y, a warning can be triggered: > > $ cat /proc/sched_debug > > ... > kernel/cgroup.c:1649 invoked rcu_dereference_check() without protection! > ... > > Both cgroup_path() and task_group() should be called with ei

[Devel] Re: [PATCH 2/5] cgroup: Fix an RCU warning in alloc_css_id()

2010-04-22 Thread Paul E. McKenney
On Thu, Apr 22, 2010 at 05:30:00PM +0800, Li Zefan wrote: > With CONFIG_PROVE_RCU=y, a warning can be triggered: > > # mount -t cgroup -o memory xxx /mnt > # mkdir /mnt/0 > > ... > kernel/cgroup.c:4442 invoked rcu_dereference_check() without protection! > ... > > This is a false-positive. It

[Devel] Re: [PATCH 1/5] cgroup: Fix an RCU warning in cgroup_path()

2010-04-22 Thread Paul E. McKenney
On Thu, Apr 22, 2010 at 05:29:24PM +0800, Li Zefan wrote: > with CONFIG_PROVE_RCU=y, a warning can be triggered: > > # mount -t cgroup -o debug xxx /mnt > # cat /proc/$$/cgroup > > ... > kernel/cgroup.c:1649 invoked rcu_dereference_check() without protection! > ... > > This is a false-positi

[Devel] Lockdep splat in cpuset code acquiring alloc_lock

2010-04-14 Thread Paul E. McKenney
Hello! I hit the following lockdep splat on one of many runs. Thoughts? Thanx, Paul = [ INFO: inconsistent lock state ] 2.6.34-rc3-au

[Devel] Re: [PATCH tip/core/urgent] rcu: protect fork-time cgroup access

2010-03-30 Thread Paul E. McKenney
On Tue, Mar 30, 2010 at 02:32:04AM -0700, Matt Helsley wrote: > > On Mon, Mar 29, 2010 at 11:42:55PM +0200, Peter Zijlstra wrote: > > > On Mon, 2010-03-29 at 14:34 -0700, Paul E. McKenney wrote: > > > > > > > And it appears that my patch is at best insuffici

[Devel] Re: [PATCH 6/6] Makes procs file writable to move all threads by tgid at once

2009-08-06 Thread Paul E. McKenney
On Thu, Aug 06, 2009 at 05:24:46PM +0200, Peter Zijlstra wrote: > On Thu, 2009-08-06 at 08:19 -0700, Paul E. McKenney wrote: > > > > > So yes, putting a rwsem in there sounds fine, you're already bouncing > > > it. > > > > If the critical sectio

[Devel] Re: [PATCH 6/6] Makes procs file writable to move all threads by tgid at once

2009-08-06 Thread Paul E. McKenney
On Thu, Aug 06, 2009 at 01:39:21PM +0200, Peter Zijlstra wrote: > On Thu, 2009-08-06 at 04:24 -0700, Paul Menage wrote: > > On Thu, Aug 6, 2009 at 4:02 AM, Peter Zijlstra > > wrote: > > > > > > Taking that many locks in general, some apps (JVM based usually) tend to > > > be thread heavy and can e

[Devel] Re: [PATCH 4/7] io-throttle controller infrastructure

2009-05-04 Thread Paul E. McKenney
On Sun, May 03, 2009 at 01:36:20PM +0200, Andrea Righi wrote: > This is the core of the io-throttle kernel infrastructure. It creates > the basic interfaces to the cgroup subsystem and implements the I/O > measurement and throttling functionality. Looks good from an RCU perspective!

[Devel] Re: [PATCH 4/7] io-throttle controller infrastructure

2009-04-21 Thread Paul E. McKenney
On Tue, Apr 21, 2009 at 02:58:30PM +0200, Andrea Righi wrote: > On Mon, Apr 20, 2009 at 09:15:24PM -0700, Paul E. McKenney wrote: > > > > How does the above lock relate to the iot->lock called out in the > > > > comment > > > > headers in the earlier f

[Devel] Re: [PATCH 4/7] io-throttle controller infrastructure

2009-04-20 Thread Paul E. McKenney
On Mon, Apr 20, 2009 at 11:22:27PM +0200, Andrea Righi wrote: > On Mon, Apr 20, 2009 at 10:59:04AM -0700, Paul E. McKenney wrote: > > On Sat, Apr 18, 2009 at 11:38:29PM +0200, Andrea Righi wrote: > > > This is the core of the io-throttle kernel infrastructure. It creates > >

[Devel] Re: [PATCH 4/7] io-throttle controller infrastructure

2009-04-20 Thread Paul E. McKenney
On Sat, Apr 18, 2009 at 11:38:29PM +0200, Andrea Righi wrote: > This is the core of the io-throttle kernel infrastructure. It creates > the basic interfaces to the cgroup subsystem and implements the I/O > measurement and throttling functionality. A few questions interspersed below.

[Devel] Re: [PATCH 3/14][TUN]: Introduce the tun_net structure.

2008-04-11 Thread Paul E. McKenney
On Fri, Apr 11, 2008 at 07:45:06PM +0400, Pavel Emelyanov wrote: > Paul E. McKenney wrote: > > On Fri, Apr 11, 2008 at 11:55:59AM +0400, Pavel Emelyanov wrote: > >> Paul E. McKenney wrote: > >>> On Thu, Apr 10, 2008 at 07:06:24PM +0400, Pavel Emelyanov wrote: &g

[Devel] Re: [PATCH 3/14][TUN]: Introduce the tun_net structure.

2008-04-11 Thread Paul E. McKenney
On Fri, Apr 11, 2008 at 11:55:59AM +0400, Pavel Emelyanov wrote: > Paul E. McKenney wrote: > > On Thu, Apr 10, 2008 at 07:06:24PM +0400, Pavel Emelyanov wrote: > >> This is the first step in making tuntap devices work in net > >> namespaces. The structure mentioned is

[Devel] Re: [PATCH 3/14][TUN]: Introduce the tun_net structure.

2008-04-10 Thread Paul E. McKenney
On Thu, Apr 10, 2008 at 07:06:24PM +0400, Pavel Emelyanov wrote: > This is the first step in making tuntap devices work in net > namespaces. The structure mentioned is pointed by generic > net pointer with tun_net_id id, and tun driver fills one on > its load. It will contain only the tun devices

[Devel] Re: [PATCH] Remove rcu_assign_pointer() penalty for NULL pointers

2007-11-30 Thread Paul E. McKenney
On Sat, Dec 01, 2007 at 12:07:52PM +1100, Herbert Xu wrote: > On Fri, Nov 30, 2007 at 04:37:21PM -0800, Paul E. McKenney wrote: > > > > The rcu_assign_pointer() primitive currently unconditionally executes > > a memory barrier, even when a NULL pointer is being assigned. T

[Devel] [PATCH] Remove rcu_assign_pointer() penalty for NULL pointers

2007-11-30 Thread Paul E. McKenney
-NULL and const/non-const) with gcc version 4.1.2, and hand-checked the assembly output. Signed-off-by: Paul E. McKenney <[EMAIL PROTECTED]> --- rcupdate.h | 11 +++ 1 file changed, 7 insertions(+), 4 deletions(-) diff -urpNa -X dontdiff linux-2.6.24-rc1-ego/include/linux/rcup

[Devel] Re: [PATCH (resubmit)][BRIDGE] Properly dereference the br_should_route_hook

2007-11-29 Thread Paul E. McKenney
On Fri, Nov 30, 2007 at 10:49:00AM +1100, Herbert Xu wrote: > On Thu, Nov 29, 2007 at 06:36:50AM -0800, Paul E. McKenney wrote: > > > > That certainly is an interesting tradeoff... Save a memory barrier > > when assigning NULL, but pay an extra test and branch in all case

[Devel] Re: [PATCH (resubmit)][BRIDGE] Properly dereference the br_should_route_hook

2007-11-29 Thread Paul E. McKenney
On Fri, Nov 30, 2007 at 12:04:20AM +1100, Herbert Xu wrote: > On Tue, Nov 27, 2007 at 07:21:08PM +0300, Pavel Emelyanov wrote: > > This hook is protected with the RCU, so simple > > > > if (br_should_route_hook) > > br_should_route_hook(...) > > > > is not enough on some architect

[Devel] Re: [PATCH] net: Fix race when opening a proc file while a network namespace is exiting.

2007-09-12 Thread Paul E. McKenney
t get confused and use > the wrong helper function. > > Then I fix up the callers to use get_proc_net and handle the case case > where get_proc_net returns NULL. In that case I return -ENXIO because > effectively the network namespace has already gone away so the files > we

[Devel] Re: [PATCH 03/16] net: Basic network namespace infrastructure.

2007-09-09 Thread Paul E. McKenney
On Sun, Sep 09, 2007 at 04:04:45AM -0600, Eric W. Biederman wrote: > "Paul E. McKenney" <[EMAIL PROTECTED]> writes: > > > On Sat, Sep 08, 2007 at 03:15:34PM -0600, Eric W. Biederman wrote: > >> > >> This is the basic infrastructure needed to support

[Devel] Re: [PATCH 03/16] net: Basic network namespace infrastructure.

2007-09-08 Thread Paul E. McKenney
On Sat, Sep 08, 2007 at 03:15:34PM -0600, Eric W. Biederman wrote: > > This is the basic infrastructure needed to support network > namespaces. This infrastructure is: > - Registration functions to support initializing per network > namespace data when a network namespaces is created or destroy

[Devel] Re: [RFC][PATCH] Make access to taks's nsproxy liter

2007-08-10 Thread Paul E. McKenney
On Wed, Aug 08, 2007 at 09:36:47PM +0400, Oleg Nesterov wrote: > On 08/08, Paul E. McKenney wrote: > > > > On Wed, Aug 08, 2007 at 08:41:07PM +0400, Oleg Nesterov wrote: > > > > +void switch_task_namespaces(struct task_struct *p, struct nsproxy *new) > > > >

[Devel] Re: [RFC][PATCH] Make access to taks's nsproxy liter

2007-08-10 Thread Paul E. McKenney
On Wed, Aug 08, 2007 at 08:41:07PM +0400, Oleg Nesterov wrote: > This time Paul E. McKenney actually cc'ed, sorry for the extra > noise... > > On 08/08, Pavel Emelyanov wrote: > > > > When someone wants to deal with some other taks's namespaces > > it