[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <tip-7563421b13da21dd7a947f658b5299e65ed95cbe@git.kernel.org>
Date: Wed, 4 May 2016 00:16:24 -0700
From: tip-bot for Mike Travis <tipbot@...or.com>
To: linux-tip-commits@...r.kernel.org
Cc: len.brown@...el.com, luto@...capital.net, rja@....com,
torvalds@...ux-foundation.org, tglx@...utronix.de,
dvlasenk@...hat.com, hpa@...or.com, linux-kernel@...r.kernel.org,
nzimmer@....com, gfk@....com, peterz@...radead.org, travis@....com,
brgerst@...il.com, sivanich@....com, akpm@...ux-foundation.org,
bp@...en8.de, abanman@....com, estabrook@....com, mingo@...nel.org
Subject: [tip:x86/platform] x86/platform/UV: Add UV MMR Illegal Access
Function
Commit-ID: 7563421b13da21dd7a947f658b5299e65ed95cbe
Gitweb: http://git.kernel.org/tip/7563421b13da21dd7a947f658b5299e65ed95cbe
Author: Mike Travis <travis@....com>
AuthorDate: Fri, 29 Apr 2016 16:54:06 -0500
Committer: Ingo Molnar <mingo@...nel.org>
CommitDate: Wed, 4 May 2016 08:48:47 +0200
x86/platform/UV: Add UV MMR Illegal Access Function
This new function is generated by the UV MMR generation script to
identify MMR registers and fields that are not defined for a specific
UV architecture. With this switch, the immediate panic can be replaced
with a message and a bad return value allowing either hardware or the
emulator to diagnose the problem. It allows functions common to some
UV arches to use common defines that might not be fully defined for all
arches, as long as they do not reference them on the unsupported arches.
Tested-by: John Estabrook <estabrook@....com>
Tested-by: Gary Kroening <gfk@....com>
Tested-by: Nathan Zimmer <nzimmer@....com>
Signed-off-by: Mike Travis <travis@....com>
Reviewed-by: Dimitri Sivanich <sivanich@....com>
Cc: Andrew Banman <abanman@....com>
Cc: Andrew Morton <akpm@...ux-foundation.org>
Cc: Andy Lutomirski <luto@...capital.net>
Cc: Borislav Petkov <bp@...en8.de>
Cc: Brian Gerst <brgerst@...il.com>
Cc: Denys Vlasenko <dvlasenk@...hat.com>
Cc: H. Peter Anvin <hpa@...or.com>
Cc: Len Brown <len.brown@...el.com>
Cc: Linus Torvalds <torvalds@...ux-foundation.org>
Cc: Peter Zijlstra <peterz@...radead.org>
Cc: Russ Anderson <rja@....com>
Cc: Thomas Gleixner <tglx@...utronix.de>
Link: http://lkml.kernel.org/r/20160429215403.231926687@asylum.americas.sgi.com
Signed-off-by: Ingo Molnar <mingo@...nel.org>
---
arch/x86/kernel/apic/x2apic_uv_x.c | 12 ++++++++++++
1 file changed, 12 insertions(+)
diff --git a/arch/x86/kernel/apic/x2apic_uv_x.c b/arch/x86/kernel/apic/x2apic_uv_x.c
index 9086d95..85c3849 100644
--- a/arch/x86/kernel/apic/x2apic_uv_x.c
+++ b/arch/x86/kernel/apic/x2apic_uv_x.c
@@ -55,6 +55,18 @@ EXPORT_SYMBOL_GPL(uv_apicid_hibits);
static struct apic apic_x2apic_uv_x;
+/* Set this to use hardware error handler instead of kernel panic */
+static int disable_uv_undefined_panic = 1;
+unsigned long uv_undefined(char *str)
+{
+ if (likely(!disable_uv_undefined_panic))
+ panic("UV: error: undefined MMR: %s\n", str);
+ else
+ pr_crit("UV: error: undefined MMR: %s\n", str);
+ return ~0ul; /* cause a machine fault */
+}
+EXPORT_SYMBOL(uv_undefined);
+
static unsigned long __init uv_early_read_mmr(unsigned long addr)
{
unsigned long val, *mmr;
Powered by blists - more mailing lists