memory_failure() can handle free buddy page.  Support injecting hwpoison
to free page by adding is_free_buddy_page check when hwpoison filter is
disabled.
[akpm@linux-foundation.org: export is_free_buddy_page() to modules]
Link: https://lkml.kernel.org/r/20220218092052.3853-1-linmiaohe@huawei.com
Signed-off-by: Miaohe Lin <linmiaohe@huawei.com>
Cc: Naoya Horiguchi <naoya.horiguchi@nec.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
 
 
        shake_page(hpage);
        /*
-        * This implies unable to support non-LRU pages.
+        * This implies unable to support non-LRU pages except free page.
         */
-       if (!PageLRU(hpage) && !PageHuge(p))
+       if (!PageLRU(hpage) && !PageHuge(p) && !is_free_buddy_page(p))
                return 0;
 
        /*
 
 
        return order < MAX_ORDER;
 }
+EXPORT_SYMBOL(is_free_buddy_page);
 
 #ifdef CONFIG_MEMORY_FAILURE
 /*