From: "David S. Miller" <davem@davemloft.net>
To: davej@redhat.com
Cc: lkml@rtr.ca, linux-kernel@vger.kernel.org, torvalds@osdl.org
Subject: Re: [PATCH] Fix bytecount result from printk()
Date: Thu, 01 Dec 2005 12:15:54 -0800 (PST) [thread overview]
Message-ID: <20051201.121554.130875743.davem@davemloft.net> (raw)
In-Reply-To: <20051201175732.GD19433@redhat.com>
From: Dave Jones <davej@redhat.com>
Date: Thu, 1 Dec 2005 12:57:32 -0500
> On Thu, Dec 01, 2005 at 10:55:49AM -0500, Mark Lord wrote:
> > printk() returns a bytecount, which nothing actually appears to use.
>
> We do check it in a few places.
>
> arch/x86_64/kernel/traps.c: i += printk(" "); \
> arch/x86_64/kernel/traps.c: i += printk(" <%s> ", id);
> arch/x86_64/kernel/traps.c: i += printk(" <EOE> ");
> arch/x86_64/kernel/traps.c: i += printk(" <IRQ> ");
> arch/x86_64/kernel/traps.c: i += printk(" <EOI> ");
> drivers/char/mem.c: ret = printk("%s", tmp);
Wow, that's amazing. :)
I bet these can easily be removed, and since printk() is such
a core thing, simplifying it should trump whatever benfits
these few call sites have from getting a return byte count.
next prev parent reply other threads:[~2005-12-01 20:15 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-12-01 15:55 Mark Lord
2005-12-01 16:09 ` Linus Torvalds
2005-12-01 16:25 ` Mark Lord
2005-12-01 17:57 ` Dave Jones
2005-12-01 20:15 ` David S. Miller [this message]
2005-12-02 1:23 ` Andi Kleen
2005-12-01 21:09 ` Mark Lord
2005-12-01 21:16 ` Andi Kleen
2005-12-02 2:04 ` Andrew Morton
2005-12-02 2:22 ` Mark Lord
2005-12-01 20: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=20051201.121554.130875743.davem@davemloft.net \
--to=davem@davemloft.net \
--cc=davej@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=lkml@rtr.ca \
--cc=torvalds@osdl.org \
/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®