Akinobu Mita | 2dfc383 | 2006-03-26 01:39:10 -0800 | [diff] [blame] | 1 | #ifndef _ASM_GENERIC_BITOPS_FLS64_H_ |
2 | #define _ASM_GENERIC_BITOPS_FLS64_H_ | ||||
3 | |||||
4 | static inline int fls64(__u64 x) | ||||
5 | { | ||||
6 | __u32 h = x >> 32; | ||||
7 | if (h) | ||||
8 | return fls(h) + 32; | ||||
9 | return fls(x); | ||||
10 | } | ||||
11 | |||||
12 | #endif /* _ASM_GENERIC_BITOPS_FLS64_H_ */ |