diff options
Diffstat (limited to 'Documentation')
-rw-r--r-- | Documentation/cgroups/memory.txt | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/Documentation/cgroups/memory.txt b/Documentation/cgroups/memory.txt index e479007f1a75..6a066a270fc5 100644 --- a/Documentation/cgroups/memory.txt +++ b/Documentation/cgroups/memory.txt | |||
@@ -184,12 +184,14 @@ behind this approach is that a cgroup that aggressively uses a shared | |||
184 | page will eventually get charged for it (once it is uncharged from | 184 | page will eventually get charged for it (once it is uncharged from |
185 | the cgroup that brought it in -- this will happen on memory pressure). | 185 | the cgroup that brought it in -- this will happen on memory pressure). |
186 | 186 | ||
187 | But see section 8.2: when moving a task to another cgroup, its pages may | ||
188 | be recharged to the new cgroup, if move_charge_at_immigrate has been chosen. | ||
189 | |||
187 | Exception: If CONFIG_CGROUP_CGROUP_MEM_RES_CTLR_SWAP is not used. | 190 | Exception: If CONFIG_CGROUP_CGROUP_MEM_RES_CTLR_SWAP is not used. |
188 | When you do swapoff and make swapped-out pages of shmem(tmpfs) to | 191 | When you do swapoff and make swapped-out pages of shmem(tmpfs) to |
189 | be backed into memory in force, charges for pages are accounted against the | 192 | be backed into memory in force, charges for pages are accounted against the |
190 | caller of swapoff rather than the users of shmem. | 193 | caller of swapoff rather than the users of shmem. |
191 | 194 | ||
192 | |||
193 | 2.4 Swap Extension (CONFIG_CGROUP_MEM_RES_CTLR_SWAP) | 195 | 2.4 Swap Extension (CONFIG_CGROUP_MEM_RES_CTLR_SWAP) |
194 | 196 | ||
195 | Swap Extension allows you to record charge for swap. A swapped-in page is | 197 | Swap Extension allows you to record charge for swap. A swapped-in page is |
@@ -615,8 +617,7 @@ memory cgroup. | |||
615 | bit | what type of charges would be moved ? | 617 | bit | what type of charges would be moved ? |
616 | -----+------------------------------------------------------------------------ | 618 | -----+------------------------------------------------------------------------ |
617 | 0 | A charge of an anonymous page(or swap of it) used by the target task. | 619 | 0 | A charge of an anonymous page(or swap of it) used by the target task. |
618 | | Those pages and swaps must be used only by the target task. You must | 620 | | You must enable Swap Extension(see 2.4) to enable move of swap charges. |
619 | | enable Swap Extension(see 2.4) to enable move of swap charges. | ||
620 | -----+------------------------------------------------------------------------ | 621 | -----+------------------------------------------------------------------------ |
621 | 1 | A charge of file pages(normal file, tmpfs file(e.g. ipc shared memory) | 622 | 1 | A charge of file pages(normal file, tmpfs file(e.g. ipc shared memory) |
622 | | and swaps of tmpfs file) mmapped by the target task. Unlike the case of | 623 | | and swaps of tmpfs file) mmapped by the target task. Unlike the case of |
@@ -629,8 +630,6 @@ memory cgroup. | |||
629 | 630 | ||
630 | 8.3 TODO | 631 | 8.3 TODO |
631 | 632 | ||
632 | - Implement madvise(2) to let users decide the vma to be moved or not to be | ||
633 | moved. | ||
634 | - All of moving charge operations are done under cgroup_mutex. It's not good | 633 | - All of moving charge operations are done under cgroup_mutex. It's not good |
635 | behavior to hold the mutex too long, so we may need some trick. | 634 | behavior to hold the mutex too long, so we may need some trick. |
636 | 635 | ||