@@ -86,8 +86,6 @@ bool clear_mask16_timeout(uint16_t mask, volatile void *p,
*/
#define hweight64(x) generic_hweight64(x)
#define hweight32(x) generic_hweight32(x)
-#define hweight16(x) generic_hweight16(x)
-#define hweight8(x) generic_hweight8(x)
#endif /* _ARM_BITOPS_H */
/*
@@ -132,7 +132,5 @@ static inline int test_and_set_bit(unsigned int nr, volatile void *addr)
*/
#define hweight64(x) __builtin_popcountll(x)
#define hweight32(x) __builtin_popcount(x)
-#define hweight16(x) __builtin_popcount((uint16_t)(x))
-#define hweight8(x) __builtin_popcount((uint8_t)(x))
#endif /* _ASM_PPC_BITOPS_H */
@@ -483,7 +483,5 @@ static always_inline unsigned int arch_flsl(unsigned long x)
*/
#define hweight64(x) generic_hweight64(x)
#define hweight32(x) generic_hweight32(x)
-#define hweight16(x) generic_hweight16(x)
-#define hweight8(x) generic_hweight8(x)
#endif /* _X86_BITOPS_H */
@@ -395,23 +395,6 @@ static inline unsigned int generic_hweight32(unsigned int w)
return (w + (w >> 16)) & 0xff;
}
-static inline unsigned int generic_hweight16(unsigned int w)
-{
- w -= ((w >> 1) & 0x5555);
- w = (w & 0x3333) + ((w >> 2) & 0x3333);
- w = (w + (w >> 4)) & 0x0f0f;
-
- return (w + (w >> 8)) & 0xff;
-}
-
-static inline unsigned int generic_hweight8(unsigned int w)
-{
- w -= ((w >> 1) & 0x55);
- w = (w & 0x33) + ((w >> 2) & 0x33);
-
- return (w + (w >> 4)) & 0x0f;
-}
-
static inline unsigned int generic_hweight64(uint64_t w)
{
if ( BITS_PER_LONG < 64 )