lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250522180224.ux4uyexsolnxz47l@desk>
Date: Thu, 22 May 2025 11:02:24 -0700
From: Pawan Gupta <pawan.kumar.gupta@...ux.intel.com>
To: Borislav Petkov <bp@...en8.de>
Cc: x86@...nel.org, David Kaplan <david.kaplan@....com>,
	linux-kernel@...r.kernel.org, "H. Peter Anvin" <hpa@...or.com>,
	Josh Poimboeuf <jpoimboe@...nel.org>
Subject: Re: [PATCH v2 2/7] x86/retbleed: Simplify the =stuff checks

On Thu, May 22, 2025 at 01:42:58PM +0200, Borislav Petkov wrote:
> On Wed, May 21, 2025 at 07:44:37PM -0700, Pawan Gupta wrote:
> > +	if (retbleed_mitigation == RETBLEED_MITIGATION_STUFF &&
> > +	    spectre_v2_enabled != SPECTRE_V2_RETPOLINE) {
> > +		pr_err("WARNING: retbleed=stuff depends on spectre_v2=retpoline\n");
> > +		retbleed_mitigation = RETBLEED_MITIGATION_AUTO;
> 
> What would be the next-best thing fallback for this, short of disabling the
> mitigation?
> 
> UNRET, IBPB?

Next best is IBRS/eIBRS, which also depends on spectre-v2 mitigation. So
NONE is fine here because the next code block will take care of selecting
the right mitigation.

> I would prefer if we look at STUFFing only when SPECTRE_V2_RETPOLINE - i.e.,
> is it even possible.

retbleed_update_mitigation() is the earliest we know that stuffing is
possible (when spectre-v2 has selected the mitigation).

> If not, we fallback to another mitigation which is probably more expensive but
> it is better than NONE...

Covered above.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ