diff options
author | Paul Jackson <pj@sgi.com> | 2008-02-07 03:14:48 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2008-02-07 11:42:23 -0500 |
commit | 8f5aa26c75b7722e80c0c5c5bb833d41865d7019 (patch) | |
tree | 7f1b27938b2732a70b99a65e49e83f1a77ac6aa9 /Documentation/cpusets.txt | |
parent | 73507f335f406ff31ceb97b39fa76eaee00f4f26 (diff) |
cpusets: update_cpumask documentation fix
Update cpuset documentation to match the October 2007 "Fix cpusets
update_cpumask" changes that now apply changes to a cpusets 'cpus' allowed
mask immediately to the cpus_allowed of the tasks in that cpuset.
Signed-off-by: Paul Jackson <pj@sgi.com>
Acked-by: Cliff Wickman <cpw@sgi.com>
Cc: David Rientjes <rientjes@google.com>
Cc: Paul Menage <menage@google.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'Documentation/cpusets.txt')
-rw-r--r-- | Documentation/cpusets.txt | 23 |
1 files changed, 8 insertions, 15 deletions
diff --git a/Documentation/cpusets.txt b/Documentation/cpusets.txt index 141bef1c8599..43db6fe12814 100644 --- a/Documentation/cpusets.txt +++ b/Documentation/cpusets.txt | |||
@@ -523,21 +523,14 @@ from one cpuset to another, then the kernel will adjust the tasks | |||
523 | memory placement, as above, the next time that the kernel attempts | 523 | memory placement, as above, the next time that the kernel attempts |
524 | to allocate a page of memory for that task. | 524 | to allocate a page of memory for that task. |
525 | 525 | ||
526 | If a cpuset has its CPUs modified, then each task using that | 526 | If a cpuset has its 'cpus' modified, then each task in that cpuset |
527 | cpuset does _not_ change its behavior automatically. In order to | 527 | will have its allowed CPU placement changed immediately. Similarly, |
528 | minimize the impact on the critical scheduling code in the kernel, | 528 | if a tasks pid is written to a cpusets 'tasks' file, in either its |
529 | tasks will continue to use their prior CPU placement until they | 529 | current cpuset or another cpuset, then its allowed CPU placement is |
530 | are rebound to their cpuset, by rewriting their pid to the 'tasks' | 530 | changed immediately. If such a task had been bound to some subset |
531 | file of their cpuset. If a task had been bound to some subset of its | 531 | of its cpuset using the sched_setaffinity() call, the task will be |
532 | cpuset using the sched_setaffinity() call, and if any of that subset | 532 | allowed to run on any CPU allowed in its new cpuset, negating the |
533 | is still allowed in its new cpuset settings, then the task will be | 533 | affect of the prior sched_setaffinity() call. |
534 | restricted to the intersection of the CPUs it was allowed on before, | ||
535 | and its new cpuset CPU placement. If, on the other hand, there is | ||
536 | no overlap between a tasks prior placement and its new cpuset CPU | ||
537 | placement, then the task will be allowed to run on any CPU allowed | ||
538 | in its new cpuset. If a task is moved from one cpuset to another, | ||
539 | its CPU placement is updated in the same way as if the tasks pid is | ||
540 | rewritten to the 'tasks' file of its current cpuset. | ||
541 | 534 | ||
542 | In summary, the memory placement of a task whose cpuset is changed is | 535 | In summary, the memory placement of a task whose cpuset is changed is |
543 | updated by the kernel, on the next allocation of a page for that task, | 536 | updated by the kernel, on the next allocation of a page for that task, |