public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Borislav Petkov <bp@alien8.de>
To: "Luck, Tony" <tony.luck@intel.com>
Cc: Daniel Verkamp <dverkamp@chromium.org>,
	"x86@kernel.org" <x86@kernel.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	Andrew Cooper <andrew.cooper3@citrix.com>
Subject: Re: [PATCH] x86: also disable FSRM if ERMS is disabled
Date: Tue, 11 Oct 2022 19:52:53 +0200	[thread overview]
Message-ID: <Y0WtdarNtdIXCuhC@zn.tnic> (raw)
In-Reply-To: <SJ1PR11MB6083203F6D6EFF8E562A2593FC239@SJ1PR11MB6083.namprd11.prod.outlook.com>

On Tue, Oct 11, 2022 at 05:09:19PM +0000, Luck, Tony wrote:
> >> The Intel SDM says: "Software can disable fast-string operation by
> >> clearing the fast-string-enable bit (bit 0) of IA32_MISC_ENABLE MSR",
> >> so it's not an invalid configuration for this bit to be unset.
> >
> > Dunno, did Intel folks think about clearing the respective CPUID bits
> > when exposing IA32_MISC_ENABLE[0] to software? Tony?
> 
> I don't know if it was thought about. Experimentally clearing bit
> 0 of IA32_MISC_ENABLE does not affect the CPUID bit settings
> for either ERMS or FSRM (on the one system I tried that supports
> both of these bits).

Confirms my observation on a Coffeelake here too.

Oh well, probably not that important. I mean, I bet luserspace is
looking at those CPUID bits - glibc probably - and then probably selects
the proper memcpy or so routine, based on what's there.

If something clears MSR_IA32_MISC_ENABLE_FAST_STRING_BIT and we go and
clear our feature flags and luserspace still queries CPUID then oh well,
it'll be fun. It all depends on why something has cleared them tho. It
could be some performance thing or something a lot more funky. I guess
if stuff starts exploding left and right, there will soon be a microcode
patch after that. :-)

Might be prudent to check with hw folks just in case...

Thx.

-- 
Regards/Gruss,
    Boris.

https://people.kernel.org/tglx/notes-about-netiquette

  reply	other threads:[~2022-10-11 17:53 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-09-23  0:58 [PATCH] x86: also disable FSRM if ERMS is disabled Daniel Verkamp
2022-09-23 11:13 ` Borislav Petkov
2022-09-23 17:25   ` Daniel Verkamp
2022-09-23 17:51     ` Borislav Petkov
2022-10-07 18:08       ` Daniel Verkamp
2022-10-11 11:28         ` Borislav Petkov
2022-10-11 17:09           ` Luck, Tony
2022-10-11 17:52             ` Borislav Petkov [this message]
2022-10-11 19:08               ` Luck, Tony
2022-10-11 20:56                 ` Borislav Petkov
2022-10-11 22:19                   ` Luck, Tony
2022-10-11 22:59                     ` Andrew Cooper
2023-01-04  7:43         ` Jiri Slaby
2023-01-04 11:39           ` Borislav Petkov
2023-01-14  9:19             ` Ingo Molnar
2023-01-14  9:58               ` Borislav Petkov
2023-01-16  5:26             ` Jiri Slaby
2023-01-16 21:17               ` 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=Y0WtdarNtdIXCuhC@zn.tnic \
    --to=bp@alien8.de \
    --cc=andrew.cooper3@citrix.com \
    --cc=dverkamp@chromium.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=tony.luck@intel.com \
    --cc=x86@kernel.org \
    /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