Re: more than 50 percent of dmesg belongs only to PCI and USB

From: Michael Ellerman
Date: Sun Mar 15 2009 - 20:59:34 EST


On Sun, 2009-03-15 at 17:39 -0700, Greg KH wrote:
> On Mon, Mar 16, 2009 at 10:28:49AM +1100, Michael Ellerman wrote:
> > On Sat, 2009-03-14 at 13:11 +0530, Jaswinder Singh Rajput wrote:
> > > Can we make dmesg little bit better and remove some noise and put these
> > > debug messages on /sys/kernel/debug/ :
> >
> > I think they should just be KERN_DEBUG, that way they won't be displayed
> > to most users, except people who want to see them.
> >
> > The problem is it's easier to write:
> >
> > dev_info(&dev->dev, "transparent bridge\n");
> >
> > than:
> >
> > dev_printk(KERN_DEBUG, &dev->dev, "transparent bridge\n");
> >
> > and, dev_dbg() does not do what you want in this case.
>
> Why not? It prints it out if you enable the config option at run-time,
> which is what you want.

Only if you have CONFIG_DYNAMIC_PRINTK_DEBUG or whatever it's called
enabled. Which is a terrible idea because it compiles-in all the
pr_debug() and dev_dbg() code that used to be if (0)'ed.

cheers

--
Michael Ellerman
OzLabs, IBM Australia Development Lab

wwweb: http://michael.ellerman.id.au
phone: +61 2 6212 1183 (tie line 70 21183)

We do not inherit the earth from our ancestors,
we borrow it from our children. - S.M.A.R.T Person

Attachment: signature.asc
Description: This is a digitally signed message part