mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Sohil Mehta <sohil.mehta@intel.com>
To: "H. Peter Anvin" <hpa@zytor.com>,
	Thomas Gleixner <tglx@kernel.org>,
	"Ingo Molnar" <mingo@redhat.com>, Borislav Petkov <bp@alien8.de>,
	Dave Hansen <dave.hansen@linux.intel.com>, <x86@kernel.org>
Cc: "Peter Zijlstra (Intel)" <peterz@infradead.org>,
	Kees Cook <kees@kernel.org>, Xin Li <xin@zytor.com>,
	"Ahmed S. Darwish" <darwi@linutronix.de>,
	<linux-kernel@vger.kernel.org>
Subject: Re: [PATCH 0/2] x86/fred: enable FRED by default
Date: Mon, 23 Mar 2026 18:01:09 -0700	[thread overview]
Message-ID: <84489fd4-aa23-4ba1-b5a1-c1baafb6718d@intel.com> (raw)
In-Reply-To: <20260323201510.1537333-1-hpa@zytor.com>

On 3/23/2026 1:15 PM, H. Peter Anvin wrote:

Can we please include this as well?

diff --git a/arch/x86/kernel/fred.c b/arch/x86/kernel/fred.c
index e736b19e18de..117aa06d25ca 100644
--- a/arch/x86/kernel/fred.c
+++ b/arch/x86/kernel/fred.c
@@ -27,9 +27,6 @@ EXPORT_PER_CPU_SYMBOL(fred_rsp0);

 void cpu_init_fred_exceptions(void)
 {
-	/* When FRED is enabled by default, remove this log message */
-	pr_info("Initialize FRED on CPU%d\n", smp_processor_id());
-
 	/*
 	 * If a kernel event is delivered before a CPU goes to user level for
 	 * the first time, its SS is NULL thus NULL is pushed into the SS field


> 
> diff --git a/Documentation/admin-guide/kernel-parameters.txt b/Documentation/admin-guide/kernel-parameters.txt
> index 03a550630644..bfa8a20ccc37 100644
> --- a/Documentation/admin-guide/kernel-parameters.txt
> +++ b/Documentation/admin-guide/kernel-parameters.txt
> @@ -1750,8 +1750,8 @@ Kernel parameters
>  	fred=		[X86-64]
>  			Enable/disable Flexible Return and Event Delivery.
>  			Format: { on | off }
> -			on: enable FRED when it's present.
> -			off: disable FRED, the default setting.
> +			on: enable FRED when it's present, the default setting.

Why do we need the fred=on line after this series? It can't really
enable FRED when the compile option is disabled. Seems like a dead (and
slightly confusing) option to me.

> +			off: disable FRED.
>  
>  	ftrace=[tracer]
>  			[FTRACE] will set and start the specified tracer
> diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig
> index e2df1b147184..876b663dcf38 100644
> --- a/arch/x86/Kconfig
> +++ b/arch/x86/Kconfig
> @@ -557,7 +557,7 @@ config X86_FRED
>  	bool "Flexible Return and Event Delivery"
>  	depends on X86_64
>  	help
> -	  When enabled, try to use Flexible Return and Event Delivery
> +	  When enabled, use Flexible Return and Event Delivery
>  	  instead of the legacy SYSCALL/SYSENTER/IDT architecture for
>  	  ring transitions and exception/interrupt handling if the
>  	  system supports it.
> diff --git a/arch/x86/kernel/cpu/common.c b/arch/x86/kernel/cpu/common.c
> index a8ff4376c286..e22a49869380 100644
> --- a/arch/x86/kernel/cpu/common.c
> +++ b/arch/x86/kernel/cpu/common.c
> @@ -1746,7 +1746,7 @@ static void __init cpu_parse_early_param(void)
>  
>  	/* Minimize the gap between FRED is available and available but disabled. */
>  	arglen = cmdline_find_option(boot_command_line, "fred", arg, sizeof(arg));
> -	if (arglen != 2 || strncmp(arg, "on", 2))
> +	if (arglen > 0 && (arglen != 2 || strncmp(arg, "on", 2)))
>  		setup_clear_cpu_cap(X86_FEATURE_FRED);

Nit: Would it be better to compare with "off" rather than not on?

>  
>  	arglen = cmdline_find_option(boot_command_line, "clearcpuid", arg, sizeof(arg));


  parent reply	other threads:[~2026-03-24  1:01 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-03-23 20:15 H. Peter Anvin
2026-03-23 20:15 ` [PATCH 1/2] " H. Peter Anvin
2026-03-23 20:15 ` [PATCH 2/2] x86/Kconfig: tighten up wording of the CONFIG_X86_FRED help text H. Peter Anvin
2026-03-23 20:24 ` [PATCH 0/2] x86/fred: enable FRED by default Peter Zijlstra
2026-03-24  1:01 ` Sohil Mehta [this message]
2026-03-24  3:05   ` Xin Li
2026-03-24  3:52     ` H. Peter Anvin
2026-03-24  5:08       ` Sohil Mehta
2026-03-24  6:34         ` Sohil Mehta
2026-03-24  7:50         ` H. Peter Anvin
2026-03-24 17:19           ` Sohil Mehta
2026-03-24 19:53             ` Borislav Petkov
2026-03-25 16:22               ` H. Peter Anvin
2026-03-25 16:30                 ` Borislav Petkov
2026-03-25 16:41                   ` H. Peter Anvin
2026-03-25 17:07                   ` Sohil Mehta
2026-03-24 19:50   ` Borislav Petkov

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=84489fd4-aa23-4ba1-b5a1-c1baafb6718d@intel.com \
    --to=sohil.mehta@intel.com \
    --cc=bp@alien8.de \
    --cc=darwi@linutronix.de \
    --cc=dave.hansen@linux.intel.com \
    --cc=hpa@zytor.com \
    --cc=kees@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@redhat.com \
    --cc=peterz@infradead.org \
    --cc=tglx@kernel.org \
    --cc=x86@kernel.org \
    --cc=xin@zytor.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

Powered by JetHome