The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: Nigel Cunningham <ncunningham@crca.org.au>
To: Matt Helsley <matthltc@us.ibm.com>
Cc: Andrew Morton <akpm@linux-foundation.org>,
	"Rafael J. Wysocki" <rjw@sisk.pl>,
	Paul Menage <menage@google.com>, Li Zefan <lizf@cn.fujitsu.com>,
	Linux-Kernel <linux-kernel@vger.kernel.org>,
	Linux Containers <containers@lists.linux-foundation.org>,
	linux-pm@lists.linux-foundation.org,
	Cedric Le Goater <clg@fr.ibm.com>,
	"Serge E. Hallyn" <serue@us.ibm.com>
Subject: Re: [PATCH 4/6] Container Freezer: Skip frozen cgroups during power management resume
Date: Fri, 01 Aug 2008 20:24:40 +1000	[thread overview]
Message-ID: <1217586280.27551.18.camel@nigel-laptop> (raw)
In-Reply-To: <20080801050701.070484831@us.ibm.com>

Hi.

On Thu, 2008-07-31 at 22:07 -0700, Matt Helsley wrote:
> When a system is resumed after a suspend, it will also unfreeze
> frozen cgroups.
> 
> This patchs modifies the resume sequence to skip the tasks which
> are part of a frozen control group.
> 
> Signed-off-by: Cedric Le Goater <clg@fr.ibm.com>
> Signed-off-by: Matt Helsley <matthltc@us.ibm.com>
> Acked-by: Serge E. Hallyn <serue@us.ibm.com>
> Tested-by: Matt Helsley <matthltc@us.ibm.com>

I understand the freezer pretty well, so maybe I can help a little.

Acked-by: Nigel Cunningham <nigel@tuxonice.net>

> ---
>  kernel/power/process.c |    4 ++++
>  1 files changed, 4 insertions(+), 0 deletions(-)
> 
> diff --git a/kernel/power/process.c b/kernel/power/process.c
> index 444cea8..ce9e280 100644
> --- a/kernel/power/process.c
> +++ b/kernel/power/process.c
> @@ -13,6 +13,7 @@
>  #include <linux/module.h>
>  #include <linux/syscalls.h>
>  #include <linux/freezer.h>
> +#include <linux/cgroup_freezer.h>
>  
>  /* 
>   * Timeout for stopping processes
> @@ -135,6 +136,9 @@ static void thaw_tasks(bool nosig_only)
>  		if (nosig_only && should_send_signal(p))
>  			continue;
>  
> +		if (cgroup_frozen(p))
> +			continue;
> +
>  		thaw_process(p);
>  	} while_each_thread(g, p);
>  	read_unlock(&tasklist_lock);
> -- 
> 1.5.3.7
> 


  reply	other threads:[~2008-08-01 11:46 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-08-01  5:06 [PATCH 0/6] Container Freezer: Reuse Suspend Freezer Matt Helsley
2008-08-01  5:07 ` [PATCH 1/6] Container Freezer: Add TIF_FREEZE flag to all architectures Matt Helsley
2008-08-01 10:32   ` Nigel Cunningham
2008-08-01 12:32     ` Cedric Le Goater
2008-08-01 22:05       ` Matt Helsley
2008-08-01 22:54         ` Rafael J. Wysocki
2008-08-02  1:13         ` Nigel Cunningham
2008-08-01  5:07 ` [PATCH 2/6] Container Freezer: Make refrigerator always available Matt Helsley
2008-08-01 10:33   ` Nigel Cunningham
2008-08-01 14:27   ` Thomas Petazzoni
2008-08-01 19:08     ` Matt Helsley
2008-08-01 22:53       ` Rafael J. Wysocki
2008-08-01 23:24         ` Matt Helsley
2008-08-02 14:34           ` Rafael J. Wysocki
2008-08-02  2:30         ` Matt Helsley
2008-08-02 10:39       ` Thomas Petazzoni
2008-08-01  5:07 ` [PATCH 3/6] Container Freezer: Implement freezer cgroup subsystem Matt Helsley
2008-08-01 22:58   ` Rafael J. Wysocki
2008-08-02  0:11     ` Matt Helsley
2008-08-02  7:38       ` Cedric Le Goater
2008-08-02 14:37         ` Rafael J. Wysocki
2008-08-01  5:07 ` [PATCH 4/6] Container Freezer: Skip frozen cgroups during power management resume Matt Helsley
2008-08-01 10:24   ` Nigel Cunningham [this message]
2008-08-01  5:07 ` [PATCH 5/6] Container Freezer: Prevent frozen tasks or cgroups from changing Matt Helsley
2008-08-01  5:07 ` [PATCH 6/6] Container Freezer: Use cgroup write_string method Matt Helsley
2008-08-01  5:16 ` [PATCH 0/6] Container Freezer: Reuse Suspend Freezer Matt Helsley
2008-08-01 13:04   ` Rafael J. Wysocki

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1217586280.27551.18.camel@nigel-laptop \
    --to=ncunningham@crca.org.au \
    --cc=akpm@linux-foundation.org \
    --cc=clg@fr.ibm.com \
    --cc=containers@lists.linux-foundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@lists.linux-foundation.org \
    --cc=lizf@cn.fujitsu.com \
    --cc=matthltc@us.ibm.com \
    --cc=menage@google.com \
    --cc=rjw@sisk.pl \
    --cc=serue@us.ibm.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox