x86/mce: Unify pr_* prefix
authorBorislav Petkov <bp@suse.de>
Wed, 5 Dec 2018 20:05:13 +0000 (21:05 +0100)
committerBorislav Petkov <bp@suse.de>
Thu, 6 Dec 2018 11:04:52 +0000 (12:04 +0100)
Move the pr_fmt prefix to internal.h and include it everywhere. This
way, all pr_* printed strings will be prepended with "mce: ".

No functional changes.

Signed-off-by: Borislav Petkov <bp@suse.de>
Cc: Tony Luck <tony.luck@intel.com>
Link: https://lkml.kernel.org/r/20181205200913.GR29510@zn.tnic
arch/x86/kernel/cpu/mce/core.c
arch/x86/kernel/cpu/mce/dev-mcelog.c
arch/x86/kernel/cpu/mce/internal.h
arch/x86/kernel/cpu/mce/p5.c
arch/x86/kernel/cpu/mce/therm_throt.c
arch/x86/kernel/cpu/mce/threshold.c
arch/x86/kernel/cpu/mce/winchip.c

index b0ae12cf7827f993aaaef78614209ba820fee9fc..ad8f62a0c706a9c7674777c3491c6fd61cd99e3d 100644 (file)
@@ -8,8 +8,6 @@
  * Author: Andi Kleen
  */
 
-#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
-
 #include <linux/thread_info.h>
 #include <linux/capability.h>
 #include <linux/miscdevice.h>
index 41d9169d27fa27f9638cef651e4ccd2a9284c342..9690ec5c80515f73a2a3705b23f673574fe035e4 100644 (file)
@@ -8,8 +8,6 @@
  * Author: Andi Kleen
  */
 
-#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
-
 #include <linux/miscdevice.h>
 #include <linux/slab.h>
 #include <linux/kmod.h>
index ceb67cd5918ff4b0b5dbce93fa1f3a36670084bc..af5eab1e65e2707416ecab9e179c3255ec1320a3 100644 (file)
@@ -2,6 +2,9 @@
 #ifndef __X86_MCE_INTERNAL_H__
 #define __X86_MCE_INTERNAL_H__
 
+#undef pr_fmt
+#define pr_fmt(fmt) "mce: " fmt
+
 #include <linux/device.h>
 #include <asm/mce.h>
 
index 5cddf831720fd321b01a7393b8c678d635b46e4b..4ae6df556526e56a70db8dd41c004541d7fe6008 100644 (file)
@@ -14,6 +14,8 @@
 #include <asm/mce.h>
 #include <asm/msr.h>
 
+#include "internal.h"
+
 /* By default disabled */
 int mce_p5_enabled __read_mostly;
 
index 2da67b70ba989821db25e3190a5c68964f9e1c26..df01ff8513a5a2823a6d096c5e2c0fa8ad0ebc80 100644 (file)
@@ -30,6 +30,8 @@
 #include <asm/msr.h>
 #include <asm/trace/irq_vectors.h>
 
+#include "internal.h"
+
 /* How long to wait between reporting thermal events */
 #define CHECK_INTERVAL         (300 * HZ)
 
index 2b584b319eff37532df8c8729fc520725bee5c29..10586a85c23f08030f0c2262fe47bf5a572023b4 100644 (file)
@@ -10,6 +10,8 @@
 #include <asm/mce.h>
 #include <asm/trace/irq_vectors.h>
 
+#include "internal.h"
+
 static void default_threshold_interrupt(void)
 {
        pr_err("Unexpected threshold interrupt at vector %x\n",
index 3b45b270a865d1658648667451f4b57fede21f26..a30ea13cccc2611148f6df52149abb712fd9107c 100644 (file)
@@ -13,6 +13,8 @@
 #include <asm/mce.h>
 #include <asm/msr.h>
 
+#include "internal.h"
+
 /* Machine check handler for WinChip C6: */
 static void winchip_machine_check(struct pt_regs *regs, long error_code)
 {