From: Borislav Petkov <bp@alien8.de>
To: luofei <luofei@unicloud.com>
Cc: tony.luck@intel.com, tglx@linutronix.de, mingo@redhat.com,
dave.hansen@linux.intel.com, x86@kernel.org,
naoya.horiguchi@nec.com, akpm@linux-foundation.org,
hpa@zytor.com, gregkh@linuxfoundation.org, rafael@kernel.org,
linux-edac@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-mm@kvack.org
Subject: Re: [PATCH v5 1/2] mm/hwpoison: Avoid the impact of hwpoison_filter() return value on mce handler
Date: Wed, 23 Feb 2022 18:39:38 +0100 [thread overview]
Message-ID: <YhZxWjei2Iw65mAF@zn.tnic> (raw)
In-Reply-To: <20220223082135.2769649-1-luofei@unicloud.com>
On Wed, Feb 23, 2022 at 03:21:35AM -0500, luofei wrote:
> When the hwpoison page meets the filter conditions, it should
> not be regarded as successful memory_failure() processing for
> mce handler, but should return a distinct value, otherwise
> mce handler regards the error page has been identified and
> isolated, which may lead to calling set_mce_nospec() to change
> page attribute, etc.
>
> Here memory_failure() return -EOPNOTSUPP to indicate that the
> error event is filtered, mce handler should not take any action
> for this situation and hwpoison injector should treat as correct.
>
> Signed-off-by: luofei <luofei@unicloud.com>
> ---
> arch/x86/kernel/cpu/mce/core.c | 8 +++++---
> drivers/base/memory.c | 2 ++
> mm/hwpoison-inject.c | 3 ++-
> mm/madvise.c | 2 ++
> mm/memory-failure.c | 9 +++++++--
> 5 files changed, 18 insertions(+), 6 deletions(-)
Much better, thanks.
Acked-by: Borislav Petkov <bp@suse.de>
--
Regards/Gruss,
Boris.
https://people.kernel.org/tglx/notes-about-netiquette
prev parent reply other threads:[~2022-02-23 17:39 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-02-23 8:21 [PATCH v5 1/2] mm/hwpoison: Avoid the impact of hwpoison_filter() return value on mce handler luofei
2022-02-23 17:39 ` Borislav Petkov [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=YhZxWjei2Iw65mAF@zn.tnic \
--to=bp@alien8.de \
--cc=akpm@linux-foundation.org \
--cc=dave.hansen@linux.intel.com \
--cc=gregkh@linuxfoundation.org \
--cc=hpa@zytor.com \
--cc=linux-edac@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=luofei@unicloud.com \
--cc=mingo@redhat.com \
--cc=naoya.horiguchi@nec.com \
--cc=rafael@kernel.org \
--cc=tglx@linutronix.de \
--cc=tony.luck@intel.com \
--cc=x86@kernel.org \
/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