x86/efi: Preface all print statements with efi* tag
authorMatt Fleming <matt@codeblueprint.co.uk>
Sun, 25 Oct 2015 10:26:35 +0000 (10:26 +0000)
committerMatt Fleming <matt@codeblueprint.co.uk>
Mon, 14 Dec 2015 15:24:03 +0000 (15:24 +0000)
The pr_*() calls in the x86 EFI code may or may not include a
subsystem tag, which makes it difficult to grep the kernel log for all
relevant EFI messages and leads users to miss important information.

Recently, a bug reporter provided all the EFI print messages from the
kernel log when trying to diagnose an issue but missed the following
statement because it wasn't prefixed with anything indicating it was
related to EFI,

  pr_err("Error ident-mapping new memmap (0x%lx)!\n", pa_memmap);

Cc: Borislav Petkov <bp@suse.de>
Reviewed-by: Josh Triplett <josh@joshtriplett.org>
Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk>
arch/x86/platform/efi/efi-bgrt.c
arch/x86/platform/efi/efi_64.c
arch/x86/platform/efi/quirks.c

index ea48449b2e63d1428de814d654ba58087dee436a..9a52b5c4438f70d3342d64319f54c5d6a1e09d5b 100644 (file)
@@ -10,6 +10,9 @@
  * it under the terms of the GNU General Public License version 2 as
  * published by the Free Software Foundation.
  */
+
+#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
 #include <linux/kernel.h>
 #include <linux/init.h>
 #include <linux/acpi.h>
index a0ac0f9c307f661c8b3ed08c4ca6d23507772e36..d347e854a5e454ac614f8139e62f1267efbae86c 100644 (file)
@@ -15,6 +15,8 @@
  *
  */
 
+#define pr_fmt(fmt) "efi: " fmt
+
 #include <linux/kernel.h>
 #include <linux/init.h>
 #include <linux/mm.h>
index 1c7380da65ffab641f0cb0aedc88cb7ef7e8f6cc..6452070f3025273661d0f49f5d6d1c3199e65cc3 100644 (file)
@@ -1,3 +1,5 @@
+#define pr_fmt(fmt) "efi: " fmt
+
 #include <linux/init.h>
 #include <linux/kernel.h>
 #include <linux/string.h>
@@ -256,7 +258,7 @@ void __init efi_apply_memmap_quirks(void)
         * services.
         */
        if (!efi_runtime_supported()) {
-               pr_info("efi: Setup done, disabling due to 32/64-bit mismatch\n");
+               pr_info("Setup done, disabling due to 32/64-bit mismatch\n");
                efi_unmap_memmap();
        }
 
This page took 0.0288 seconds and 5 git commands to generate.