Yongkai Wu 8ace22bce8 hugetlbfs: call VM_BUG_ON_PAGE earlier in free_huge_page()
A stack trace was triggered by VM_BUG_ON_PAGE(page_mapcount(page), page)
in free_huge_page().  Unfortunately, the page->mapping field was set to
NULL before this test.  This made it more difficult to determine the
root cause of the problem.

Move the VM_BUG_ON_PAGE tests earlier in the function so that if they do
trigger more information is present in the page struct.

Link: http://lkml.kernel.org/r/1543491843-23438-1-git-send-email-nic_w@163.com
Signed-off-by: Yongkai Wu <nic_w@163.com>
Acked-by: Michal Hocko <mhocko@suse.com>
Acked-by: Mike Kravetz <mike.kravetz@oracle.com>
Reviewed-by: William Kucharski <william.kucharski@oracle.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2018-12-14 15:05:45 -08:00
..
2018-10-31 08:54:16 -07:00
2018-10-31 08:54:15 -07:00
2018-10-31 08:54:16 -07:00
2018-10-31 08:54:16 -07:00
2018-10-31 08:54:17 -07:00
2018-09-29 22:47:49 -04:00
2018-06-07 17:34:36 -07:00
2018-10-31 08:54:16 -07:00
2018-10-31 08:54:16 -07:00
2018-11-02 11:25:48 -07:00
2018-11-01 14:42:49 -07:00
2018-12-13 16:35:58 -08:00
2018-10-26 16:26:33 -07:00
2018-10-26 16:26:33 -07:00
2018-11-18 10:15:09 -08:00
2018-02-06 18:32:48 -08:00