From: Mark Rutland <mark.rutland@arm.com> To: Pawan Gupta <pawan.kumar.gupta@linux.intel.com> Cc: "Russell King" <linux@armlinux.org.uk>, "Thomas Gleixner" <tglx@linutronix.de>, "Ingo Molnar" <mingo@redhat.com>, "Borislav Petkov" <bp@alien8.de>, "Dave Hansen" <dave.hansen@linux.intel.com>, x86@kernel.org, "H. Peter Anvin" <hpa@zytor.com>, "Kees Cook" <keescook@chromium.org>, "Andrew Morton" <akpm@linux-foundation.org>, "Masahiro Yamada" <masahiroy@kernel.org>, "Peter Zijlstra (Intel)" <peterz@infradead.org>, "Sami Tolvanen" <samitolvanen@google.com>, "Colin Ian King" <colin.king@canonical.com>, "Frederic Weisbecker" <frederic@kernel.org>, "Mike Rapoport" <rppt@kernel.org>, "YiFei Zhu" <yifeifz2@illinois.edu>, "Steven Rostedt (VMware)" <rostedt@goodmis.org>, "Viresh Kumar" <viresh.kumar@linaro.org>, "Andrey Konovalov" <andreyknvl@gmail.com>, "Wang Kefeng" <wangkefeng.wang@huawei.com>, "Uwe Kleine-König" <u.kleine-koenig@pengutronix.de>, "Nathan Chancellor" <nathan@kernel.org>, "Nick Desaulniers" <ndesaulniers@google.com>, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: Re: [PATCH v2 1/2] arch/Kconfig: Make CONFIG_CPU_SPECTRE available for all architectures Date: Thu, 28 Oct 2021 14:49:18 +0100 [thread overview] Message-ID: <20211028134918.GB48435@lakrids.cambridge.arm.com> (raw) In-Reply-To: <232b692cd79e4f6e4c3ee7055b5f02792a28d2c4.1635383031.git.pawan.kumar.gupta@linux.intel.com> On Wed, Oct 27, 2021 at 06:33:22PM -0700, Pawan Gupta wrote: > Borrow CONFIG_CPU_SPECTRE from ARM to be available for all > architectures. This will help in configuration of features that depend > on CPU being affected by spectre class of vulnerabilities. > > Signed-off-by: Pawan Gupta <pawan.kumar.gupta@linux.intel.com> Given that spectre isn't one specific issue, biut rather a blanket term for a bunch of things that can have variable overlap, I don't think this makes much sense unless we're going to add finer-grained options for all the variants, and IMO it'd make more sene for the architectures to directly select the things that'd otherwise be dependent on this. Thanks, Mark. > --- > arch/Kconfig | 3 +++ > arch/arm/mm/Kconfig | 3 --- > arch/x86/Kconfig | 1 + > 3 files changed, 4 insertions(+), 3 deletions(-) > > diff --git a/arch/Kconfig b/arch/Kconfig > index 8df1c7102643..6aa856d51cb7 100644 > --- a/arch/Kconfig > +++ b/arch/Kconfig > @@ -1091,6 +1091,9 @@ config ARCH_SUPPORTS_RT > config CPU_NO_EFFICIENT_FFS > def_bool n > > +config CPU_SPECTRE > + bool > + > config HAVE_ARCH_VMAP_STACK > def_bool n > help > diff --git a/arch/arm/mm/Kconfig b/arch/arm/mm/Kconfig > index 8355c3895894..44551465fd03 100644 > --- a/arch/arm/mm/Kconfig > +++ b/arch/arm/mm/Kconfig > @@ -828,9 +828,6 @@ config CPU_BPREDICT_DISABLE > help > Say Y here to disable branch prediction. If unsure, say N. > > -config CPU_SPECTRE > - bool > - > config HARDEN_BRANCH_PREDICTOR > bool "Harden the branch predictor against aliasing attacks" if EXPERT > depends on CPU_SPECTRE > diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig > index d9830e7e1060..769739da67c6 100644 > --- a/arch/x86/Kconfig > +++ b/arch/x86/Kconfig > @@ -124,6 +124,7 @@ config X86 > select CLKEVT_I8253 > select CLOCKSOURCE_VALIDATE_LAST_CYCLE > select CLOCKSOURCE_WATCHDOG > + select CPU_SPECTRE > select DCACHE_WORD_ACCESS > select EDAC_ATOMIC_SCRUB > select EDAC_SUPPORT > -- > 2.31.1 >
WARNING: multiple messages have this Message-ID (diff)
From: Mark Rutland <mark.rutland@arm.com> To: Pawan Gupta <pawan.kumar.gupta@linux.intel.com> Cc: "Russell King" <linux@armlinux.org.uk>, "Thomas Gleixner" <tglx@linutronix.de>, "Ingo Molnar" <mingo@redhat.com>, "Borislav Petkov" <bp@alien8.de>, "Dave Hansen" <dave.hansen@linux.intel.com>, x86@kernel.org, "H. Peter Anvin" <hpa@zytor.com>, "Kees Cook" <keescook@chromium.org>, "Andrew Morton" <akpm@linux-foundation.org>, "Masahiro Yamada" <masahiroy@kernel.org>, "Peter Zijlstra (Intel)" <peterz@infradead.org>, "Sami Tolvanen" <samitolvanen@google.com>, "Colin Ian King" <colin.king@canonical.com>, "Frederic Weisbecker" <frederic@kernel.org>, "Mike Rapoport" <rppt@kernel.org>, "YiFei Zhu" <yifeifz2@illinois.edu>, "Steven Rostedt (VMware)" <rostedt@goodmis.org>, "Viresh Kumar" <viresh.kumar@linaro.org>, "Andrey Konovalov" <andreyknvl@gmail.com>, "Wang Kefeng" <wangkefeng.wang@huawei.com>, "Uwe Kleine-König" <u.kleine-koenig@pengutronix.de>, "Nathan Chancellor" <nathan@kernel.org>, "Nick Desaulniers" <ndesaulniers@google.com>, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: Re: [PATCH v2 1/2] arch/Kconfig: Make CONFIG_CPU_SPECTRE available for all architectures Date: Thu, 28 Oct 2021 14:49:18 +0100 [thread overview] Message-ID: <20211028134918.GB48435@lakrids.cambridge.arm.com> (raw) In-Reply-To: <232b692cd79e4f6e4c3ee7055b5f02792a28d2c4.1635383031.git.pawan.kumar.gupta@linux.intel.com> On Wed, Oct 27, 2021 at 06:33:22PM -0700, Pawan Gupta wrote: > Borrow CONFIG_CPU_SPECTRE from ARM to be available for all > architectures. This will help in configuration of features that depend > on CPU being affected by spectre class of vulnerabilities. > > Signed-off-by: Pawan Gupta <pawan.kumar.gupta@linux.intel.com> Given that spectre isn't one specific issue, biut rather a blanket term for a bunch of things that can have variable overlap, I don't think this makes much sense unless we're going to add finer-grained options for all the variants, and IMO it'd make more sene for the architectures to directly select the things that'd otherwise be dependent on this. Thanks, Mark. > --- > arch/Kconfig | 3 +++ > arch/arm/mm/Kconfig | 3 --- > arch/x86/Kconfig | 1 + > 3 files changed, 4 insertions(+), 3 deletions(-) > > diff --git a/arch/Kconfig b/arch/Kconfig > index 8df1c7102643..6aa856d51cb7 100644 > --- a/arch/Kconfig > +++ b/arch/Kconfig > @@ -1091,6 +1091,9 @@ config ARCH_SUPPORTS_RT > config CPU_NO_EFFICIENT_FFS > def_bool n > > +config CPU_SPECTRE > + bool > + > config HAVE_ARCH_VMAP_STACK > def_bool n > help > diff --git a/arch/arm/mm/Kconfig b/arch/arm/mm/Kconfig > index 8355c3895894..44551465fd03 100644 > --- a/arch/arm/mm/Kconfig > +++ b/arch/arm/mm/Kconfig > @@ -828,9 +828,6 @@ config CPU_BPREDICT_DISABLE > help > Say Y here to disable branch prediction. If unsure, say N. > > -config CPU_SPECTRE > - bool > - > config HARDEN_BRANCH_PREDICTOR > bool "Harden the branch predictor against aliasing attacks" if EXPERT > depends on CPU_SPECTRE > diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig > index d9830e7e1060..769739da67c6 100644 > --- a/arch/x86/Kconfig > +++ b/arch/x86/Kconfig > @@ -124,6 +124,7 @@ config X86 > select CLKEVT_I8253 > select CLOCKSOURCE_VALIDATE_LAST_CYCLE > select CLOCKSOURCE_WATCHDOG > + select CPU_SPECTRE > select DCACHE_WORD_ACCESS > select EDAC_ATOMIC_SCRUB > select EDAC_SUPPORT > -- > 2.31.1 > _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
next prev parent reply other threads:[~2021-10-28 13:49 UTC|newest] Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top 2021-10-28 1:32 [PATCH ebpf v2 0/2] Unprivileged BPF default Pawan Gupta 2021-10-28 1:33 ` [PATCH v2 1/2] arch/Kconfig: Make CONFIG_CPU_SPECTRE available for all architectures Pawan Gupta 2021-10-28 1:33 ` Pawan Gupta 2021-10-28 5:27 ` Greg KH 2021-10-28 5:27 ` Greg KH 2021-10-28 13:49 ` Mark Rutland [this message] 2021-10-28 13:49 ` Mark Rutland 2021-10-28 19:36 ` Pawan Gupta 2021-10-28 19:36 ` Pawan Gupta 2021-10-29 9:22 ` Mark Rutland 2021-10-29 9:22 ` Mark Rutland 2021-10-29 16:05 ` Daniel Borkmann 2021-10-29 16:05 ` Daniel Borkmann 2021-10-29 19:15 ` Pawan Gupta 2021-10-29 19:15 ` Pawan Gupta 2021-10-29 10:08 ` Russell King (Oracle) 2021-10-29 10:08 ` Russell King (Oracle) 2021-10-29 22:51 ` Pawan Gupta 2021-10-29 22:51 ` Pawan Gupta 2021-10-28 1:35 ` [PATCH ebpf v2 2/2] bpf: Make unprivileged bpf depend on CONFIG_CPU_SPECTRE Pawan Gupta 2021-10-28 5:34 ` Greg KH 2021-10-28 19:38 ` Pawan Gupta 2021-10-28 13:57 ` Mark Rutland 2021-10-28 16:44 ` Greg KH
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=20211028134918.GB48435@lakrids.cambridge.arm.com \ --to=mark.rutland@arm.com \ --cc=akpm@linux-foundation.org \ --cc=andreyknvl@gmail.com \ --cc=bp@alien8.de \ --cc=colin.king@canonical.com \ --cc=dave.hansen@linux.intel.com \ --cc=frederic@kernel.org \ --cc=hpa@zytor.com \ --cc=keescook@chromium.org \ --cc=linux-arm-kernel@lists.infradead.org \ --cc=linux-kernel@vger.kernel.org \ --cc=linux@armlinux.org.uk \ --cc=masahiroy@kernel.org \ --cc=mingo@redhat.com \ --cc=nathan@kernel.org \ --cc=ndesaulniers@google.com \ --cc=pawan.kumar.gupta@linux.intel.com \ --cc=peterz@infradead.org \ --cc=rostedt@goodmis.org \ --cc=rppt@kernel.org \ --cc=samitolvanen@google.com \ --cc=tglx@linutronix.de \ --cc=u.kleine-koenig@pengutronix.de \ --cc=viresh.kumar@linaro.org \ --cc=wangkefeng.wang@huawei.com \ --cc=x86@kernel.org \ --cc=yifeifz2@illinois.edu \ /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: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.