From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754529AbdFLQv2 (ORCPT ); Mon, 12 Jun 2017 12:51:28 -0400 Received: from mx1.redhat.com ([209.132.183.28]:40054 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753884AbdFLQvZ (ORCPT ); Mon, 12 Jun 2017 12:51:25 -0400 DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 5E80181247 Authentication-Results: ext-mx01.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com Authentication-Results: ext-mx01.extmail.prod.ext.phx2.redhat.com; spf=pass smtp.mailfrom=hdegoede@redhat.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com 5E80181247 Subject: Re: 4.12 REGRESSION, 4.12 does not boot as VirtualBox guest To: Peter Zijlstra , Thomas Gleixner Cc: Linus Torvalds , Ingo Molnar , Linux Kernel Mailing List , the arch/x86 maintainers , Frank Mehnert , Michael Thayer References: <20170612115246.lbj23umwaycztvb6@hirez.programming.kicks-ass.net> From: Hans de Goede Message-ID: Date: Mon, 12 Jun 2017 18:51:17 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.1.0 MIME-Version: 1.0 In-Reply-To: <20170612115246.lbj23umwaycztvb6@hirez.programming.kicks-ass.net> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.25]); Mon, 12 Jun 2017 16:51:20 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi, On 12-06-17 13:52, Peter Zijlstra wrote: > On Mon, Jun 12, 2017 at 10:16:53AM +0200, Thomas Gleixner wrote: >> On Sat, 10 Jun 2017, Linus Torvalds wrote: >> >>> On Fri, Jun 9, 2017 at 3:33 AM, Hans de Goede wrote: >>>> >>>> Sorry for escalating this right up to you, but this issue >>>> does not seem to be getting any attention and I'm not sure >>>> which subsys maintainer to poke about this. >>> >>> Looks like x86. Added people. >>> >>>> The problem is that the 4.12-rc# kernels fail to boot on >>>> VirtualBox guests hosted on any machine with a Sky Lake >>>> (and probably also a Kaby Lake) CPU, for details see: >>>> >>>> https://bugzilla.kernel.org/show_bug.cgi?id=195961 >> >> Looks like the WARN/BUG rework. Peter???? > > I wasn't aware we'd call WARN _that_ early. Does something like so make > it work? Yes it does, with this patch the oops is back (unrelated problem) and the kernel boots again :) You can add my: Tested-by: Hans de Goede Regards, Hans > > --- > arch/x86/include/asm/extable.h | 1 + > arch/x86/kernel/traps.c | 2 +- > arch/x86/mm/extable.c | 3 +++ > 3 files changed, 5 insertions(+), 1 deletion(-) > > diff --git a/arch/x86/include/asm/extable.h b/arch/x86/include/asm/extable.h > index b8ad261d11dc..c66d19e3c23e 100644 > --- a/arch/x86/include/asm/extable.h > +++ b/arch/x86/include/asm/extable.h > @@ -29,6 +29,7 @@ struct pt_regs; > } while (0) > > extern int fixup_exception(struct pt_regs *regs, int trapnr); > +extern int fixup_bug(struct pt_regs *regs, int trapnr); > extern bool ex_has_fault_handler(unsigned long ip); > extern void early_fixup_exception(struct pt_regs *regs, int trapnr); > > diff --git a/arch/x86/kernel/traps.c b/arch/x86/kernel/traps.c > index 3995d3a777d4..bf54309b85da 100644 > --- a/arch/x86/kernel/traps.c > +++ b/arch/x86/kernel/traps.c > @@ -182,7 +182,7 @@ int is_valid_bugaddr(unsigned long addr) > return ud == INSN_UD0 || ud == INSN_UD2; > } > > -static int fixup_bug(struct pt_regs *regs, int trapnr) > +int fixup_bug(struct pt_regs *regs, int trapnr) > { > if (trapnr != X86_TRAP_UD) > return 0; > diff --git a/arch/x86/mm/extable.c b/arch/x86/mm/extable.c > index 35ea061010a1..0ea8afcb929c 100644 > --- a/arch/x86/mm/extable.c > +++ b/arch/x86/mm/extable.c > @@ -162,6 +162,9 @@ void __init early_fixup_exception(struct pt_regs *regs, int trapnr) > if (fixup_exception(regs, trapnr)) > return; > > + if (fixup_bug(regs, trapnr)) > + return; > + > fail: > early_printk("PANIC: early exception 0x%02x IP %lx:%lx error %lx cr2 0x%lx\n", > (unsigned)trapnr, (unsigned long)regs->cs, regs->ip, >