From: Jean Delvare <khali@linux-fr.org>
To: Greg KH <greg@kroah.com>, Christopher Hoover <ch@murgatroid.com>
Cc: Andrew Morton <akpm@osdl.org>,
kernel-janitors@lists.osdl.org, linux-kernel@vger.kernel.org,
lm-sensors@lm-sensors.org
Subject: Re: [PATCH] Clean up magic numbers in i2c_parport.h
Date: Fri, 24 Mar 2006 20:31:35 +0100 [thread overview]
Message-ID: <20060324203135.bfcaac45.khali@linux-fr.org> (raw)
In-Reply-To: <20060324174901.GA27881@kroah.com>
Hi Greg, Christpher,
> > I don't think C99 initializers are needed here, the structure is pretty
> > simple and is also defined in the same file, a few lines above all its
> > instance declarations. So I am indeed asking for a patch w/o macros and
> > w/o C99 structure initializers, unless someone objects.
>
> You should use structure initializers whereever possible, as it makes
> future changes much easier and safer (reorder the fields and things
> don't break in odd ways.) So I would encourage this kind of change.
Oh well, if Greg says so...
Christopher, can you please respin a patch with C99 initializers, which
would look a bit better than your original one? I'd suggest a single,
straightforward macro (no needless underscores please):
#define LINEOP(val, port, inverted) \
{ .val = (val), .port = (port), .inverted = (inverted) }
Hopefully this will keep all lines within a reasonable length and won't
hurt the readability too much.
Also, I just noticed in your original patch: please preserve the comma
at the end of the last line of struct declarations. It's not needed,
sure, but it makes later changes easier.
Thanks,
--
Jean Delvare
prev parent reply other threads:[~2006-03-24 19:31 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-03-23 8:12 [PATCH] Clean up magic numbers in i2c_parport.h Christopher Hoover
2006-03-23 19:56 ` Jean Delvare
2006-03-24 4:45 ` Christopher Hoover
2006-03-24 7:26 ` Jean Delvare
2006-03-24 17:49 ` [KJ] " Greg KH
2006-03-24 19:31 ` Jean Delvare [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=20060324203135.bfcaac45.khali@linux-fr.org \
--to=khali@linux-fr.org \
--cc=akpm@osdl.org \
--cc=ch@murgatroid.com \
--cc=greg@kroah.com \
--cc=kernel-janitors@lists.osdl.org \
--cc=linux-kernel@vger.kernel.org \
--cc=lm-sensors@lm-sensors.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