mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Dave Kleikamp <shaggy@austin.ibm.com>
To: Richard Knutsson <ricknu-0@student.ltu.se>
Cc: akpm@osdl.org, linux-kernel@vger.kernel.org, hch@infradead.org
Subject: Re: [PATCH 2.6.18-rc4-mm2] fs/jfs: Conversion to generic boolean
Date: Tue, 29 Aug 2006 07:37:42 -0500	[thread overview]
Message-ID: <1156855062.8082.7.camel@kleikamp.austin.ibm.com> (raw)
In-Reply-To: <44F37D4C.1080801@student.ltu.se>

On Tue, 2006-08-29 at 01:33 +0200, Richard Knutsson wrote:
> Dave Kleikamp wrote:
> 
> >On Mon, 2006-08-28 at 22:42 +0200, Richard Knutsson wrote:
> >
> >  
> >
> >>Just why is it, that when there is a change to make locally defined 
> >>booleans into a more generic one, it is converted into integers? ;)
> >>    
> >>
> >
> >I just see this as an opportunity to make jfs more closely fit the
> >coding style of the mainline kernel.
> >  
> >
> That is what I am trying to do, making bool as accepted as any other 
> integer. No more, no less.

Okay.  My initial impression is that you were just offended by the
ugliness of having so many different definitions of true, false, and
boolean types.

> 
> >  
> >
> >>But seriously, what is gained by removing them, other then less 
> >>understandable code? (Not talking about FALSE -> 0, but boolean_t -> int)
> >>    
> >>
> >
> >I don't feel strongly one way or another about the use of boolean_t, but
> >under fs/, the only code that uses that type is in fs/jfs and fs/xfs,
> >which are both ported from other operating systems.  Using ints for
> >boolean values does seem to be the accepted practice in the kernel.
> >  
> >
> Yes it is, but I am (for now) trying to convert those who uses some sort 
> of boolean to the generic one (in fs/ for now). Right now the ntfs/- and 
> partitions/-conversion seem to have thumbs up, in -mm.
> 
> >  
> >
> >>I can understand if authors disprove making an integer into a boolean, 
> >>but here it already were booleans.
> >>But hey, you are the maintainer ;)
> >>    
> >>
> >
> >I could be persuaded to leave the declarations as boolean_t or even
> >making them bool, but right now I'm leaning toward making them int for
> >consistency.
> >  
> >
> A root-beer maybe?

heh

> What do you say, can you hold on it for a while (can't be urgent, can 
> it?) and see how the conversion go. Will take time for it during this 
> week(end) and if the result is that almost no maintainer wants it, then...
> Just seem strange to having a boolean function but declaring it integer, 
> for (in my knowledge) no reason.

Sounds good to me.  I think I'll go ahead and kill the use of TRUE and
FALSE, but hold off on the type change for now.

-- 
David Kleikamp
IBM Linux Technology Center


  reply	other threads:[~2006-08-29 12:37 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-08-26 17:37 Richard Knutsson
2006-08-28 14:22 ` Dave Kleikamp
2006-08-28 20:42   ` Richard Knutsson
2006-08-28 21:11     ` Dave Kleikamp
2006-08-28 23:33       ` Richard Knutsson
2006-08-29 12:37         ` Dave Kleikamp [this message]
2006-08-29 13:48           ` Richard Knutsson
2006-08-29 13:53             ` Dave Kleikamp

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=1156855062.8082.7.camel@kleikamp.austin.ibm.com \
    --to=shaggy@austin.ibm.com \
    --cc=akpm@osdl.org \
    --cc=hch@infradead.org \
    --cc=linux-kernel@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

all inboxes | Powered by JetHome®