[Drbd-dev] [PATCH 15/20] drbd: cosmetic: change all printk(level, ...) to pr_<level>(...)
Joe Perches
joe at perches.com
Tue Jul 1 18:30:37 CEST 2014
On Tue, 2014-07-01 at 18:16 +0200, Philipp Reisner wrote:
> From: Lars Ellenberg <lars.ellenberg at linbit.com>
>
> Cosmetic change only.
[]
> diff --git a/drivers/block/drbd/drbd_bitmap.c b/drivers/block/drbd/drbd_bitmap.c
[]
> @@ -353,9 +353,8 @@ static void bm_free_pages(struct page **pages, unsigned long number)
>
> for (i = 0; i < number; i++) {
> if (!pages[i]) {
> - printk(KERN_ALERT "drbd: bm_free_pages tried to free "
> - "a NULL pointer; i=%lu n=%lu\n",
> - i, number);
> + pr_alert("bm_free_pages tried to free a NULL pointer; i=%lu n=%lu\n",
> + i, number);
Cosmetic yes, but these won't be prefixed with "drbd: "
unless there's a #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
somewhere above this and before any other #include.
> diff --git a/drivers/block/drbd/drbd_main.c b/drivers/block/drbd/drbd_main.c
[]
> @@ -26,6 +26,8 @@
>
> */
>
> +#define pr_fmt(fmt) "drbd: " fmt
like this one, though I think KBUILD_MODNAME would be better.
More information about the drbd-dev
mailing list