diff options
author | Anton Vorontsov <cbouatmailru@gmail.com> | 2012-01-04 00:09:35 -0500 |
---|---|---|
committer | Anton Vorontsov <cbouatmailru@gmail.com> | 2012-01-04 00:09:35 -0500 |
commit | 251f39fe42dae863bd24e30864e6b66076ba076d (patch) | |
tree | c804944bc17f3836d19cc8b5bc611dd1fb0ea915 /Documentation/power/freezing-of-tasks.txt | |
parent | 9b8872273af6983b246252a6508fa7cf34c69d6e (diff) | |
parent | 35b4c01e29bdd9632dabf9784ed3486333f00427 (diff) |
Merge branch 'power-supply-scope' of git://git.kernel.org/pub/scm/linux/kernel/git/jeremy/xen
Diffstat (limited to 'Documentation/power/freezing-of-tasks.txt')
-rw-r--r-- | Documentation/power/freezing-of-tasks.txt | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/Documentation/power/freezing-of-tasks.txt b/Documentation/power/freezing-of-tasks.txt index 38b57248fd6..316c2ba187f 100644 --- a/Documentation/power/freezing-of-tasks.txt +++ b/Documentation/power/freezing-of-tasks.txt | |||
@@ -22,12 +22,12 @@ try_to_freeze_tasks() that sets TIF_FREEZE for all of the freezable tasks and | |||
22 | either wakes them up, if they are kernel threads, or sends fake signals to them, | 22 | either wakes them up, if they are kernel threads, or sends fake signals to them, |
23 | if they are user space processes. A task that has TIF_FREEZE set, should react | 23 | if they are user space processes. A task that has TIF_FREEZE set, should react |
24 | to it by calling the function called refrigerator() (defined in | 24 | to it by calling the function called refrigerator() (defined in |
25 | kernel/power/process.c), which sets the task's PF_FROZEN flag, changes its state | 25 | kernel/freezer.c), which sets the task's PF_FROZEN flag, changes its state |
26 | to TASK_UNINTERRUPTIBLE and makes it loop until PF_FROZEN is cleared for it. | 26 | to TASK_UNINTERRUPTIBLE and makes it loop until PF_FROZEN is cleared for it. |
27 | Then, we say that the task is 'frozen' and therefore the set of functions | 27 | Then, we say that the task is 'frozen' and therefore the set of functions |
28 | handling this mechanism is referred to as 'the freezer' (these functions are | 28 | handling this mechanism is referred to as 'the freezer' (these functions are |
29 | defined in kernel/power/process.c and include/linux/freezer.h). User space | 29 | defined in kernel/power/process.c, kernel/freezer.c & include/linux/freezer.h). |
30 | processes are generally frozen before kernel threads. | 30 | User space processes are generally frozen before kernel threads. |
31 | 31 | ||
32 | It is not recommended to call refrigerator() directly. Instead, it is | 32 | It is not recommended to call refrigerator() directly. Instead, it is |
33 | recommended to use the try_to_freeze() function (defined in | 33 | recommended to use the try_to_freeze() function (defined in |
@@ -95,7 +95,7 @@ after the memory for the image has been freed, we don't want tasks to allocate | |||
95 | additional memory and we prevent them from doing that by freezing them earlier. | 95 | additional memory and we prevent them from doing that by freezing them earlier. |
96 | [Of course, this also means that device drivers should not allocate substantial | 96 | [Of course, this also means that device drivers should not allocate substantial |
97 | amounts of memory from their .suspend() callbacks before hibernation, but this | 97 | amounts of memory from their .suspend() callbacks before hibernation, but this |
98 | is e separate issue.] | 98 | is a separate issue.] |
99 | 99 | ||
100 | 3. The third reason is to prevent user space processes and some kernel threads | 100 | 3. The third reason is to prevent user space processes and some kernel threads |
101 | from interfering with the suspending and resuming of devices. A user space | 101 | from interfering with the suspending and resuming of devices. A user space |