diff options
author | Li Zefan <lizf@cn.fujitsu.com> | 2008-07-04 12:59:55 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2008-07-04 13:40:08 -0400 |
commit | bef67c5a7d3a9c45e091e36625c09c0c811e2672 (patch) | |
tree | 9e26d7896d6bf96ac8f65cf1b47955601705a921 /Documentation/cgroups.txt | |
parent | 4e0d13cbb71de2b1baf71ddd3c14f7ba8da810e5 (diff) |
cgroups: document the effect of attaching PID 0 to a cgroup
Document that a pid of zero(0) can be used to refer to the current task
when attaching a task to a cgroup, as in the following usage:
# echo 0 > /dev/cgroup/tasks
This is consistent with existing cpuset behavior.
Signed-off-by: Li Zefan <lizf@cn.fujitsu.com>
Acked-by: Paul Jackson <pj@sgi.com>
Acked-by: Dhaval Giani <dhaval@linux.vnet.ibm.com>
Cc: Paul Menage <menage@google.com>
Cc: Balbir Singh <balbir@in.ibm.com>
Cc: Andrea Righi <righi.andrea@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'Documentation/cgroups.txt')
-rw-r--r-- | Documentation/cgroups.txt | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/Documentation/cgroups.txt b/Documentation/cgroups.txt index 824fc0274471..d9014aa0eb68 100644 --- a/Documentation/cgroups.txt +++ b/Documentation/cgroups.txt | |||
@@ -390,6 +390,10 @@ If you have several tasks to attach, you have to do it one after another: | |||
390 | ... | 390 | ... |
391 | # /bin/echo PIDn > tasks | 391 | # /bin/echo PIDn > tasks |
392 | 392 | ||
393 | You can attach the current shell task by echoing 0: | ||
394 | |||
395 | # echo 0 > tasks | ||
396 | |||
393 | 3. Kernel API | 397 | 3. Kernel API |
394 | ============= | 398 | ============= |
395 | 399 | ||