[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20200403164244.GZ20730@hirez.programming.kicks-ass.net>
Date: Fri, 3 Apr 2020 18:42:44 +0200
From: Peter Zijlstra <peterz@...radead.org>
To: Sean Christopherson <sean.j.christopherson@...el.com>
Cc: Thomas Gleixner <tglx@...utronix.de>,
Ingo Molnar <mingo@...hat.com>, Borislav Petkov <bp@...en8.de>,
x86@...nel.org, "H. Peter Anvin" <hpa@...or.com>,
linux-kernel@...r.kernel.org,
"Kenneth R. Crudup" <kenny@...ix.com>,
Jessica Yu <jeyu@...nel.org>,
Rasmus Villemoes <rasmus.villemoes@...vas.dk>,
Paolo Bonzini <pbonzini@...hat.com>,
Fenghua Yu <fenghua.yu@...el.com>,
Xiaoyao Li <xiaoyao.li@...el.com>,
Nadav Amit <nadav.amit@...il.com>,
Thomas Hellstrom <thellstrom@...are.com>,
Tony Luck <tony.luck@...el.com>,
Steven Rostedt <rostedt@...dmis.org>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Jann Horn <jannh@...gle.com>,
Kees Cook <keescook@...omium.org>,
David Laight <David.Laight@...LAB.COM>,
Doug Covelli <dcovelli@...are.com>
Subject: Re: [RFC PATCH] x86/split_lock: Disable SLD if an unaware
(out-of-tree) module enables VMX
On Fri, Apr 03, 2020 at 09:30:07AM -0700, Sean Christopherson wrote:
> Hook into native CR4 writes to disable split-lock detection if CR4.VMXE
> is toggled on by an SDL-unaware entity, e.g. an out-of-tree hypervisor
> module. Most/all VMX-based hypervisors blindly reflect #AC exceptions
> into the guest, or don't intercept #AC in the first place. With SLD
> enabled, this results in unexpected #AC faults in the guest, leading to
> crashes in the guest and other undesirable behavior.
>
> Reported-by: "Kenneth R. Crudup" <kenny@...ix.com>
> Cc: Peter Zijlstra <peterz@...radead.org>
> Cc: Thomas Gleixner <tglx@...utronix.de>
> Cc: Jessica Yu <jeyu@...nel.org>
> Cc: Rasmus Villemoes <rasmus.villemoes@...vas.dk>
> Cc: Kenneth R. Crudup <kenny@...ix.com>
> Cc: Paolo Bonzini <pbonzini@...hat.com>
> Cc: Fenghua Yu <fenghua.yu@...el.com>
> Cc: Xiaoyao Li <xiaoyao.li@...el.com>
> Cc: Nadav Amit <namit@...are.com>
> Cc: Thomas Hellstrom <thellstrom@...are.com>
> Cc: Tony Luck <tony.luck@...el.com>
> Cc: Steven Rostedt <rostedt@...dmis.org>
> Cc: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
> Cc: Jann Horn <jannh@...gle.com>
> Cc: Kees Cook <keescook@...omium.org>
> Cc: David Laight <David.Laight@...LAB.COM>
> Cc: Doug Covelli <dcovelli@...are.com>
> Signed-off-by: Sean Christopherson <sean.j.christopherson@...el.com>
> ---
>
> A bit ugly, but on the plus side the code is largely contained to intel.c.
> I think forgoing the on_all_cpus() remote kill is safe?
How would it be safe? You can't control where the module text will be
ran, or how quickly.
Powered by blists - more mailing lists