Re: mm/munlock: mlock_page() munlock_page() batch by pagevec

From: Hugh Dickins
Date: Wed Feb 09 2022 - 23:50:06 EST


On Wed, 9 Feb 2022, Naresh Kamboju wrote:
> The following build regression noticed while building Linux next 20220209
> arm/riscv/sh of allnoconfig and tinyconfig builds failed with gcc-10,
> gcc-11 and clang-13.
>
> clang: warning: argument unused during compilation: '-march=armv7-m'
> [-Wunused-command-line-argument]
> mm/swap.c:637:2: error: implicit declaration of function
> 'mlock_page_drain' [-Werror,-Wimplicit-function-declaration]
> mlock_page_drain(cpu);
> ^
> 1 error generated.
> make[2]: *** [scripts/Makefile.build:289: mm/swap.o] Error 1
>
> Reported-by: Linux Kernel Functional Testing <lkft@xxxxxxxxxx>

Thanks Naresh, Geert had already reported, and SeongJae sent a fix in

https://lore.kernel.org/lkml/20220209094158.21941-2-sj@xxxxxxxxxx/

Turns out that a !CONFIG_MMU CONFIG_SMP config will need one more stub,
I just sent a v2 update to SJ's patch in that thread.

Hugh