Commit 17408d78 authored by Li RongQing's avatar Li RongQing Committed by Linus Torvalds

mm: memcontrol: remove BUG_ON in uncharge_list

When calling uncharge_list, if a page is transparent huge we don't need
to BUG_ON about non-transparent huge, since nobody should be able to see
the page at this stage and this page cannot be raced against with a THP
split.

This check became unneeded after 0a31bc97 ("mm: memcontrol: rewrite
uncharge API").

[mhocko@suse.com: changelog enhancements]
Link: http://lkml.kernel.org/r/1465369248-13865-1-git-send-email-roy.qing.li@gmail.comSigned-off-by: default avatarLi RongQing <roy.qing.li@gmail.com>
Acked-by: default avatarMichal Hocko <mhocko@suse.com>
Acked-by: default avatarJohannes Weiner <hannes@cmpxchg.org>
Cc: Vladimir Davydov <vdavydov@virtuozzo.com>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent dd4123f3
...@@ -5580,7 +5580,6 @@ static void uncharge_list(struct list_head *page_list) ...@@ -5580,7 +5580,6 @@ static void uncharge_list(struct list_head *page_list)
if (PageTransHuge(page)) { if (PageTransHuge(page)) {
nr_pages <<= compound_order(page); nr_pages <<= compound_order(page);
VM_BUG_ON_PAGE(!PageTransHuge(page), page);
nr_huge += nr_pages; nr_huge += nr_pages;
} }
if (PageAnon(page)) if (PageAnon(page))
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment