From mboxrd@z Thu Jan 1 00:00:00 1970 From: Matt Helsley Subject: Re: [PATCH 4/4] cgroup freezer: --- replacement patch 4/4 (b) Date: Thu, 4 Jun 2009 03:45:27 -0700 Message-ID: <20090604104527.GY9285@us.ibm.com> References: <89c3726813accffb7c51cd30ff93b79a4391f382.1244019829.git.matthltc@us.ibm.com> <20090603161840.GD7848@us.ibm.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Content-Disposition: inline In-Reply-To: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: containers-bounces-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org Errors-To: containers-bounces-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org To: Oren Laadan Cc: Paul Menage , Containers List-Id: containers.vger.kernel.org On Wed, Jun 03, 2009 at 08:12:19PM -0400, Oren Laadan wrote: > From 3c24531980764a71705492c2dfc2cc99366784f3 Mon Sep 17 00:00:00 2001 > From: Oren Laadan > Date: Wed, 3 Jun 2009 19:31:21 -0400 > Subject: [PATCH] c/r: use CHECKPOINTING state for hierarchy's cgroup freezer > > Set state of freezer cgroup of checkpointed task hierarchy to > "CHECKPOINTING" during a checkpoint, to ensure that tasks cannot > be thawed while at it. > > get_container() grabs a reference to the root task's freezer cgroup. > Then in may_checkpoint_task() each it verifies that all tasks belong > to the same freezer group. Ugh, I really don't like grabbing this reference. It may be necessary though -- I need to think about it more. > > In particular, the root task is also tested, such that if the root > tasks changes its freezer cgroups before it moves to "CHECKPOINTING", > it will be notived and an error returned. Tasks in a CHECKPOINTING cgroup are frozen and frozen tasks cannot move. See freezer_can_attach(). This does rather complicate self-checkpoint though! See my reply to your follow-on patches.. Cheers, -Matt Helsley