]> git.proxmox.com Git - mirror_ubuntu-eoan-kernel.git/commit
mm: memcontrol: use root_mem_cgroup res_counter
authorJohannes Weiner <hannes@cmpxchg.org>
Wed, 6 Aug 2014 23:05:59 +0000 (16:05 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Thu, 7 Aug 2014 01:01:17 +0000 (18:01 -0700)
commit05b8430123359886ef6a4146fba384e30d771b3f
tree6d83d5c64448f2cbb8fe1df84b7d423dd24f823a
parent692e7c45d95ad1064b6911800e2cfec7fc0236db
mm: memcontrol: use root_mem_cgroup res_counter

Due to an old optimization to keep expensive res_counter changes at a
minimum, the root_mem_cgroup res_counter is never charged; there is no
limit at that level anyway, and any statistics can be generated on
demand by summing up the counters of all other cgroups.

However, with per-cpu charge caches, res_counter operations do not even
show up in profiles anymore, so this optimization is no longer
necessary.

Remove it to simplify the code.

Signed-off-by: Johannes Weiner <hannes@cmpxchg.org>
Acked-by: Michal Hocko <mhocko@suse.com>
Cc: Hugh Dickins <hughd@google.com>
Cc: Tejun Heo <tj@kernel.org>
Cc: Vladimir Davydov <vdavydov@parallels.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
mm/memcontrol.c