On 04/17/2018 09:00 AM, Mike Galbraith wrote: > On Tue, 2018-04-17 at 17:31 +0200, Borislav Petkov wrote: >> On Tue, Apr 17, 2018 at 05:21:30PM +0200, Jörg Otte wrote: >>> finished bisection. >>> 39114b7a743e6759bab4d96b7d9651d44d17e3f9 is the first bad commit >>> (x86/pti: Never implicitly clear _PAGE_GLOBAL for kernel image). >> >> Looks like you're not the only one: >> >> http://marc.info/?i=20180417150130.ga11...@ak-laptop.emea.nsn-net.net > > I'm hitting this too, but only with PREEMPT_RT. I put a bandaid on it > (tell pti_kernel_image_global_ok() to return true for PREEMPT_RT) while > waiting to see if it was really really as non-rt as it appeared to be.
It looks like pti_init() is too early for change_page_attr()/set_memory_nonglobal() because they look for irqs_off(). This *should* be OK in practice because we only need to flush the boot CPU, not the others. That's what ends up causing the BUG_ON(). But, there's apparently something else going on too because things don't boot even with that BUG_ON() backed out. The good news is that its easy to reproduce.