aboutsummaryrefslogtreecommitdiffstats
path: root/Documentation/cgroups/memory.txt
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2012-07-31 22:25:39 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2012-07-31 22:25:39 -0400
commitac694dbdbc403c00e2c14d10bc7b8412cc378259 (patch)
treee37328cfbeaf43716dd5914cad9179e57e84df76 /Documentation/cgroups/memory.txt
parenta40a1d3d0a2fd613fdec6d89d3c053268ced76ed (diff)
parent437ea90cc3afdca5229b41c6b1d38c4842756cb9 (diff)
Merge branch 'akpm' (Andrew's patch-bomb)
Merge Andrew's second set of patches: - MM - a few random fixes - a couple of RTC leftovers * emailed patches from Andrew Morton <akpm@linux-foundation.org>: (120 commits) rtc/rtc-88pm80x: remove unneed devm_kfree rtc/rtc-88pm80x: assign ret only when rtc_register_driver fails mm: hugetlbfs: close race during teardown of hugetlbfs shared page tables tmpfs: distribute interleave better across nodes mm: remove redundant initialization mm: warn if pg_data_t isn't initialized with zero mips: zero out pg_data_t when it's allocated memcg: gix memory accounting scalability in shrink_page_list mm/sparse: remove index_init_lock mm/sparse: more checks on mem_section number mm/sparse: optimize sparse_index_alloc memcg: add mem_cgroup_from_css() helper memcg: further prevent OOM with too many dirty pages memcg: prevent OOM with too many dirty pages mm: mmu_notifier: fix freed page still mapped in secondary MMU mm: memcg: only check anon swapin page charges for swap cache mm: memcg: only check swap cache pages for repeated charging mm: memcg: split swapin charge function into private and public part mm: memcg: remove needless !mm fixup to init_mm when charging mm: memcg: remove unneeded shmem charge type ...
Diffstat (limited to 'Documentation/cgroups/memory.txt')
-rw-r--r--Documentation/cgroups/memory.txt12
1 files changed, 7 insertions, 5 deletions
diff --git a/Documentation/cgroups/memory.txt b/Documentation/cgroups/memory.txt
index dd88540bb995..4372e6b8a353 100644
--- a/Documentation/cgroups/memory.txt
+++ b/Documentation/cgroups/memory.txt
@@ -73,6 +73,8 @@ Brief summary of control files.
73 73
74 memory.kmem.tcp.limit_in_bytes # set/show hard limit for tcp buf memory 74 memory.kmem.tcp.limit_in_bytes # set/show hard limit for tcp buf memory
75 memory.kmem.tcp.usage_in_bytes # show current tcp buf memory allocation 75 memory.kmem.tcp.usage_in_bytes # show current tcp buf memory allocation
76 memory.kmem.tcp.failcnt # show the number of tcp buf memory usage hits limits
77 memory.kmem.tcp.max_usage_in_bytes # show max tcp buf memory usage recorded
76 78
771. History 791. History
78 80
@@ -187,12 +189,12 @@ the cgroup that brought it in -- this will happen on memory pressure).
187But see section 8.2: when moving a task to another cgroup, its pages may 189But see section 8.2: when moving a task to another cgroup, its pages may
188be recharged to the new cgroup, if move_charge_at_immigrate has been chosen. 190be recharged to the new cgroup, if move_charge_at_immigrate has been chosen.
189 191
190Exception: If CONFIG_CGROUP_CGROUP_MEM_RES_CTLR_SWAP is not used. 192Exception: If CONFIG_CGROUP_CGROUP_MEMCG_SWAP is not used.
191When you do swapoff and make swapped-out pages of shmem(tmpfs) to 193When you do swapoff and make swapped-out pages of shmem(tmpfs) to
192be backed into memory in force, charges for pages are accounted against the 194be backed into memory in force, charges for pages are accounted against the
193caller of swapoff rather than the users of shmem. 195caller of swapoff rather than the users of shmem.
194 196
1952.4 Swap Extension (CONFIG_CGROUP_MEM_RES_CTLR_SWAP) 1972.4 Swap Extension (CONFIG_MEMCG_SWAP)
196 198
197Swap Extension allows you to record charge for swap. A swapped-in page is 199Swap Extension allows you to record charge for swap. A swapped-in page is
198charged back to original page allocator if possible. 200charged back to original page allocator if possible.
@@ -259,7 +261,7 @@ When oom event notifier is registered, event will be delivered.
259 per-zone-per-cgroup LRU (cgroup's private LRU) is just guarded by 261 per-zone-per-cgroup LRU (cgroup's private LRU) is just guarded by
260 zone->lru_lock, it has no lock of its own. 262 zone->lru_lock, it has no lock of its own.
261 263
2622.7 Kernel Memory Extension (CONFIG_CGROUP_MEM_RES_CTLR_KMEM) 2642.7 Kernel Memory Extension (CONFIG_MEMCG_KMEM)
263 265
264With the Kernel memory extension, the Memory Controller is able to limit 266With the Kernel memory extension, the Memory Controller is able to limit
265the amount of kernel memory used by the system. Kernel memory is fundamentally 267the amount of kernel memory used by the system. Kernel memory is fundamentally
@@ -286,8 +288,8 @@ per cgroup, instead of globally.
286 288
287a. Enable CONFIG_CGROUPS 289a. Enable CONFIG_CGROUPS
288b. Enable CONFIG_RESOURCE_COUNTERS 290b. Enable CONFIG_RESOURCE_COUNTERS
289c. Enable CONFIG_CGROUP_MEM_RES_CTLR 291c. Enable CONFIG_MEMCG
290d. Enable CONFIG_CGROUP_MEM_RES_CTLR_SWAP (to use swap extension) 292d. Enable CONFIG_MEMCG_SWAP (to use swap extension)
291 293
2921. Prepare the cgroups (see cgroups.txt, Why are cgroups needed?) 2941. Prepare the cgroups (see cgroups.txt, Why are cgroups needed?)
293# mount -t tmpfs none /sys/fs/cgroup 295# mount -t tmpfs none /sys/fs/cgroup