Commit d755712e authored by Liu Shixin's avatar Liu Shixin Committed by Yongqiang Liu
Browse files

dhugetlb: isolate hwpoison hugepage when release

hulk inclusion
category: bugfix
bugzilla: 46904, https://gitee.com/openeuler/kernel/issues/I6GSKP


CVE: NA

--------------------------------

For a hwpoison hugetlb page, the page will be freed firstly. If succeed, it
will be dissolved and released to buddy system, then isolate the hwpoison page.

For a hwpoison hugepage belong to dynamic hugetlb, we isolate the hugepage
without dissolve it. Add a check in free_huge_page_to_dhugetlb_pool() to
isolate the hwpoison hugepage directly. And keep HUGETLB_PAGE_DTOR after free
to ensure the PageHuge() check return true in dissolve_free_huge_page().

Fixes: 0f0535e57da("dhugetlb: skip dissolve hugepage belonging to dynamic hugetlb")
Signed-off-by: default avatarLiu Shixin <liushixin2@huawei.com>
Reviewed-by: default avatarKefeng Wang <wangkefeng.wang@huawei.com>
Signed-off-by: default avatarYongqiang Liu <liuyongqiang13@huawei.com>
parent 77978cd7
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment