From: Andrew Morton <akpm@osdl.org>
To: Heiko Carstens <heiko.carstens@de.ibm.com>
Cc: mp3@de.ibm.com, clg@fr.ibm.com, linux-kernel@vger.kernel.org
Subject: Re: [Patch] statistics infrastructure - update 9
Date: Tue, 4 Jul 2006 00:19:26 -0700 [thread overview]
Message-ID: <20060704001926.20889847.akpm@osdl.org> (raw)
In-Reply-To: <20060704061754.GB9417@osiris.boeblingen.de.ibm.com>
On Tue, 4 Jul 2006 08:17:54 +0200
Heiko Carstens <heiko.carstens@de.ibm.com> wrote:
> > +
> > +static inline void statistic_add_as(int type, struct statistic *stat, int i,
> > + s64 value, u64 incr)
> > +{
> > +}
> > +
> > +#endif /* CONFIG_STATISTICS */
>
> Why not have something like:
>
> #define statistic_create(interface, name) ({ 0; })
> #define statistic_remove(interface) ({ 0; })
> #define statistic_set(stat, i, value, total) do { } while (0)
> ...
>
> That would be much shorter and easier to read. But maybe it's just me :)
typechecking.
struct scsi_device s;
int foo;
statistic_create(s, foo_with_a_typo); /* whee */
prev parent reply other threads:[~2006-07-04 7:19 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-07-03 16:24 Martin Peschke
2006-07-03 16:41 ` Cedric Le Goater
2006-07-04 0:17 ` Andi Kleen
2006-07-06 16:55 ` Martin Peschke
2006-07-06 17:00 ` Andi Kleen
2006-07-10 14:41 ` Martin Peschke
2006-07-04 6:17 ` Heiko Carstens
2006-07-04 7:19 ` Andrew Morton [this message]
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=20060704001926.20889847.akpm@osdl.org \
--to=akpm@osdl.org \
--cc=clg@fr.ibm.com \
--cc=heiko.carstens@de.ibm.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mp3@de.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
all inboxes | Powered by JetHome®