From: Breno Leitao <leitao@debian.org>
To: Borislav Petkov <bp@alien8.de>, mingo@kernel.org, jpoimboe@kernel.org
Cc: Ingo Molnar <mingo@kernel.org>,
Josh Poimboeuf <jpoimboe@kernel.org>,
tglx@linutronix.de, Ingo Molnar <mingo@redhat.com>,
Dave Hansen <dave.hansen@linux.intel.com>,
x86@kernel.org, "H. Peter Anvin" <hpa@zytor.com>,
Peter Zijlstra <peterz@infradead.org>,
Pawan Gupta <pawan.kumar.gupta@linux.intel.com>,
leit@meta.com,
"open list:X86 ARCHITECTURE (32-BIT AND 64-BIT)"
<linux-kernel@vger.kernel.org>,
Linus Torvalds <torvalds@linux-foundation.org>,
gustavold@meta.com
Subject: Re: [PATCH v4] x86/bugs: Add a separate config for each mitigation
Date: Tue, 17 Oct 2023 08:08:15 -0700 [thread overview]
Message-ID: <ZS6jX9v+QBsKyavE@gmail.com> (raw)
In-Reply-To: <20231016124654.GDZS0wvqJlsf+iVAeu@fat_crate.local>
On Mon, Oct 16, 2023 at 02:46:54PM +0200, Borislav Petkov wrote:
> IOW, I don't see the particular reason for having those namespaced. But
> since you and Josh care so much and I don't - not that much :-) - and
> I definitely won't be doing the work, feel free.
Thanks for all the discussion so far.
I am summarizing what I got from this discussion so far, and
starting to get the direction on where we want to be:
0) Each mitigation should have their own Kconfig entry under
SPECULATION_MITIGATIONS.
1) Have "Mitigation" namespace for each mitigation. These are the new
name for the mitigations:
* MITIGATION_PAGE_TABLE_ISOLATION
* MITIGATION_RETPOLINE
* MITIGATION_UNRET_ENTRY
* MITIGATION_CALL_DEPTH_TRACKING
* MITIGATION_IBPB_ENTRY
* MITIGATION_IBRS_ENTRY
* MITIGATION_SRSO
* MITIGATION_SLS
2) Split the GDS mitigation in two:
* MITIGATION_GDS
* MITIGATION_GDS_FORCE
3) Create new Kconfigs for the following missing mitigations:
* MITIGATION_MDS
* MITIGATION_TAA
* MITIGATION_MMIO_STALE_DATA
* MITIGATION_L1TF
* MITIGATION_RETBLEED
* MITIGATION_SPECTRE_V1
* MITIGATION_SPECTRE_V2
* MITIGATION_SRBDS
* MITIGATION_SSB
4) Do no touch the enum order, instead use the something as the code
below to avoid the #ifdefs in the code:
static enum retbleed_mitigation_cmd retbleed_cmd __ro_after_init =
IS_ENABLED(CONFIG_MITIGATION_RETBLEED) ? RETBLEED_CMD_AUTO : RETBLEED_CMD_OFF;
5) Make sure that there is clear messages when the mitigations are
disabled. i.e, make sure that the current pr_info() we have today are
called in case the mitigation is disabled.
Am I missing something?
next prev parent reply other threads:[~2023-10-17 15:08 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-10-10 10:30 [PATCH v4] x86/bugs: Add a separate config for each mitigation Breno Leitao
2023-10-11 4:42 ` Josh Poimboeuf
2023-10-11 12:20 ` Breno Leitao
2023-10-11 16:49 ` Josh Poimboeuf
2023-10-11 19:03 ` Borislav Petkov
2023-10-11 22:03 ` Josh Poimboeuf
2023-10-12 7:29 ` Borislav Petkov
2023-10-12 16:48 ` Josh Poimboeuf
2023-10-15 15:06 ` Borislav Petkov
2023-10-16 10:07 ` Ingo Molnar
2023-10-16 12:46 ` Borislav Petkov
2023-10-17 15:08 ` Breno Leitao [this message]
2023-10-11 21:59 ` Ingo Molnar
2023-10-12 13:02 ` Breno Leitao
2023-10-12 17:05 ` Josh Poimboeuf
2023-10-12 18:51 ` Ingo Molnar
2023-10-12 20:43 ` Josh Poimboeuf
2023-10-13 10:50 ` Ingo Molnar
2023-10-15 14:11 ` Josh Poimboeuf
2023-10-16 9:45 ` Ingo Molnar
2023-10-17 17:15 ` Josh Poimboeuf
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=ZS6jX9v+QBsKyavE@gmail.com \
--to=leitao@debian.org \
--cc=bp@alien8.de \
--cc=dave.hansen@linux.intel.com \
--cc=gustavold@meta.com \
--cc=hpa@zytor.com \
--cc=jpoimboe@kernel.org \
--cc=leit@meta.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@kernel.org \
--cc=mingo@redhat.com \
--cc=pawan.kumar.gupta@linux.intel.com \
--cc=peterz@infradead.org \
--cc=tglx@linutronix.de \
--cc=torvalds@linux-foundation.org \
--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