[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <11544.1173207073@redhat.com>
Date: Tue, 06 Mar 2007 18:51:13 +0000
From: David Howells <dhowells@...hat.com>
To: Linus Torvalds <torvalds@...ux-foundation.org>
Cc: akpm@...ux-foundation.org, benh@...nel.crashing.org,
linux-kernel@...r.kernel.org, hpa@...or.com,
johannes@...solutions.net
Subject: Re: [PATCH] Fix get_order()
Linus Torvalds <torvalds@...ux-foundation.org> wrote:
> That seems bogus. "n == 1" should give "0", no?
Sigh. No. The comment header says it all:
/**
* roundup_pow_of_two - round the given value up to nearest power of two
* @n - parameter
*
* round the given value up to the nearest power of two
* - the result is undefined when n == 0
* - this can be used to initialise global variables from constant data
*/
Ie: round, say, 30 up to 32, not 5.
David
-
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