linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Pavel Machek <pavel@ucw.cz>
To: Randy Dunlap <randy_d_dunlap@linux.intel.com>
Cc: lkml <linux-kernel@vger.kernel.org>,
	linux-ide@vger.kernel.org, akpm@osdl.org, jgarzik@pobox.com
Subject: Re: [PATCH 2/13] ATA ACPI: debugging infrastructure
Date: Tue, 28 Feb 2006 12:45:00 +0100	[thread overview]
Message-ID: <20060228114500.GA4057@elf.ucw.cz> (raw)
In-Reply-To: <20060222135133.3f80fbf9.randy_d_dunlap@linux.intel.com>


> --- linux-2616-rc4-ata.orig/include/linux/libata.h
> +++ linux-2616-rc4-ata/include/linux/libata.h
> @@ -36,7 +36,8 @@
>  #include <acpi/acpi.h>
>  
>  /*
> - * compile-time options
> + * compile-time options: to be removed as soon as all the drivers are
> + * converted to the new debugging mechanism
>   */
>  #undef ATA_DEBUG		/* debugging output */
>  #undef ATA_VERBOSE_DEBUG	/* yet more debugging output */
> @@ -72,6 +73,38 @@
>          }
>  #endif
>  
> +/* NEW: debug levels */
> +#define HAVE_LIBATA_MSG 1

What is new with them?

> +enum {
> +	ATA_MSG_DRV	= 0x0001,
> +	ATA_MSG_INFO	= 0x0002,
> +	ATA_MSG_PROBE	= 0x0004,
> +	ATA_MSG_WARN	= 0x0008,
> +	ATA_MSG_MALLOC	= 0x0010,
> +	ATA_MSG_CTL	= 0x0020,
> +	ATA_MSG_INTR	= 0x0040,
> +	ATA_MSG_ERR	= 0x0080,
> +};
> +
> +#define ata_msg_drv(p)    ((p)->msg_enable & ATA_MSG_DRV)
> +#define ata_msg_info(p)   ((p)->msg_enable & ATA_MSG_INFO)
> +#define ata_msg_probe(p)  ((p)->msg_enable & ATA_MSG_PROBE)
> +#define ata_msg_warn(p)   ((p)->msg_enable & ATA_MSG_WARN)
> +#define ata_msg_malloc(p) ((p)->msg_enable & ATA_MSG_MALLOC)
> +#define ata_msg_ctl(p)    ((p)->msg_enable & ATA_MSG_CTL)
> +#define ata_msg_intr(p)   ((p)->msg_enable & ATA_MSG_INTR)
> +#define ata_msg_err(p)    ((p)->msg_enable & ATA_MSG_ERR)

I hate to see debugging infrastructure like this. We already have it
in ACPI and it is nasty/useless. It hides serious errors during normal
run, while if you turn on the debugging, it floods logs so that
it is unusable, too. I end up having to replace dprintks with
printks... nasty.
								Pavel
-- 
Web maintainer for suspend.sf.net (www.sf.net/projects/suspend) wanted...

  reply	other threads:[~2006-02-28 11:48 UTC|newest]

Thread overview: 44+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20060222133241.595a8509.randy_d_dunlap@linux.intel.com>
2006-02-22 21:40 ` [PATCH 1/13] ATA ACPI: Makefile/Kconfig/doc Randy Dunlap
2006-02-22 21:51 ` [PATCH 2/13] ATA ACPI: debugging infrastructure Randy Dunlap
2006-02-28 11:45   ` Pavel Machek [this message]
2006-02-28 12:00     ` Jeff Garzik
2006-02-28 12:04       ` Pavel Machek
2006-02-28 12:13         ` Jeff Garzik
2006-02-28 12:18       ` Andrew Morton
2006-02-28 12:31         ` Jeff Garzik
2006-02-28 18:35           ` Andrew Morton
2006-02-28 19:27             ` Jeff Garzik
2006-02-28 14:43         ` Mark Lord
2006-02-28 19:22           ` Randy Dunlap
2006-02-28 17:10         ` Phillip Susi
2006-03-01 10:29         ` James Courtier-Dutton
2006-03-01 10:45           ` Andrew Morton
2006-02-22 21:52 ` [PATCH 3/13] ATA ACPI: SATA methods Randy Dunlap
2006-02-22 21:54 ` [PATCH 4/13] ATA ACPI: add params/docs Randy Dunlap
2006-02-28 11:46   ` Pavel Machek
2006-02-28 11:57     ` Jeff Garzik
2006-02-22 21:55 ` [PATCH 5/13] ATA ACPI: use debugging macros Randy Dunlap
2006-02-28 11:47   ` Pavel Machek
2006-02-28 11:58     ` Jeff Garzik
2006-02-22 21:56 ` [PATCH 6/13] ATA ACPI: use correct acpi_object pointer Randy Dunlap
2006-02-22 21:58 ` [PATCH 7/13] ATA ACPI: more Makefile/Kconfig Randy Dunlap
2006-02-28 11:49   ` Pavel Machek
2006-02-28 12:03     ` Jeff Garzik
2006-02-28 15:27       ` Randy.Dunlap
2006-02-22 21:58 ` [PATCH 8/13] ATA ACPI: PATA methods Randy Dunlap
2006-02-28 11:55   ` Pavel Machek
2006-02-28 12:02     ` Jeff Garzik
2006-02-22 22:00 ` [PATCH 9/13] ATA ACPI: check SATA/PATA more carefully Randy Dunlap
2006-02-23  0:30   ` Alan Cox
2006-02-22 22:01 ` [PATCH 10/13] ATA ACPI: do taskfile before mode commands Randy Dunlap
2006-02-28 11:57   ` Pavel Machek
2006-02-28 12:05     ` Jeff Garzik
2006-02-28 12:08       ` Pavel Machek
2006-02-28 12:14         ` Jeff Garzik
2006-02-22 22:02 ` [PATCH 11/13] ATA ACPI: fix pata host typo Randy Dunlap
2006-02-22 22:06 ` [PATCH 12/13] ATA ACPI: use scsi_bus_shutdown for SATA/PATA Randy Dunlap
2006-02-28 11:58   ` Pavel Machek
2006-02-28 19:44     ` Randy Dunlap
2006-02-28 20:22       ` Pavel Machek
2006-02-22 22:07 ` [PATCH 13/13] ATA ACPI: enable writing PATA taskfiles Randy Dunlap
2006-02-28 11:59   ` Pavel Machek

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=20060228114500.GA4057@elf.ucw.cz \
    --to=pavel@ucw.cz \
    --cc=akpm@osdl.org \
    --cc=jgarzik@pobox.com \
    --cc=linux-ide@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=randy_d_dunlap@linux.intel.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;
as well as URLs for NNTP newsgroup(s).