[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Pine.LNX.4.64.0610061015570.14591@schroedinger.engr.sgi.com>
Date: Fri, 6 Oct 2006 10:17:37 -0700 (PDT)
From: Christoph Lameter <clameter@....com>
To: Matthew Wilcox <matthew@....cx>
cc: David Howells <dhowells@...hat.com>, torvalds@...l.org,
akpm@...l.org, sfr@...b.auug.org.au, linux-kernel@...r.kernel.org,
linux-arch@...r.kernel.org
Subject: Re: [PATCH 1/4] LOG2: Implement a general integer log2 facility in
the kernel [try #4]
On Fri, 6 Oct 2006, Matthew Wilcox wrote:
> On Fri, Oct 06, 2006 at 02:34:14PM +0100, David Howells wrote:
> > +config ARCH_HAS_ILOG2_U32
> > + bool
> > + default n
>
> Why not "def_bool n"? Or indeed, since the default is n, why not just
> "bool"?
Why so complicated and why do it at all? We already have fls and ffs
amoung the bit operations and those map to cpu instructions on arches
that support these. fls can be used as a log 2 facilities. If you need
another name and further refine it then just add an inline function.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists