Re: [PATCH 2/5] x86: efi: convert printk to pr_*()

From: Joe Perches
Date: Wed Jan 04 2012 - 00:26:08 EST


On Tue, 2012-01-03 at 09:11 -0800, Olof Johansson wrote:
> Alright, I guess I'll go through and convert them, even though
> there's no net gain to speak of.

Perhaps it'd be better to add
#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
before any #include and remove PFX from the
formats.

> diff --git a/arch/x86/platform/efi/efi.c b/arch/x86/platform/efi/efi.c
[]
> @@ -254,7 +254,7 @@ int efi_set_rtc_mmss(unsigned long nowtime)
>
> status = efi.get_time(&eft, &cap);
> if (status != EFI_SUCCESS) {
> - printk(KERN_ERR "Oops: efitime: can't read time!\n");
> + pr_err("Oops: efitime: can't read time!\n");

pr_err("Oops: can't read time!\n")
> @@ -367,7 +367,7 @@ static void __init print_efi_memmap(void)
> p < memmap.map_end;
> p += memmap.desc_size, i++) {
> md = p;
> - printk(KERN_INFO PFX "mem%02u: type=%u, attr=0x%llx, "
> + pr_info(PFX "mem%02u: type=%u, attr=0x%llx, "
> "range=[0x%016llx-0x%016llx) (%lluMB)\n",

pr_info("mem%02u: type..."

etc...

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/