* [KJ] argument type of generic_fls()
@ 2005-08-13 13:42 walter harms
2005-08-13 14:12 ` Adrian Bunk
0 siblings, 1 reply; 2+ messages in thread
From: walter harms @ 2005-08-13 13:42 UTC (permalink / raw)
To: kernel-janitors
hi list,
after the log2 discussion i was looking for log2 in kernel. i found
long_log2() in page_alloc.c. What the author actualy wanted was fls().
To my confusion the generic_fls() searches only 32 bit but has an
argument of type int (i would expect uint32).
Will it create confusion with 64bit int systems ? if anyone considers
these a problem i would add a flsl() function and replace the int with
uint32.
re
walter
_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@lists.osdl.org
https://lists.osdl.org/mailman/listinfo/kernel-janitors
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [KJ] argument type of generic_fls()
2005-08-13 13:42 [KJ] argument type of generic_fls() walter harms
@ 2005-08-13 14:12 ` Adrian Bunk
0 siblings, 0 replies; 2+ messages in thread
From: Adrian Bunk @ 2005-08-13 14:12 UTC (permalink / raw)
To: kernel-janitors
[-- Attachment #1: Type: text/plain, Size: 814 bytes --]
On Sat, Aug 13, 2005 at 03:42:59PM +0200, walter harms wrote:
> hi list,
Hi Walter,
> after the log2 discussion i was looking for log2 in kernel. i found
> long_log2() in page_alloc.c. What the author actualy wanted was fls().
> To my confusion the generic_fls() searches only 32 bit but has an
> argument of type int (i would expect uint32).
> Will it create confusion with 64bit int systems ? if anyone considers
> these a problem i would add a flsl() function and replace the int with
> uint32.
ints stay 32bit on 64bit systems.
> re
> walter
cu
Adrian
--
"Is there not promise of rain?" Ling Tan asked suddenly out
of the darkness. There had been need of rain for many days.
"Only a promise," Lao Er said.
Pearl S. Buck - Dragon Seed
[-- Attachment #2: Type: text/plain, Size: 168 bytes --]
_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@lists.osdl.org
https://lists.osdl.org/mailman/listinfo/kernel-janitors
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2005-08-13 14:12 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-08-13 13:42 [KJ] argument type of generic_fls() walter harms
2005-08-13 14:12 ` Adrian Bunk
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.