Re: [PATCH] mm/page: Drop has_unaccepted_memory() helper

From: David Hildenbrand
Date: Mon Sep 09 2024 - 04:44:18 EST


On 09.09.24 10:19, Kirill A. Shutemov wrote:
has_unaccepted_memory() has the only caller -- cond_accept_memory().

Remove the helper and check zones_with_unaccepted_pages directly in
cond_accept_memory().

It also fixes warning with clang 18 when kernel is compiled without
unaccepted memory support:

mm/page_alloc.c:7043:20: error: unused function 'has_unaccepted_memory' [-Werror,-Wunused-function]

Signed-off-by: Kirill A. Shutemov <kirill.shutemov@xxxxxxxxxxxxxxx>
Reported-by: kernel test robot <lkp@xxxxxxxxx>
Closes: https://lore.kernel.org/oe-kbuild-all/202409061101.Jlx5z2fI-lkp@xxxxxxxxx/
---

Reviewed-by: David Hildenbrand <david@xxxxxxxxxx>

--
Cheers,

David / dhildenb