]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
freezer: don't distinguish nosig tasks on thaw
authorTejun Heo <tj@kernel.org>
Sat, 20 Aug 2011 09:31:39 +0000 (11:31 +0200)
committerTejun Heo <tj@kernel.org>
Sat, 20 Aug 2011 09:31:39 +0000 (11:31 +0200)
There's no point in thawing nosig tasks before others.  There's no
ordering requirement between the two groups on thaw, which the staged
thawing can't guarantee anyway.  Simplify thaw_processes() by removing
the distinction and collapsing thaw_tasks() into thaw_processes().
This will help further updates to freezer.

Signed-off-by: Tejun Heo <tj@kernel.org>
kernel/power/process.c

index ddfaba4da2b16c2b812b821717aba611dc5d08b0..3eee548a5fdd08e6f192618e0ac9a95aab1989c7 100644 (file)
@@ -160,34 +160,28 @@ int freeze_processes(void)
        return error;
 }
 
-static void thaw_tasks(bool nosig_only)
+void thaw_processes(void)
 {
        struct task_struct *g, *p;
 
+       oom_killer_enable();
+
+       printk("Restarting tasks ... ");
+
+       thaw_workqueues();
+
        read_lock(&tasklist_lock);
        do_each_thread(g, p) {
                if (!freezable(p))
                        continue;
 
-               if (nosig_only && should_send_signal(p))
-                       continue;
-
                if (cgroup_freezing_or_frozen(p))
                        continue;
 
                __thaw_task(p);
        } while_each_thread(g, p);
        read_unlock(&tasklist_lock);
-}
-
-void thaw_processes(void)
-{
-       oom_killer_enable();
 
-       printk("Restarting tasks ... ");
-       thaw_workqueues();
-       thaw_tasks(true);
-       thaw_tasks(false);
        schedule();
        printk("done.\n");
 }