[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20200805050808.GC9127@nazgul.tnic>
Date: Wed, 5 Aug 2020 07:08:08 +0200
From: Borislav Petkov <bp@...en8.de>
To: hpa@...or.com
Cc: Borislav Petkov <bp@...e.de>,
Ricardo Neri <ricardo.neri-calderon@...ux.intel.com>,
Thomas Gleixner <tglx@...utronix.de>,
Ingo Molnar <mingo@...nel.org>,
Andy Lutomirski <luto@...nel.org>, x86@...nel.org,
"Peter Zijlstra (Intel)" <peterz@...radead.org>,
Dave Hansen <dave.hansen@...el.com>,
Tony Luck <tony.luck@...el.com>,
Cathy Zhang <cathy.zhang@...el.com>,
Fenghua Yu <fenghua.yu@...el.com>,
Kyung Min Park <kyung.min.park@...el.com>,
"Ravi V. Shankar" <ravi.v.shankar@...el.com>,
Sean Christopherson <sean.j.christopherson@...el.com>,
linux-kernel@...r.kernel.org,
Ricardo Neri <ricardo.neri@...el.com>,
Dave Hansen <dave.hansen@...ux.intel.com>,
linux-edac@...r.kernel.org
Subject: Re: [PATCH v2] x86/cpu: Use SERIALIZE in sync_core() when available
On Tue, Aug 04, 2020 at 09:58:25PM -0700, hpa@...or.com wrote:
> Because why use an alternative to jump over one instruction?
>
> I personally would prefer to have the IRET put out of line
Can't yet - SERIALIZE CPUs are a minority at the moment.
> and have the call/jmp replaced by SERIALIZE inline.
Well, we could do:
alternative_io("... IRET bunch", __ASM_SERIALIZE, X86_FEATURE_SERIALIZE, ...);
and avoid all kinds of jumping. Alternatives get padded so there
would be a couple of NOPs following when SERIALIZE gets patched in
but it shouldn't be a problem. I guess one needs to look at what gcc
generates...
--
Regards/Gruss,
Boris.
https://people.kernel.org/tglx/notes-about-netiquette
Powered by blists - more mailing lists