[Devel] [PATCH vz8.2 3/4] ve/memcg: Cleanup /proc/vmstat virtualization
Konstantin Khorenko
khorenko at virtuozzo.com
Thu Jul 22 16:53:21 MSK 2021
To_merge: ("5f48326db336 ve/memcg: Virtualize /proc/vmstat view inside CT")
https://jira.sw.ru/browse/PSBM-131992
Signed-off-by: Konstantin Khorenko <khorenko at virtuozzo.com>
---
mm/memcontrol.c | 13 ++++++-------
1 file changed, 6 insertions(+), 7 deletions(-)
diff --git a/mm/memcontrol.c b/mm/memcontrol.c
index 8d82bfd3f79a..b518bae93b29 100644
--- a/mm/memcontrol.c
+++ b/mm/memcontrol.c
@@ -3908,21 +3908,20 @@ void mem_cgroup_fill_vmstat(struct mem_cgroup *memcg, unsigned long *stats)
NR_VM_NODE_STAT_ITEMS +
NR_VM_WRITEBACK_STAT_ITEMS;
-
-
- zone_stats[NR_FREE_PAGES] = memory > limit ? 0 : limit- memory;
+ zone_stats[NR_FREE_PAGES] = memory > limit ? 0 : limit - memory;
for (i = LRU_BASE; i < NR_LRU_LISTS; i++) {
struct mem_cgroup *iter;
for_each_mem_cgroup_tree(iter, memcg)
- node_stats[NR_LRU_BASE + i] = mem_cgroup_nr_lru_pages(iter, BIT(i));
+ node_stats[NR_LRU_BASE + i] =
+ mem_cgroup_nr_lru_pages(iter, BIT(i));
}
node_stats[NR_ANON_MAPPED] = node_stats[NR_ACTIVE_ANON] +
- node_stats[NR_INACTIVE_ANON];
- node_stats[NR_FILE_PAGES] = node_stats[NR_ACTIVE_FILE] +
- node_stats[NR_INACTIVE_FILE];
+ node_stats[NR_INACTIVE_ANON];
+ node_stats[NR_FILE_PAGES] = node_stats[NR_ACTIVE_FILE] +
+ node_stats[NR_INACTIVE_FILE];
node_stats[NR_SLAB_RECLAIMABLE] = mem_page_state_recursive(
memcg, NR_SLAB_RECLAIMABLE);
--
2.28.0
More information about the Devel
mailing list