[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1311647037.24377.7.camel@Joe-Laptop>
Date: Mon, 25 Jul 2011 19:23:57 -0700
From: Joe Perches <joe@...ches.com>
To: Jim Cromie <jim.cromie@...il.com>
Cc: jbaron@...hat.com, bvanassche@....org, gregkh@...e.de,
linux-kernel@...r.kernel.org, gnb@...h.org
Subject: Re: [PATCH 24/25] dynamic_debug: drop pr_fmt() from
dynamic_pr_debug
On Mon, 2011-07-25 at 15:42 -0600, Jim Cromie wrote:
> dynamic_pr_debug can add module, function, file, and line selectively,
> theres no need to also add them via macro. Moreover, adding them
> via the macro, which is useful for pr_info and friends, causes
> pr_debug to double-print those fields added by the flag-settings.
[]
> diff --git a/include/linux/dynamic_debug.h b/include/linux/dynamic_debug.h
[]
> @@ -65,7 +65,7 @@ extern int __dynamic_netdev_dbg(struct _ddebug *descriptor,
> #define dynamic_pr_debug(fmt, ...) do { \
> DYNAMIC_DEBUG_METADATA(fmt); \
> if (unlikely(descriptor.enabled)) \
> - __dynamic_pr_debug(&descriptor, pr_fmt(fmt), ##__VA_ARGS__);\
> + __dynamic_pr_debug(&descriptor, fmt, ##__VA_ARGS__); \
For me, NAK.
I think this isn't a good idea for now.
Maybe in a year or two after all the #define pr_fmt(foo)
are sorted out better.
This is a #define, that is used by all uses of pr_fmt/pr_debug.
This will have problems with uses of pr_fmt that are not
using KBUILD_MODNAME like all uses of:
#define pr_fmt(fmt) KMSG_COMPONENT ": " fmt
and those that use a specific fixed string like:
#define pr_fmt(fmt) "foo: " fmt
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists