[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20190710134433.GN3402@hirez.programming.kicks-ass.net>
Date: Wed, 10 Jul 2019 15:44:33 +0200
From: Peter Zijlstra <peterz@...radead.org>
To: Xi Ruoyao <xry111@...gyan1223.wang>
Cc: Jiri Kosina <jikos@...nel.org>,
Thomas Gleixner <tglx@...utronix.de>,
Kees Cook <keescook@...omium.org>,
Linus Torvalds <torvalds@...ux-foundation.org>,
Ingo Molnar <mingo@...nel.org>,
Linux List Kernel Mailing <linux-kernel@...r.kernel.org>,
Borislav Petkov <bp@...en8.de>, Len Brown <lenb@...nel.org>,
Andrew Morton <akpm@...ux-foundation.org>,
"Rafael J. Wysocki" <rafael.j.wysocki@...el.com>,
Tony Luck <tony.luck@...el.com>,
Bob Moore <robert.moore@...el.com>,
Erik Schmauss <erik.schmauss@...el.com>,
Josh Poimboeuf <jpoimboe@...hat.com>,
Daniel Bristot de Oliveira <bristot@...hat.com>,
Nadav Amit <namit@...are.com>
Subject: Re: [GIT PULL] x86/topology changes for v5.3
On Wed, Jul 10, 2019 at 09:25:16PM +0800, Xi Ruoyao wrote:
> On 2019-07-10 14:31 +0200, Jiri Kosina wrote:
> > Adding Daniel to check whether this couldn't be some fallout of jumplabel
> > batching.
>
> I don't think so. I tried to revert Daniel's jumplabel batching commits and the
> issue wasn't solved. But reverting Kees' CR0 and CR4 commits can "fix" it
> (apprently).
Xi, could you please try the below instead?
If we mark the key as RO after init, and then try and modify the key to
link module usage sites, things might go bang as described.
Thanks!
diff --git a/arch/x86/kernel/cpu/common.c b/arch/x86/kernel/cpu/common.c
index 27d7864e7252..5bf7a8354da2 100644
--- a/arch/x86/kernel/cpu/common.c
+++ b/arch/x86/kernel/cpu/common.c
@@ -366,7 +366,7 @@ static __always_inline void setup_umip(struct cpuinfo_x86 *c)
cr4_clear_bits(X86_CR4_UMIP);
}
-DEFINE_STATIC_KEY_FALSE_RO(cr_pinning);
+DEFINE_STATIC_KEY_FALSE(cr_pinning);
EXPORT_SYMBOL(cr_pinning);
unsigned long cr4_pinned_bits __ro_after_init;
EXPORT_SYMBOL(cr4_pinned_bits);
Powered by blists - more mailing lists