From: James Bottomley <James.Bottomley@SteelEye.com>
To: Andrew Morton <akpm@linux-foundation.org>
Cc: linux-scsi@vger.kernel.org, ricknu-0@student.ltu.se
Subject: Re: [patch 16/30] drivers/scsi/aic7xxx_old: Convert to generic boolean-values
Date: Tue, 08 May 2007 10:11:00 -0500 [thread overview]
Message-ID: <1178637060.3737.15.camel@mulgrave.il.steeleye.com> (raw)
In-Reply-To: <20070507140656.3debfb55.akpm@linux-foundation.org>
On Mon, 2007-05-07 at 14:06 -0700, Andrew Morton wrote:
> On Mon, 07 May 2007 14:50:19 -0500
> James Bottomley <James.Bottomley@SteelEye.com> wrote:
>
> > On Thu, 2007-04-26 at 00:35 -0700, akpm@linux-foundation.org wrote:
> > > From: Richard Knutsson <ricknu-0@student.ltu.se>
> > >
> > > Convert:
> > > FALSE -> false
> > > TRUE -> true
> >
> > NAK'd by maintainer.
> >
>
> I went back and reviewed the previous discussion. Maintaner's reasons for
> NAKing were, and remain wholly specious.
Well, I agree with them. There are three primary reasons for this
1. In C logical values are arithmetic types by design. Trying to
backfill C++ ideas of separation of logical and arithmetic types
is asking for bugs.
2. If people have to use boolean values (which I don't like; I
prefer simple assignment and checking), I prefer the upper case
values because, effectively, they're simple arithmetical
constants.
3. it's going to generate a huge amount of churn in all the
subsystems and drivers for no appreciable benefit. Unless
someone can actually articulate one? (Other than "because it's
there").
The patch in question basically just downcased the TRUE/FALSE in the
driver, which makes it less readable (mainly because I really don't like
the way it uses truth values, but that's a maintainer's prerogative, and
I recognise the upper case values as warning me to be careful).
> That being said, the patch is moderately wrong (or at least incomplete)
> because it does things like:
>
> - unsigned char done = FALSE;
> + unsigned char done = false;
>
> whereas it should have done
>
> - unsigned char done = FALSE;
> + bool done = false;
And the value to the driver of this transformation?
James
next prev parent reply other threads:[~2007-05-08 15:11 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-04-26 7:35 [patch 16/30] drivers/scsi/aic7xxx_old: Convert to generic boolean-values akpm
2007-05-07 19:50 ` James Bottomley
2007-05-07 21:06 ` Andrew Morton
2007-05-07 21:11 ` Andrew Morton
2007-05-08 4:13 ` Richard Knutsson
2007-05-08 15:11 ` James Bottomley [this message]
2007-05-08 19:14 ` Andrew Morton
2007-05-08 19:24 ` James Bottomley
2007-05-08 20:11 ` Andrew Morton
2007-05-08 20:41 ` James Bottomley
2007-05-08 21:44 ` David Miller
2007-05-08 21:59 ` James Bottomley
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=1178637060.3737.15.camel@mulgrave.il.steeleye.com \
--to=james.bottomley@steeleye.com \
--cc=akpm@linux-foundation.org \
--cc=linux-scsi@vger.kernel.org \
--cc=ricknu-0@student.ltu.se \
/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