Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

ACPI: blacklist: Unify the message printing

Intoduce pr_fmt() and use pr_*() macros to replace printk(), to generate
a unified format string for prefix, then remove the PREFIX.

Signed-off-by: Hanjun Guo <guohanjun@huawei.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>

authored by

Hanjun Guo and committed by
Rafael J. Wysocki
007b3e53 606e56c6

+5 -4
+5 -4
drivers/acpi/blacklist.c
··· 10 10 * Copyright (C) 2002 Andy Grover <andrew.grover@intel.com> 11 11 */ 12 12 13 + #define pr_fmt(fmt) "ACPI: " fmt 14 + 13 15 #include <linux/kernel.h> 14 16 #include <linux/init.h> 15 17 #include <linux/acpi.h> ··· 51 49 52 50 i = acpi_match_platform_list(acpi_blacklist); 53 51 if (i >= 0) { 54 - pr_err(PREFIX "Vendor \"%6.6s\" System \"%8.8s\" Revision 0x%x has a known ACPI BIOS problem.\n", 52 + pr_err("Vendor \"%6.6s\" System \"%8.8s\" Revision 0x%x has a known ACPI BIOS problem.\n", 55 53 acpi_blacklist[i].oem_id, 56 54 acpi_blacklist[i].oem_table_id, 57 55 acpi_blacklist[i].oem_revision); 58 56 59 - pr_err(PREFIX "Reason: %s. This is a %s error\n", 57 + pr_err("Reason: %s. This is a %s error\n", 60 58 acpi_blacklist[i].reason, 61 59 (acpi_blacklist[i].data ? 62 60 "non-recoverable" : "recoverable")); ··· 75 73 #ifdef CONFIG_ACPI_REV_OVERRIDE_POSSIBLE 76 74 static int __init dmi_enable_rev_override(const struct dmi_system_id *d) 77 75 { 78 - printk(KERN_NOTICE PREFIX "DMI detected: %s (force ACPI _REV to 5)\n", 79 - d->ident); 76 + pr_notice("DMI detected: %s (force ACPI _REV to 5)\n", d->ident); 80 77 acpi_rev_override_setup(NULL); 81 78 return 0; 82 79 }