[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20110901112221.GA2752@htj.dyndns.org>
Date: Thu, 1 Sep 2011 20:22:21 +0900
From: Tejun Heo <tj@...nel.org>
To: Frederic Weisbecker <fweisbec@...il.com>
Cc: rjw@...k.pl, paul@...lmenage.org, lizf@...fujitsu.com,
linux-pm@...ts.linux-foundation.org, linux-kernel@...r.kernel.org,
containers@...ts.linux-foundation.org, matthltc@...ibm.com,
kamezawa.hiroyu@...fujitsu.com
Subject: Re: [PATCH 6/6] cgroup: kill subsys->can_attach_task(), pre_attach()
and attach_task()
Hello,
On Wed, Aug 31, 2011 at 03:42:24PM +0200, Frederic Weisbecker wrote:
> My task counter subsystem patchset brings a cancel_attach_task() callback
> that cancels can_attach_task() effects.
>
> I thought that rebased on top of your patch it's going to be merged inside
> cancel_attach() but OTOH we can't cancel the effect of failed migration
> on a thread that way.
>
> May be we need to keep a cancel_attach_task() just for that purpose?
We can do that but I think that becomes a bit too complex and fragile.
That path won't be traveled unless it races against exit. Bugs will
be difficult to detect and reproduce. In this respect, the current
code already seems racy. ->can_attach (or other methods in the attach
path) and ->exit can race each other and I don't think all subsystems
handle that properly.
IMHO the right thing to do here is simplifying synchronization rules
so that nothing else happens while migration is in progress.
Thanks.
--
tejun
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists