summaryrefslogtreecommitdiff
path: root/arch/x86/include/asm/extable.h
diff options
context:
space:
mode:
authorPeter Zijlstra <peterz@infradead.org>2017-06-12 14:52:46 +0300
committerThomas Gleixner <tglx@linutronix.de>2017-06-12 22:17:48 +0300
commit8a524f803a3e0290cdba6d373361b2cef9752934 (patch)
tree6de661f3898c330e2f7c418dae74e7363951d544 /arch/x86/include/asm/extable.h
parent32c1431eea4881a6b17bd7c639315010aeefa452 (diff)
downloadlinux-8a524f803a3e0290cdba6d373361b2cef9752934.tar.xz
x86/debug: Handle early WARN_ONs proper
Hans managed to trigger a WARN very early in the boot which killed his (Virtual) box. The reason is that the recent rework of WARN() to use UD0 forgot to add the fixup_bug() call to early_fixup_exception(). As a result the kernel does not handle the WARN_ON injected UD0 exception and panics. Add the missing fixup call, so early UD's injected by WARN() get handled. Fixes: 9a93848fe787 ("x86/debug: Implement __WARN() using UD0") Reported-and-tested-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Frank Mehnert <frank.mehnert@oracle.com> Cc: Hans de Goede <hdegoede@redhat.com> Cc: Michael Thayer <michael.thayer@oracle.com> Link: http://lkml.kernel.org/r/20170612180108.w4vgu2ckucmllf3a@hirez.programming.kicks-ass.net
Diffstat (limited to 'arch/x86/include/asm/extable.h')
-rw-r--r--arch/x86/include/asm/extable.h1
1 files changed, 1 insertions, 0 deletions
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);