12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667 |
- #ifndef __ASM_GENERIC_BITS_PER_LONG
- #define __ASM_GENERIC_BITS_PER_LONG
- #ifndef _UAPI__ASM_GENERIC_BITS_PER_LONG
- #define _UAPI__ASM_GENERIC_BITS_PER_LONG
- #ifndef __BITS_PER_LONG
- #if defined(__CHAR_BIT__) && defined(__SIZEOF_LONG__)
- #define __BITS_PER_LONG (__CHAR_BIT__ * __SIZEOF_LONG__)
- #else
- #define __BITS_PER_LONG 32
- #endif
- #endif
- #endif
- #ifdef CONFIG_64BIT
- #ifndef BITS_PER_LONG
- #define BITS_PER_LONG 64
- #endif
- #else
- #define BITS_PER_LONG 32
- #endif
- #if 0 && BITS_PER_LONG != __BITS_PER_LONG
- #error Inconsistent word size. Check asm/bitsperlong.h
- #endif
- #ifndef BITS_PER_LONG_LONG
- #define BITS_PER_LONG_LONG 64
- #endif
- #define small_const_nbits(nbits) \
- (__builtin_constant_p(nbits) && (nbits) <= BITS_PER_LONG && (nbits) > 0)
- #endif
|