Re: [PATCH v2 2/2] x86/tsx: Get the tsx= command line parameter with early_param()

From: Nikolay Borisov

Date: Tue Oct 07 2025 - 08:50:05 EST




On 26.09.25 г. 21:01 ч., Petr Tesarik wrote:
Use early_param() to get the value of the tsx= command line parameter.
Although cmdline_find_option() works fine, the option is later reported
as unknown and passed to user space. The latter is not a real issue, but
the former is confusing and makes people wonder if the tsx= parameter had
any effect and double-check for typos unnecessarily.

The behavior changes slightly if "tsx" is given without any argument (which
is invalid syntax). Prior to this patch, the kernel logged an error message
and disabled TSX. With this patch, the parameter is ignored. The new
behavior is consistent with other parameters, e.g. "tsx_async_abort".

Signed-off-by: Petr Tesarik <ptesarik@xxxxxxxx>

LGTM, also could you include some rationale why early_param vs __setup for example, or arch_param_cb (which by the way has yet to find its first user).


Reviewed-by: Nikolay Borisov <nik.borisov@xxxxxxxx>