[PATCH 1/2] x86/fred: enable FRED by default

From: H. Peter Anvin

Date: Mon Mar 23 2026 - 16:37:51 EST


When FRED was added to the mainline kernel, it was set up as an
explicit opt-in due to the risk of regressions before hardware was
available publicly.

Now, Panther Lake (Core Ultra 300 series) has been released, and
benchmarking by Phoronix has shown that it provides a significant
performance benefit on most workloads:

https://www.phoronix.com/review/intel-fred-panther-lake

Accordingly, enable FRED by default if the CPU supports it. FRED can
of course still be disabled via the fred=off command line option.

Signed-off-by: H. Peter Anvin (Intel) <hpa@xxxxxxxxx>
---
Documentation/admin-guide/kernel-parameters.txt | 4 ++--
arch/x86/kernel/cpu/common.c | 2 +-
2 files changed, 3 insertions(+), 3 deletions(-)

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.
+ off: disable FRED.

ftrace=[tracer]
[FTRACE] will set and start the specified tracer
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);

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