From: Miaohe Lin <linmiaohe@huawei.com>
To: Zheng Bin <zhengbin13@huawei.com>, <naoya.horiguchi@nec.com>,
<akpm@linux-foundation.org>
Cc: <gaochao49@huawei.com>, <linux-mm@kvack.org>,
<linux-kernel@vger.kernel.org>
Subject: Re: [PATCH -next] mm/memory-failure: fix redefinition of mf_generic_kill_procs
Date: Wed, 29 Jun 2022 10:56:00 +0800 [thread overview]
Message-ID: <3e3691cc-c29e-78be-eeff-56ecb6753182@huawei.com> (raw)
In-Reply-To: <20220628112143.1170473-1-zhengbin13@huawei.com>
On 2022/6/28 19:21, Zheng Bin wrote:
> If CONFIG_HUGETLB_PAGE=n, building fails:
>
> mm/memory-failure.c:1805:19: error: redefinition of ‘mf_generic_kill_procs’
> static inline int mf_generic_kill_procs(unsigned long long pfn, int flags,
> ^~~~~~~~~~~~~~~~~~~~~
> mm/memory-failure.c:1564:12: note: previous definition of ‘mf_generic_kill_procs’ was here
> static int mf_generic_kill_procs(unsigned long long pfn, int flags,
>
> This patch fixes that.
>
> Fixes: 4184e8d7d056 ("mm-factor-helpers-for-memory_failure_dev_pagemap-fix")
> Signed-off-by: Zheng Bin <zhengbin13@huawei.com>
Thanks for fixing this. mf_generic_kill_procs shouldn't depend on CONFIG_HUGETLB_PAGE.
Reviewed-by: Miaohe Lin <linmiaohe@huawei.com>
BTW: It seems there is a mess between CONFIG_HUGETLB_PAGE and CONFIG_FS_DAX. It's better
to fix it later.
> ---
> mm/memory-failure.c | 7 -------
> 1 file changed, 7 deletions(-)
>
> diff --git a/mm/memory-failure.c b/mm/memory-failure.c
> index 001fead45f30..c9931c676335 100644
> --- a/mm/memory-failure.c
> +++ b/mm/memory-failure.c
> @@ -1801,13 +1801,6 @@ static int try_memory_failure_hugetlb(unsigned long pfn, int flags, int *hugetlb
> }
>
> #else
> -
> -static inline int mf_generic_kill_procs(unsigned long long pfn, int flags,
> - struct dev_pagemap *pgmap)
> -{
> - return 0;
> -}
> -
> static inline int try_memory_failure_hugetlb(unsigned long pfn, int flags, int *hugetlb)
> {
> return 0;
> --
> 2.31.1
>
> .
>
prev parent reply other threads:[~2022-06-29 2:56 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-06-28 11:21 Zheng Bin
2022-06-29 2:56 ` Miaohe Lin [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=3e3691cc-c29e-78be-eeff-56ecb6753182@huawei.com \
--to=linmiaohe@huawei.com \
--cc=akpm@linux-foundation.org \
--cc=gaochao49@huawei.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=naoya.horiguchi@nec.com \
--cc=zhengbin13@huawei.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox