Patchwork ubifs: make debug messages more silent

login
register
mail settings
Submitter Uwe Kleine-König
Date Aug. 20, 2012, 8:33 a.m.
Message ID <1345451602-22494-1-git-send-email-u.kleine-koenig@pengutronix.de>
Download mbox | patch
Permalink /patch/178701/
State New
Headers show

Comments

Uwe Kleine-König - Aug. 20, 2012, 8:33 a.m.
With pr_debug being used instead of printk(KERN_DEBUG ...) the messages
don't make it into the bootlog without further actions. This saves 32
lines of ubifs messages for me that are not needed most of the time on a
system with / on ubifs.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
---
 fs/ubifs/debug.h |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
Artem Bityutskiy - Aug. 27, 2012, 3:06 p.m.
On Mon, 2012-08-20 at 10:33 +0200, Uwe Kleine-König wrote:
> With pr_debug being used instead of printk(KERN_DEBUG ...) the messages
> don't make it into the bootlog without further actions. This saves 32
> lines of ubifs messages for me that are not needed most of the time on a
> system with / on ubifs.

I've pushed different patches to both UBI and UBIFS - now they print
much less. I've sent you the patches, but I've actually modified them
after sending. If you want to see the last version, let me know. They
are available in the UBI/UBIFS git trees.

Patch

diff --git a/fs/ubifs/debug.h b/fs/ubifs/debug.h
index 8b8cc4e..39828f2 100644
--- a/fs/ubifs/debug.h
+++ b/fs/ubifs/debug.h
@@ -176,7 +176,7 @@  struct ubifs_global_debug_info {
 
 /* Just a debugging messages not related to any specific UBIFS subsystem */
 #define dbg_msg(fmt, ...)                                                      \
-	printk(KERN_DEBUG "UBIFS DBG (pid %d): %s: " fmt "\n", current->pid,   \
+	pr_debug("UBIFS DBG (pid %d): %s: " fmt "\n", current->pid,   \
 	       __func__, ##__VA_ARGS__)
 
 /* General messages */