]> www.infradead.org Git - users/jedix/linux-maple.git/commitdiff
mm-hwpoison-hugetlb-introduce-subpage_index_hwpoison-to-save-raw-error-page-fix
authorNaoya Horiguchi <naoya.horiguchi@nec.com>
Fri, 3 Jun 2022 02:10:43 +0000 (02:10 +0000)
committerLiam R. Howlett <Liam.Howlett@oracle.com>
Wed, 20 Jul 2022 00:15:03 +0000 (20:15 -0400)
build fix

__get_huge_page_for_hwpoison() is not needed when CONFIG_HUGETLB_PAGE is
n, so extending "#ifdef CONFIG_HUGETLB_PAG" to cover
__get_huge_page_for_hwpoison() would be a simple resolution.

Reported-by: kernel test robot <lkp@intel.com>
Reported-by: Randy Dunlap <rdunlap@infradead.org>
Acked-by: Randy Dunlap <rdunlap@infradead.org>
Tested-by: Randy Dunlap <rdunlap@infradead.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
mm/memory-failure.c

index 1154c3da5c7e73583e5eb2e57c22004482705fdd..73458f6723f9049984d678ced68dc3d448a3b0b7 100644 (file)
@@ -1498,6 +1498,7 @@ static int try_to_split_thp_page(struct page *page, const char *msg)
        return 0;
 }
 
+#ifdef CONFIG_HUGETLB_PAGE
 /*
  * Called from hugetlb code with hugetlb_lock held.
  *
@@ -1546,7 +1547,6 @@ out:
        return ret;
 }
 
-#ifdef CONFIG_HUGETLB_PAGE
 /*
  * Taking refcount of hugetlb pages needs extra care about race conditions
  * with basic operations like hugepage allocation/free/demotion.