]> git.baikalelectronics.ru Git - kernel.git/commit
mm: rmap: fix huge file mmap accounting in the memcg stats
authorJohannes Weiner <hannes@cmpxchg.org>
Fri, 31 Mar 2017 22:11:50 +0000 (15:11 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Sat, 1 Apr 2017 00:13:30 +0000 (17:13 -0700)
commita5d25299982ab1ed95888092e3df1b5befd24d3e
tree9daa7662d639426e54773ddac03b69a6fc5a5d7d
parent7c1369184a1e13ddae136b52ced888324e512724
mm: rmap: fix huge file mmap accounting in the memcg stats

Huge pages are accounted as single units in the memcg's "file_mapped"
counter.  Account the correct number of base pages, like we do in the
corresponding node counter.

Link: http://lkml.kernel.org/r/20170322005111.3156-1-hannes@cmpxchg.org
Signed-off-by: Johannes Weiner <hannes@cmpxchg.org>
Reviewed-by: Kirill A. Shutemov <kirill.shutemov@linux.intel.com>
Acked-by: Michal Hocko <mhocko@suse.com>
Cc: Vladimir Davydov <vdavydov.dev@gmail.com>
Cc: <stable@vger.kernel.org> [4.8+]
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
include/linux/memcontrol.h
mm/rmap.c