mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Borislav Petkov <petkovbb@googlemail.com>
To: Joe Perches <joe@perches.com>
Cc: bzolnier@gmail.com, linux-kernel@vger.kernel.org,
	linux-ide@vger.kernel.org
Subject: Re: [PATCH 3/5] ide: add a driver-wide debugging macro
Date: Sun, 17 Aug 2008 20:24:33 +0200	[thread overview]
Message-ID: <20080817182433.GA6849@gollum.tnic> (raw)
In-Reply-To: <1218996786.24527.115.camel@localhost>

On Sun, Aug 17, 2008 at 11:13:06AM -0700, Joe Perches wrote:
> On Sun, 2008-08-17 at 19:23 +0200, Borislav Petkov wrote:
> > diff --git a/include/linux/ide.h b/include/linux/ide.h
> > index c161840..b6d714d 100644
> > --- a/include/linux/ide.h
> > +++ b/include/linux/ide.h
> > []
> > +/* DRV_NAME has to be defined in the driver before using the macro below */
> > +#define __ide_debug_log(lvl, fmt, args...)			\
> > +{								\
> > +	if (unlikely(drive->debug_mask & lvl))			\
> > +		printk(KERN_INFO DRV_NAME ": " fmt, ## args);	\
> > +}
> 
> Shouldn't a debug printk use KERN_DEBUG?

Yes, it should. However, i'm going to have to change the default console
loglevel to see those, aka boot with loglevel=7 and there's the possibility of
other debug messages getting in the way too. Instead, the debugging messages
here are enabled only when you do a debug build of the driver _and_ when enable
them through the debug_mask so you get to see debug messages only you're
interested in without changing anything else in the kernel boot.

-- 
Regards/Gruss,
    Boris.

  reply	other threads:[~2008-08-17 18:24 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-08-17 17:23 [PATCH 0/5] ide debugging macros Borislav Petkov
2008-08-17 17:23 ` [PATCH 1/5] ide: unify conversion macros Borislav Petkov
2008-08-17 17:23 ` [PATCH 2/5] ide: add drive->debug_mask switch Borislav Petkov
2008-08-17 17:23 ` [PATCH 3/5] ide: add a driver-wide debugging macro Borislav Petkov
2008-08-17 18:13   ` Joe Perches
2008-08-17 18:24     ` Borislav Petkov [this message]
2008-08-17 17:23 ` [PATCH 4/5] ide-floppy: convert driver to the new " Borislav Petkov
2008-08-17 17:23 ` [PATCH 5/5] ide-floppy: add a debug_mask module parameter Borislav Petkov
2008-08-18 21:08 ` [PATCH 0/5] ide debugging macros Bartlomiej Zolnierkiewicz
2008-08-18 21:29   ` Bartlomiej Zolnierkiewicz
2008-08-19  6:15   ` Borislav Petkov
2008-08-19  6:23   ` Borislav Petkov

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=20080817182433.GA6849@gollum.tnic \
    --to=petkovbb@googlemail.com \
    --cc=bzolnier@gmail.com \
    --cc=joe@perches.com \
    --cc=linux-ide@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=petkovbb@gmail.com \
    /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

all inboxes | Powered by JetHome®