mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: linux@horizon.com
To: vegard.nossum@horizon.com
Cc: linux@horizon.com, linux-kernel@vger.kernel.org
Subject: Re: [RFC] New kernel-message logging API
Date: 25 Sep 2007 00:58:08 -0400	[thread overview]
Message-ID: <20070925045808.12273.qmail@science.horizon.com> (raw)

> I don't know. Compare the following two lines:
> 
> printk(KERN_INFO "Message.\n");
> kprint_info("Message.");
> 
> By dropping the lengthy macro (it's not like it's going to change
> while we're running anyway, so why not make it a part of the function
> name?) and the final newline, we actually end up with a net decrease
> in line length.

Agreed.  In fact, you may want to write a header that implements the
kprint_ functions in terms of printk for out-of-core driver writers to
incorporate into their code bases, so they can  upgrade their API while
maintaining backward compatibility.  (If it were me, I'd also give it
a very permissive license, like outright public domain, to encourage use.)

> I thought it would be nice to have something that looks familiar,
> since that would ease an eventual transition. klog is a valid
> alternative, but isn't kp a bit cryptic?

Well, in context:
	kp_info("Message.");

Even the "kp_" prefix is actually pretty unnecessary.  It's "info"
and a human-readable string that make it recognizable as a log message.

Another reason to keep it short is just that it's going to get typed a LOT.

Anyway, just MHO.

             reply	other threads:[~2007-09-25  5:04 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-09-25  4:58 linux [this message]
2007-09-25  6:54 ` Joe Perches
2007-09-25  7:50   ` linux
2007-09-25  8:06   ` Vegard Nossum
  -- strict thread matches above, loose matches on Subject: below --
2007-09-22 19:27 Vegard Nossum
2007-09-23  0:13 ` Joe Perches
2007-09-23  0:40   ` Kyle Moffett
2007-09-23  0:47     ` Joe Perches
2007-09-23  3:43       ` Kyle Moffett
2007-09-23  8:39   ` Vegard Nossum
2007-09-23  8:45     ` Jan Engelhardt
2007-09-23  9:20       ` Vegard Nossum
2007-09-23  9:38         ` Jan Engelhardt
2007-09-23 19:23       ` Joe Perches
2007-09-23 19:25     ` Joe Perches
2007-09-23  1:05 ` Miguel Ojeda
2007-09-25  5:27   ` Vegard Nossum
2007-09-25 17:24     ` Miguel Ojeda
2007-09-23 20:05 ` Rob Landley
2007-09-24  9:22 ` Michael Holzheu
2007-09-24 15:19   ` Joe Perches
2007-09-24 16:43     ` Vegard Nossum
2007-09-24 17:00       ` Joe Perches
2007-09-24 20:37         ` Vegard Nossum
2007-09-25  1:18           ` Rob Landley
2007-09-24 23:51     ` Rob Landley
2007-09-25  0:10       ` Joe Perches
2007-09-25  1:46         ` Rob Landley
2007-09-25  8:57     ` Michael Holzheu
2007-09-24 18:26 ` Jesse Barnes

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=20070925045808.12273.qmail@science.horizon.com \
    --to=linux@horizon.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=vegard.nossum@horizon.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®