From: Jason Baron <jbaron@redhat.com>
To: Jim Cromie <jim.cromie@gmail.com>
Cc: Bart Van Assche <bvanassche@acm.org>,
joe@perches.com, gregkh@suse.de, linux-kernel@vger.kernel.org,
gnb@fmeh.org
Subject: Re: [PATCH 03/25] dynamic_debug: use pr_debug instead of pr_info
Date: Wed, 10 Aug 2011 13:14:15 -0400 [thread overview]
Message-ID: <20110810171415.GA2988@redhat.com> (raw)
In-Reply-To: <CAJfuBxyPtxxCvA4LBx8J+6ADgj1ah4nroM30uYS880pJN+eGxA@mail.gmail.com>
On Wed, Aug 03, 2011 at 01:52:33PM -0600, Jim Cromie wrote:
> On Wed, Aug 3, 2011 at 12:27 PM, Jason Baron <jbaron@redhat.com> wrote:
> > On Thu, Jul 28, 2011 at 03:15:35PM -0600, Jim Cromie wrote:
> >> On Thu, Jul 28, 2011 at 12:24 PM, Jason Baron <jbaron@redhat.com> wrote:
> >> > On Thu, Jul 28, 2011 at 11:18:56AM +0200, Bart Van Assche wrote:
> >> >> On Wed, Jul 27, 2011 at 11:34 PM, Jim Cromie <jim.cromie@gmail.com> wrote:
> >> >> > On Tue, Jul 26, 2011 at 1:08 AM, Bart Van Assche <bvanassche@acm.org> wrote:
> >> >> >> Changing pr_info() into pr_debug() inside the dynamic_debug
> >> >> >> implementation seems like a really bad idea to me. Such changes make
> >> >> >> it hard to find out via source code reading whether or not there is a
> >> >> >> risk that invoking one of these pr_debug() macros will cause infinite
> >> >> >> recursion.
> >> >> >
> >> >> > WRT earlier discussion (Joe, Jason):
> >> >> >
> >> >> >> I think these should be pr_debug.
> >> >> >> I know you're only using the current style.
> >> >> >>
> >> >> >> Jason, any reason these can not be converted?
> >> >> >
> >> >> > it should be ok, although we have to be careful not to use them in the
> >> >> > printing path, since that will cause a recursion.
> >> >> >
> >> >> > Also, if there is an issue with the dynamic debug code, it makes it more
> >> >> > of a pain to debug :)
> >> >>
> >> >> With this approach enabling all debug printing in the dynamic_debug
> >> >> implementation requires both echoing into .../dynamic_debug/control
> >> >> and setting the "verbose" module parameter. That's not something I
> >> >> would call "elegant", but after all, I'm not the dynamic debug
> >> >> maintainer ...
> >> >>
> >> >> Bart.
> >> >
> >> > we certainly don't want to make ppl do both. why is the verbose param
> >> > still required?
> >> >
> >>
> >> Its needed to selectively enable pr_info()s,
> >> which I use cuz they happen too early for pr_debug() to be enabled.
>
> ie: during init. ddebug_add_module happens for everything in the
> _ddebug table, and THEN ddebug_query is parsed and executed,
> which enables the callsites.
> I could parse 1st, and put them on pending-list, but then all parsing
> is done before the callsites are enabled, defeating the purpose.
>
> >
> > ok, then I would suggest we just stay with the verbose flag, since we
> > don't want make ppl jump through two hoops, and as a bonus we avoid any
> > potential recursive issue.
> >
> > thanks,
> >
> > -Jason
> >
>
>
> alright, I can live with that, but Id like to note the loss of selectivity
> in the verbose-only approach before capitulating:
>
> the pr_info()s in _proc_ routines are quite noisy when enabled.
>
> in my current config, which has 537 callsites,
> enabling all those pr_debug()s unselectively, ie:
>
> Kernel command line: ... ddebug_query="module dynamic_debug +pflt; "
> loglevel=8 dynamic_debug.verbose=1
>
> and doing : ~# cat /dbg/dynamic_debug/control
> logs 836 lines like
> [2573] ddebug_proc_next:866: called m=c6f99a40 p=c88955d0 *pos=427
> [2573] ddebug_proc_show:888: called m=c6f99a40 p=c88955e8
>
> Not completely overwhelming perhaps, but nice to silence.
>
> Before switching to pr_debug, I had changed those proc pr_infos to:
> if (verbose >= 10)
> pr_info(...)
>
> that quiets things nicely, and is knowable via modinfo,
> is that addition acceptable ?
>
why do you have '10' here, isn't it just, if (verbose) ?
> BTW, are you aiming for tip tree ?
The dynamic debug patches have been going in via Greg KH's device
tree. Now that the merge window has closed, I going to re-send the patch
series that I had pending. You can then send your series on top of that,
if you'd like.
Thanks,
-Jason
next prev parent reply other threads:[~2011-08-10 17:14 UTC|newest]
Thread overview: 47+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-07-25 21:42 [patch 00/25] dynamic_debug: multiple, pending queries in boot-arg Jim Cromie
2011-07-25 21:42 ` [PATCH 01/25] dynamic_debug: add pending flag 'a' to make pending queries explicit Jim Cromie
2011-07-25 21:42 ` [PATCH 02/25] dynamic_debug: change verbosity at runtime Jim Cromie
2011-07-25 21:42 ` [PATCH 03/25] dynamic_debug: use pr_debug instead of pr_info Jim Cromie
2011-07-26 7:08 ` Bart Van Assche
2011-07-27 21:34 ` Jim Cromie
2011-07-28 9:18 ` Bart Van Assche
2011-07-28 18:24 ` Jason Baron
2011-07-28 21:15 ` Jim Cromie
2011-08-03 18:27 ` Jason Baron
2011-08-03 19:52 ` Jim Cromie
2011-08-10 17:14 ` Jason Baron [this message]
2011-08-10 19:28 ` Jim Cromie
2011-07-25 21:42 ` [PATCH 04/25] dynamic_debug: replace strcpy with strlcpy, in ddebug_setup_query() Jim Cromie
2011-07-25 21:42 ` [PATCH 05/25] dynamic_debug: trim source-path prefix from dynamic_debug/control Jim Cromie
2011-07-25 21:42 ` [PATCH 06/25] dynamic_debug: process multiple commands on a line Jim Cromie
2011-07-25 21:42 ` [PATCH 07/25] dynamic_debug: enlarge command/query write buffer Jim Cromie
2011-07-25 21:42 ` [PATCH 08/25] dynamic_debug: warn when >1 of each type of match-spec is given Jim Cromie
2011-07-25 21:42 ` [PATCH 09/25] dynamic_debug: pr_err() call should not depend upon verbosity Jim Cromie
2011-07-25 21:42 ` [PATCH 10/25] dynamic_debug: dont kill entire facility on error parsing ddebug_query Jim Cromie
2011-07-25 21:42 ` [PATCH 11/25] dynamic_debug: factor show_ddebug_query out of ddebug_parse_query Jim Cromie
2011-07-26 7:13 ` Bart Van Assche
2011-07-26 7:15 ` Bart Van Assche
2011-07-26 16:21 ` Jim Cromie
2011-07-25 21:42 ` [PATCH 12/25] dynamic_debug: save non-matching queries to pending-list for later application Jim Cromie
2011-07-25 21:42 ` [PATCH 13/25] dynamic_debug: apply_pending_queries() from ddebug_add_module() Jim Cromie
2011-07-25 21:42 ` [PATCH 14/25] dynamic_debug: refactor query_matches_callsite out of ddebug_change Jim Cromie
2011-07-25 21:42 ` [PATCH 15/25] dynamic_debug: remove explicit foo != NULL checks Jim Cromie
2011-07-25 21:42 ` [PATCH 16/25] dynamic_debug: require 'a' flag to explicitly mark pending queries Jim Cromie
2011-07-26 7:26 ` Bart Van Assche
2011-07-27 17:27 ` Jim Cromie
2011-07-25 21:42 ` [PATCH 17/25] dynamic_debug: hoist locking in ddebug_change to callers Jim Cromie
2011-07-25 21:42 ` [PATCH 18/25] dynamic_debug: describe_flags with '=[pmflta_]*' Jim Cromie
2011-07-26 7:37 ` Bart Van Assche
2011-07-27 17:28 ` Jim Cromie
2011-07-25 21:42 ` [PATCH 19/25] dynamic_debug: add flags filtering to flags spec Jim Cromie
2011-07-25 21:42 ` [PATCH 20/25] dynamic_debug: remove pending query when flags zeroed Jim Cromie
2011-07-25 21:42 ` [PATCH 21/25] dynamic_debug: shrink struct pending query to size actually needed Jim Cromie
2011-07-26 7:32 ` Bart Van Assche
2011-07-27 18:41 ` Jim Cromie
2011-07-25 21:42 ` [PATCH 22/25] dynamic_debug: call ddebug_add_module() on dynamic_debug first Jim Cromie
2011-07-25 21:42 ` [PATCH 23/25] dynamic_debug: document pending queries, flags-filter, multiple queries Jim Cromie
2011-07-25 21:42 ` [PATCH 24/25] dynamic_debug: drop pr_fmt() from dynamic_pr_debug Jim Cromie
2011-07-26 2:23 ` Joe Perches
2011-07-26 3:45 ` Joe Perches
2011-07-26 5:54 ` Jim Cromie
2011-07-25 21:42 ` [PATCH 25/25] dynamic_debug: add $DBGFS/dynamic_debug/pending Jim Cromie
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:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20110810171415.GA2988@redhat.com \
--to=jbaron@redhat.com \
--cc=bvanassche@acm.org \
--cc=gnb@fmeh.org \
--cc=gregkh@suse.de \
--cc=jim.cromie@gmail.com \
--cc=joe@perches.com \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox