mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Jason Baron <jbaron@redhat.com>
To: Roman Fietze <roman.fietze@telemotive.de>
Cc: linux-kernel@vger.kernel.org
Subject: Re: [PATCH] dynamic_debug: allow to set dynamic debug flags right at module load time
Date: Fri, 28 May 2010 09:55:49 -0400	[thread overview]
Message-ID: <20100528135549.GA2528@redhat.com> (raw)
In-Reply-To: <201005270705.44179.roman.fietze@telemotive.de>

On Thu, May 27, 2010 at 07:05:43AM +0200, Roman Fietze wrote:
> Hello Jason,
> 
> On Wednesday 26 May 2010 20:35:59 Jason Baron wrote:
> 
> > ... we want this to be runtime configurable.
> > That is, we probably want this implemented as a module parameter, not as
> > a compile time thing. something like: modprobe module verbose=1
> 
> Kind of
> 
> #define dynamic_pr_debug(fmt, ...) do {					\
> 	...
> 		DEBUG_HASH2, __LINE__,					\
> 		verbose ? _DPRINTK_FLAGS_PRINT : _DPRINTK_FLAGS_DEFAULT}; \
> 	...
> 
> But what if verbose isn't there?
> 
> Or something smarter inside dynamic_debug_setup() or
> ddebug_add_module() looking for a module symbol or parameter with that
> name?
> 

right, i think we want to add something inside ddebug_add_module() that
recognizes if the module was loaded with verbose=1. I think you can get
at the parameters via module->kp, which we need to pass in as well.

There is also a naming issue, in that if we "reserve" the param
"verbose", how do we make sure no other module wants to use that as a
module parameter name. Or maybe it doesn't matter if we don't consume
the parameter. That is, the parameter can mean 2 things. not sure.

thanks,

-Jason

  reply	other threads:[~2010-05-28 13:56 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-05-26 12:25 Roman Fietze
2010-05-26 18:35 ` Jason Baron
2010-05-27  5:05   ` Roman Fietze
2010-05-28 13:55     ` Jason Baron [this message]
2010-06-29 11:25       ` Roman Fietze
2010-07-01 20:43         ` Jason Baron
2010-07-02  8:16           ` [PATCH] dynamic_debug: parse module parameters to enable dynamic printk at " Roman Fietze

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=20100528135549.GA2528@redhat.com \
    --to=jbaron@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=roman.fietze@telemotive.de \
    /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

Powered by JetHome