LKML Archive on
help / color / mirror / Atom feed
From: Jason Baron <>
To: Jan Engelhardt <>
Cc: Joe Perches <>,,,,,
Subject: Re: [patch 0/4] make pr_debug() dynamic
Date: Mon, 11 Feb 2008 11:38:32 -0500	[thread overview]
Message-ID: <> (raw)
In-Reply-To: <Pine.LNX.4.64.0802092320380.6917@fbirervta.pbzchgretzou.qr>

On Sat, Feb 09, 2008 at 11:21:58PM +0100, Jan Engelhardt wrote:
> >> 
> >> What's wrong with klogd -c 8 or equivalent?
> >
> >Setting the loglevel higher, will not make pr_debug() calls visible. The only
> >way to make them visible right now, is by re-compiling the kernel.
> pr_debug() was IMHO meant to be a compile-time optimization
> to throw out debug messages most people do not want.
> If you want to switch on/off debugging messages, use
> printk(KERN_DEBUG) [with klogd -c something] and not pr_debug!

true, we could turn pr_debug() calls into printk(KERN_DEBUG) calls, but there
is an overhead to all these extra printk functions calls. The way I have
implemented pr_debug(), there is no function call at all, in the off case.
To me pr_debug() is currently a compile option, b/c there is often a lot of
overhead to having it on. Being able to turn pr_debug() calls off/on in a
production environment, to get debugging data seems very valuable.



      reply	other threads:[~2008-02-11 16:41 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-02-07 21:03 Jason Baron
2008-02-07 22:42 ` Joe Perches
2008-02-08 15:52   ` Jason Baron
2008-02-09 22:21     ` Jan Engelhardt
2008-02-11 16:38       ` Jason Baron [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \ \ \ \ \ \ \ \ \ \
    --subject='Re: [patch 0/4] make pr_debug() dynamic' \

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).