mm, hwpoison: make unpoison aware of raw error info in hwpoisoned hugepage
authorNaoya Horiguchi <naoya.horiguchi@nec.com>
Thu, 14 Jul 2022 04:24:16 +0000 (13:24 +0900)
committerAndrew Morton <akpm@linux-foundation.org>
Tue, 9 Aug 2022 01:06:44 +0000 (18:06 -0700)
commitac5fcde0a96a18773f06b7c00c5ea081bbdc64b3
treed43c1dcc17a8412deb8de67f3a29b692141d2287
parent161df60e9e89651c9aa3ae0edc9aae3a8a2d21e7
mm, hwpoison: make unpoison aware of raw error info in hwpoisoned hugepage

Raw error info list needs to be removed when hwpoisoned hugetlb is
unpoisoned.  And unpoison handler needs to know how many errors there are
in the target hugepage.  So add them.

HPageVmemmapOptimized(hpage) and HPageRawHwpUnreliable(hpage)) sometimes
can't be unpoisoned, so skip them.

Link: https://lkml.kernel.org/r/20220714042420.1847125-5-naoya.horiguchi@linux.dev
Signed-off-by: Naoya Horiguchi <naoya.horiguchi@nec.com>
Reported-by: kernel test robot <lkp@intel.com>
Reviewed-by: Miaohe Lin <linmiaohe@huawei.com>
Cc: David Hildenbrand <david@redhat.com>
Cc: Liu Shixin <liushixin2@huawei.com>
Cc: Mike Kravetz <mike.kravetz@oracle.com>
Cc: Muchun Song <songmuchun@bytedance.com>
Cc: Oscar Salvador <osalvador@suse.de>
Cc: Yang Shi <shy828301@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
include/linux/swapops.h
mm/memory-failure.c