netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jeff Garzik <jgarzik@pobox.com>
To: Janice M Girouard <janiceg@us.ibm.com>
Cc: "David S. Miller" <davem@redhat.com>,
	linux-kernel@vger.kernel.org, netdev@oss.sgi.com,
	Daniel Stekloff <stekloff@us.ibm.com>,
	Janice Girouard <girouard@us.ibm.com>,
	Larry Kessler <lkessler@us.ibm.com>,
	kenistonj@us.ibm.com
Subject: Re: patch for common networking error messages
Date: Mon, 16 Jun 2003 18:48:14 -0400	[thread overview]
Message-ID: <3EEE492E.9080308@pobox.com> (raw)
In-Reply-To: <3EEE2F9F.60706@us.ibm.com>

Janice M Girouard wrote:
> I agree that it's not desirable to introduce a bunch of messages that we 
> aren't already logging.  I didn't show the netif_msg prefix because I 
> was trying to focus the patch on the common messages, but you would 
> normally proceed a message with:
> 
> if netif_msg_link()
>   printk("some text to indicate the link is up/down")
> 
> The netif_msg_link test would normally filter out what messages should 
> be logged.


There are several issues at play here.

1) In general, I think you're approaching the logging from the wrong 
angle.  Start with netif_msg_xxx/NETIF_MSG_xxx first, and figure out the 
logging API for those cases.  These cover the majority of common cases, 
and most are not specific to hardware at all.  Starting at the driver 
level and trying to move driver-specific messages into the upper layers 
is the wrong direction, I feel.

2) If we are going to do major surgery on messages, make them more 
computer-parseable at the same time.  Human readable, since it must 
above-all-else be kernel hacker readable, ... but computer parseable.

Here is an example.  DISCLAIMER:  No doubt there is a better format, it 
is merely for illustration.
	"%s: performance event: scatter/gather I/O disabled\n"
		becomes
	"dev=%s evt=perf sgio=disabled\n"

Basically a key-value format.  Resist the urge to use numeric response 
codes.  For stuff like this, I think both Linus and the typical human 
brain prefer English words to numeric response codes.  This suggested 
output is not unlike some arch's show-processor-state sysrq output.

3) _Somebody_ needs to do some "ground pounding", and figure out what 
info sysadmins and users want to see.  Event logging in general, so far, 
seems to me more like a management checklist item than a real user 
need... but I am quite willing to be proved wrong.  Until we get 
feedback along these lines, I tend to resist changes like this in 
general.  My initial read of your attached patch was that it was a long 
of source churn, and I couldn't fathom what any user would gain from it all.

	Jeff



There are a whole bunch of netif_msg_xxx and corresponding NETIF_MSG_xxx 
bits.  I don't see much need to change that I think getting the logging 
API right for those would be an important first step.

	Jeff


P.S. It is important to note the bits are laid out in increasing verbosity.

  reply	other threads:[~2003-06-16 22:48 UTC|newest]

Thread overview: 44+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-06-16 20:30 patch for common networking error messages Janice M Girouard
2003-06-16 20:38 ` David S. Miller
2003-06-16 20:53   ` Andi Kleen
2003-06-16 20:51     ` David S. Miller
2003-06-16 22:27       ` Andrew Morton
2003-06-17  7:09         ` Andi Kleen
2003-06-17  7:20           ` Andrew Morton
2003-06-16 20:59   ` Janice M Girouard
2003-06-16 22:48     ` Jeff Garzik [this message]
2003-06-16 22:52       ` Jeff Garzik
2003-06-16 22:13 ` Nivedita Singhvi
2003-06-16 22:13   ` David S. Miller
2003-06-16 22:50     ` Nivedita Singhvi
2003-06-16 22:57       ` David S. Miller
2003-06-16 23:02   ` Donald Becker
  -- strict thread matches above, loose matches on Subject: below --
2003-06-16 22:29 Janice Girouard
2003-06-16 22:27 ` David S. Miller
2003-06-16 22:45   ` Nivedita Singhvi
2003-06-16 22:52     ` David S. Miller
2003-06-17  0:07       ` Nivedita Singhvi
2003-06-16 22:50 Janice Girouard
2003-06-16 22:55 ` David S. Miller
2003-06-21 12:36   ` Alan Cox
2003-06-21 14:27     ` Jamal Hadi
2003-06-23  0:46     ` David S. Miller
2003-06-23 11:54       ` Alan Cox
2003-06-17  0:44 Janice Girouard
2003-06-17  1:19 ` David S. Miller
2003-06-17 14:34   ` Mr. James W. Laferriere
2003-06-17  2:12 Janice Girouard
2003-06-17  4:34 ` Valdis.Kletnieks
2003-06-17 16:08   ` Stephen Hemminger
2003-06-17 16:09     ` David S. Miller
2003-06-17 18:46       ` Jeff Garzik
2003-06-17 19:06         ` Janice M Girouard
2003-06-17 19:23           ` Jeff Garzik
2003-06-17 19:46             ` Janice M Girouard
2003-06-17 19:50               ` David S. Miller
2003-06-17 20:24                 ` Janice M Girouard
2003-06-17 20:27                   ` David S. Miller
2003-06-17 20:40 Janice Girouard
2003-06-17 20:42 ` David S. Miller
2003-06-17 20:57 Janice Girouard
2003-06-17 21:14 ` David S. Miller

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=3EEE492E.9080308@pobox.com \
    --to=jgarzik@pobox.com \
    --cc=davem@redhat.com \
    --cc=girouard@us.ibm.com \
    --cc=janiceg@us.ibm.com \
    --cc=kenistonj@us.ibm.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lkessler@us.ibm.com \
    --cc=netdev@oss.sgi.com \
    --cc=stekloff@us.ibm.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).