Kirill A. Shutemov
c17b1f4259
hugetlb: fix nr_pmds accounting with shared page tables
...
We account HugeTLB's shared page table to all processes who share it.
The accounting happens during huge_pmd_share().
If somebody populates pud entry under us, we should decrease pagetable's
refcount and decrease nr_pmds of the process.
By mistake, I increase nr_pmds again in this case. :-/ It will lead to
"BUG: non-zero nr_pmds on freeing mm: 2" on process' exit.
Let's fix this by increasing nr_pmds only when we're sure that the page
table will be used.
Link: http://lkml.kernel.org/r/20160617122506.GC6534@node.shutemov.name
Fixes: dc6c9a35b66b ("mm: account pmd page tables to the process")
Signed-off-by: Kirill A. Shutemov <kirill.shutemov@linux.intel.com>
Reported-by: zhongjiang <zhongjiang@huawei.com>
Reviewed-by: Mike Kravetz <mike.kravetz@oracle.com>
Acked-by: Michal Hocko <mhocko@suse.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2016-06-24 17:23:52 -07:00
..
2016-06-24 17:23:52 -07:00
2016-05-20 17:58:30 -07:00
2016-03-17 21:38:27 -07:00
2016-03-17 15:09:34 -07:00
2016-01-27 09:09:57 -05:00
2015-07-17 16:39:54 -07:00
2016-05-27 14:49:37 -07:00
2015-08-14 15:56:32 -07:00
2016-05-20 17:58:30 -07:00
2016-03-17 15:09:34 -07:00
2016-03-17 15:09:34 -07:00
2016-03-17 15:09:34 -07:00
2015-11-05 19:34:48 -08:00
2016-06-09 14:23:11 -07:00
2016-03-15 16:55:16 -07:00
2016-06-24 17:23:52 -07:00
2016-02-16 10:11:12 +01:00
2015-06-24 17:49:45 -07:00
2016-04-14 19:31:34 -07:00
2016-05-19 19:12:14 -07:00
2016-05-23 11:18:01 -07:00
2016-05-20 17:58:30 -07:00
2016-06-24 17:23:52 -07:00
2015-09-10 13:29:01 -07:00
2016-06-24 17:23:52 -07:00
2016-05-27 14:49:37 -07:00
2016-03-17 15:09:34 -07:00
2016-03-17 15:09:34 -07:00
2016-03-17 15:09:34 -07:00
2016-03-17 15:09:34 -07:00
2016-05-12 15:52:50 -07:00
2016-01-20 17:09:18 -08:00
2016-05-22 17:21:27 -07:00
2016-05-23 17:04:14 -07:00
2016-05-20 17:58:30 -07:00
2016-05-20 17:58:30 -07:00
2016-06-09 14:23:11 -07:00
2016-05-27 15:23:32 -07:00
2016-05-20 17:58:30 -07:00
2016-06-24 17:23:52 -07:00
2016-05-19 19:12:14 -07:00
2016-06-24 17:23:52 -07:00
2015-09-08 15:35:28 -07:00
2016-06-23 00:29:45 +02:00
2016-04-04 10:41:08 -07:00
2016-05-23 17:04:14 -07:00
2016-03-17 15:09:34 -07:00
2016-05-27 15:57:31 -07:00
2016-04-28 11:44:19 +02:00
2016-03-17 15:09:34 -07:00
2016-05-19 19:12:14 -07:00
2016-05-23 17:04:14 -07:00
2016-05-23 17:04:14 -07:00
2015-11-05 19:34:48 -08:00
2016-03-17 15:09:34 -07:00
2016-05-27 15:57:31 -07:00
2016-06-24 17:23:52 -07:00
2016-06-03 16:02:57 -07:00
2015-11-05 19:34:48 -08:00
2016-05-27 14:49:37 -07:00
2016-01-15 17:56:32 -08:00
2016-05-17 15:05:23 -07:00
2016-05-19 19:12:14 -07:00
2016-06-03 15:06:22 -07:00
2016-06-03 15:06:22 -07:00
2016-05-30 08:54:40 -06:00
2016-01-15 17:56:32 -08:00
2016-03-17 15:09:34 -07:00
2016-05-25 11:48:25 -04:00
2016-03-17 15:09:34 -07:00
2016-02-16 10:04:09 +01:00
2016-03-17 15:09:34 -07:00
2016-04-04 10:41:08 -07:00
2016-05-27 14:49:37 -07:00
2016-06-24 17:23:52 -07:00
2016-05-20 17:58:30 -07:00
2016-05-20 17:58:30 -07:00
2016-05-20 17:58:30 -07:00
2016-02-18 16:23:24 -08:00
2016-05-20 17:58:30 -07:00
2016-03-17 15:09:34 -07:00
2016-03-17 15:09:34 -07:00
2016-03-17 15:09:34 -07:00
2016-06-09 14:23:11 -07:00
2016-06-09 14:23:11 -07:00
2016-05-12 15:52:50 -07:00
2016-05-19 15:20:54 -06:00
2016-04-04 10:41:08 -07:00
2016-05-23 17:04:14 -07:00
2015-11-05 19:34:48 -08:00
2016-06-03 15:06:22 -07:00
2016-02-03 08:28:43 -08:00
2016-05-20 17:58:30 -07:00
2016-06-03 15:06:22 -07:00
2016-03-17 15:09:34 -07:00
2016-06-03 16:02:55 -07:00
2016-01-15 11:40:52 -08:00
2015-11-06 17:50:42 -08:00
2016-05-26 15:35:44 -07:00
2016-05-20 17:58:30 -07:00